3 ”Reöã@sŽddlZddlmZddlmZddlmZddlmZddl m Z e rpddl m Z m Z ddlmZdd lmZejeƒZGd d „d eƒZdS) éN)ÚBuildEnvironment)ÚAbstractDistribution)ÚInstallationError)Úrunner_with_spinner_message)ÚMYPY_CHECK_RUNNING)ÚSetÚTuple)Ú Distribution)Ú PackageFinderc@s(eZdZdZdd„Zdd„Zdd„ZdS) ÚSourceDistributionz½Represents a source distribution. The preparation step for these needs metadata for the packages to be generated, either using PEP 517 or using the legacy `setup.py egg_info`. cCs |jjƒS)N)ÚreqÚget_dist)Úself©rú�/builddir/build/BUILDROOT/alt-python36-pip-20.2.4-5.el8.x86_64/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/distributions/sdist.pyÚget_pkg_resources_distributionsz1SourceDistribution.get_pkg_resources_distributioncCs2|jjƒ|jjo|}|r$|j|ƒ|jjƒdS)N)r Úload_pyproject_tomlÚ use_pep517Ú_setup_isolationÚprepare_metadata)rÚfinderÚbuild_isolationÚshould_isolaterrrÚprepare_distribution_metadatas    z0SourceDistribution.prepare_distribution_metadatacs‡‡fdd„}ˆjj}|dk s"t‚tƒˆj_ˆjjj||ddƒˆjjjˆjjƒ\‰}ˆrd|dˆƒ|r’tj dˆjƒtj ddj t t t |ƒƒƒƒˆjj�@td ƒ}ˆjj}|dk s¸t‚|j|ƒ�|jƒ}WdQRXWdQRXˆjjj|ƒ\‰}ˆ�r|d ˆƒˆjjj||d d ƒdS) Ncs6d}|jˆj|djdd„tˆƒDƒƒd�}t|ƒ‚dS)NzZSome build dependencies for {requirement} conflict with {conflicting_with}: {description}.z, css|]\}}dj||ƒVqdS)z{} is incompatible with {}N)Úformat)Ú.0Ú installedÚwantedrrrú 6szPSourceDistribution._setup_isolation.._raise_conflicts..)Ú requirementÚconflicting_withÚ description)rr ÚjoinÚsortedr)r Úconflicting_reqsÚ format_stringÚ error_message)Ú conflictingrrrÚ_raise_conflicts,sz=SourceDistribution._setup_isolation.._raise_conflictsÚoverlayzInstalling build dependenciesz"PEP 517/518 supported requirementsz4Missing build requirements in pyproject.toml for %s.z`The project does not specify a build backend, and pip cannot fall back to setuptools without %s.z and z#Getting requirements to build wheelzthe backend dependenciesÚnormalzInstalling backend dependencies)r Úpyproject_requiresÚAssertionErrorrÚ build_envÚinstall_requirementsÚcheck_requirementsÚrequirements_to_checkÚloggerÚwarningr"ÚmapÚreprr#rÚpep517_backendÚsubprocess_runnerÚget_requires_for_build_wheel)rrr(r+ÚmissingÚrunnerÚbackendÚreqsr)r'rrr*s@      z#SourceDistribution._setup_isolationN)Ú__name__Ú __module__Ú __qualname__Ú__doc__rrrrrrrr s r )ÚloggingÚpip._internal.build_envrÚ pip._internal.distributions.baserÚpip._internal.exceptionsrÚpip._internal.utils.subprocessrÚpip._internal.utils.typingrÚtypingrrZpip._vendor.pkg_resourcesr Ú"pip._internal.index.package_finderr Ú getLoggerr<r1r rrrrÚs