관리-도구
편집 파일: acquire.cpython-38.pyc
U *�e� � @ s� d Z ddlmZ ddlZddlZddlmZmZ ddlm Z ddl mZmZm Z ddlmZ dd lmZ dd lmZmZmZ dd� Zd d� Zdd� Zdd� Zdd� ZdddgZdS )z Bootstrap.� )�annotationsN)�eq�lt)�Path)�PIPE�CalledProcessError�Popen� )�from_bundle)�add_wheel_to_update_log)�Version�Wheel�discover_wheelsc C sx d}|r|t jkr&t| ||||||�}|rt|dkrt|t jkrtt| t �|�||||j|d�}|dk rt|jrtt|||� |S )znGet a wheel with the given distribution-version-for_py_version trio, by using the extra search dir + download.N)�distribution�version_spec�for_py_version�search_dirs�app_data� to_folder�env) r �bundler �embed�download_wheelZas_version_spec�houseZ can_updater ) r �versionr r �downloadr �do_periodic_updater �wheel� r �L/opt/hc_python/lib/python3.8/site-packages/virtualenv/seed/wheels/acquire.py� get_wheel s � r c C s� | � |p d� �}t �d|||� tjddddddd d d|dt|�|g}t|||�}t||ttd dd�} | �� \} }| j dkr�| |d�}t | j |f|��t| |||| �} t �d| j� | S )N� zdownload wheel %s %s to %sz-m�pipr z--progress-bar�offz--disable-pip-version-checkz--only-binary=:all:z --no-depsz--python-versionz-dTzutf-8)r �stdout�stderr�universal_newlines�encodingr )�outputr% zdownloaded wheel %s) �logging�debug�sys� executable�str�pip_wheel_env_runr r �communicate� returncoder �_find_downloaded_wheel�name)r r r r r r r Zto_download�cmd�process�out�err�kwargs�resultr r r r 3 s4 � r c C s\ |� � D ]D}|�� }dD ]2}|�|�rtt|t|�d � ��� � S qqt| |||�S )N)zSaved zFile was already downloaded )� splitlines�lstrip� startswithr r �len�absolute�find_compatible_in_house)r r r r r5 �lineZ stripped_line�markerr r r r1 R s (r1 c s� t || d |�}dt|� }}|d k r�|r�|�d�r>dt }� n|�d�rTdt }� nt|��t�||d � ��t� �fdd�t |�D �t|��}||kr�d S || S )Nr �<r z==� c 3 s"