U
ÀÒ.eì ã @ sh d dl Z d dlmZmZ d dlmZ d dlmZ erTd dlm Z m
Z
mZ d dlmZ G dd„ de
ƒZdS ) é N)Ú
get_supportedÚversion_info_to_nodot)Únormalize_version_info)ÚMYPY_CHECK_RUNNING)ÚListÚOptionalÚTuple)Ú Pep425Tagc @ s* e Zd ZdZd dd„Zdd„ Zdd„ ZdS )
ÚTargetPythonzx
Encapsulates the properties of a Python interpreter one is targeting
for a package install, download, etc.
Nc C sf || _ |dkrtjdd… }nt|ƒ}d tt|dd… ƒ¡}|| _|| _|| _ || _
|| _d| _dS )a
:param platform: A string or None. If None, searches for packages
that are supported by the current system. Otherwise, will find
packages that can be built on the platform passed in. These
packages will only be downloaded for distribution: they will
not be built locally.
:param py_version_info: An optional tuple of ints representing the
Python version information to use (e.g. `sys.version_info[:3]`).
This can have length 1, 2, or 3 when provided.
:param abi: A string or None. This is passed to pep425tags.py's
get_supported() function as is.
:param implementation: A string or None. This is passed to
pep425tags.py's get_supported() function as is.
Né Ú.é )
Ú_given_py_version_infoÚsysÚversion_infor ÚjoinÚmapÚstrÚabiÚimplementationÚplatformÚ
py_versionÚpy_version_infoÚ_valid_tags)Úselfr r r r r © r úF/usr/lib/python3.8/site-packages/pip/_internal/models/target_python.pyÚ__init__ s zTargetPython.__init__c C sZ d}| j dk r$d dd„ | j D ƒ¡}d| jfd|fd| jfd| jfg}d d
d„ |D ƒ¡S )zD
Format the given, non-None attributes for display.
Nr c s s | ]}t |ƒV qd S )N)r )Ú.0Úpartr r r Ú