관리-도구
편집 파일: utils.cpython-37.pyc
B ��ReL � @ s\ d dl mZmZ d dlmZ d dlmZ er<d dlmZm Z ddiZ dd� Zefd d �ZdS )� )�CONTENT_CHUNK_SIZE�Response)�NetworkConnectionError)�MYPY_CHECK_RUNNING)�Dict�IteratorzAccept-Encoding�identityc C s� d}t | jt�rDy| j�d�}W qJ tk r@ | j�d�}Y qJX n| j}d| j kr`dk rxn nd| j|| jf }n,d| j kr�dk r�n nd| j|| jf }|r�t|| d ��d S ) N� zutf-8z iso-8859-1i� i� z%s Client Error: %s for url: %siX z%s Server Error: %s for url: %s)�response)� isinstance�reason�bytes�decode�UnicodeDecodeError�status_code�urlr )�resp�http_error_msgr � r ��/builddir/build/BUILDROOT/alt-python37-pip-20.2.4-6.el8.x86_64/opt/alt/python37/lib/python3.7/site-packages/pip/_internal/network/utils.py�raise_for_status s r c c s\ y$x| j j|dd�D ] }|V qW W n2 tk rV x| j �|�}|sHP |V q6W Y nX dS )z8Given a requests Response, provide the data chunks. F)�decode_contentN)�raw�stream�AttributeError�read)r � chunk_size�chunkr r r �response_chunks: s r N) Zpip._vendor.requests.modelsr r �pip._internal.exceptionsr �pip._internal.utils.typingr �typingr r �HEADERSr r r r r r �<module> s