관리-도구
편집 파일: wait.cpython-37.pyc
B ��Re � @ s� d dl Z d dlmZ d dlZd dlZyd dlmZ W n ek rT d dlmZ Y nX dddgZG dd� de �Z ejd kr�d d� Zndd� Zddd�Z ddd�Zdd� Zdd� Zdd� addd�Zddd�ZdS )� N)�partial)� monotonic)�time�NoWayToWaitForSocketError� wait_for_read�wait_for_writec @ s e Zd ZdS )r N)�__name__� __module__�__qualname__� r r ��/builddir/build/BUILDROOT/alt-python37-pip-20.2.4-6.el8.x86_64/opt/alt/python37/lib/python3.7/site-packages/pip/_vendor/urllib3/util/wait.pyr s )� � c C s | |�S )Nr )�fn�timeoutr r r �_retry_on_intr* s r c C s� |d krt d�}n t� | }xry| |�S ttjfk r� } z@|jd tjkrR� n(|t� }|dk rhd}|t d�krxd }wW d d }~X Y qX qW d S )N�infr )�floatr �OSError�select�error�args�errnoZEINTR)r r �deadline�er r r r 0 s Fc C sd |s|st d��g }g }|r&|�| � |r4|�| � ttj|||�}t||�\}}} t|p`|p`| �S )Nz2must specify at least one of read=True, write=True)�RuntimeError�appendr r r �bool) �sock�read�writer �rcheck�wcheckr �rready�wready�xreadyr r r �select_wait_for_socketG s r&