\h candidatereturncBtttf}t||r|Sy)z%The runtime version of BaseCandidate.N)r r!r" isinstance)r#base_candidate_classess q/root/niggaflix-v3/playground/venv/lib/python3.12/site-packages/pip/_internal/resolution/resolvelib/candidates.pyas_base_candidater))s+ " )34 linktemplatec |jrJd|jrt|j}n |j}t ||j |j |j|j|j|j|j|j }|j|_ ||_|j|_|S)Nztemplate is editable user_supplied comes_from use_pep517isolated constraintglobal_options hash_optionsconfig_settings)editablereqstrurlrr/r0r1r2r3r4r5r6 original_linkr+extras)r+r,lineireqs r(make_install_req_from_linkr?5s  8"88 ||8<< xx  ,,&&&&""&&..** 00 D"//DDI//DK Kr*c @|jsJdt|j|j|j|j |j |j|j|j|j|j }|j|_ |S)Nztemplate not editable) r/r0r1r2r3permit_editable_wheelsr4r5r6) r7rr:r/r0r1r2r3rAr4r5r6r<)r+r,r>s r(make_install_req_from_editablerBNs   555  $ ,,&&&&""&&'>>..** 00 D//DK Kr*distc |jrt|j}nM|jr&|jd|jj}n|jd|j }t ||j|j|j|j|j|j|j|j }||_|S)Nz @ z==r.)r8r9r+canonical_namer:versionrr/r0r1r2r3r4r5r6 satisfied_by)rCr,r=r>s r(_make_install_req_from_distrHbs||8<<  %%&c(--*;*;)<=%%&b7  ,,&&&&""&&..** 00 DD Kr*cJeZdZUdZeed<dZ ddedededd d e e d e e d dfd Z d e fdZd e fdZd efdZded efdZed e efdZed e fdZed e fdZed e fdZd e fdZd efdZded dfdZd efdZded ee efdZ d e efdZ!y)"_InstallRequirementBackedCandidateaA candidate backed by an ``InstallRequirement``. This represents a package request with the target not being already in the environment, and needs to be fetched and installed. The backing ``InstallRequirement`` is responsible for most of the leg work; this class exposes appropriate information to the resolver. :param link: The link passed to the ``InstallRequirement``. The backing ``InstallRequirement`` will use this link to fetch the distribution. :param source_link: The link this candidate "originates" from. This is different from ``link`` when the link is found in the wheel cache. ``link`` would point to the wheel cache, while this points to the found remote link (e.g. from pypi.org). rCFNr+ source_linkr>factoryrnamerFr$c||_||_||_||_||_||_|j |_yN)_link _source_link_factory_ireq_name_version_preparerC)selfr+rKr>rLrMrFs r(__init__z+_InstallRequirementBackedCandidate.__init__s< '    MMO r*c8|jd|jS)N rMrFrWs r(__str__z*_InstallRequirementBackedCandidate.__str__s))Adll^,,r*c`|jjdt|jdSN()) __class____name__r9rPr\s r(__repr__z+_InstallRequirementBackedCandidate.__repr__s)..))*!C O+>a@@r*cDt|j|jfSrO)hashrbrPr\s r(__hash__z+_InstallRequirementBackedCandidate.__hash__sT^^TZZ011r*othercpt||jr t|j|jSyNF)r&rbrrPrWrhs r(__eq__z)_InstallRequirementBackedCandidate.__eq__s( eT^^ ,#DJJ < <r*c|jSrO)rQr\s r(rKz._InstallRequirementBackedCandidate.source_link   r*ch|j|jj|_|jSz:The normalised name of the project the candidate refers to)rTrCrEr\s r( project_namez/_InstallRequirementBackedCandidate.project_names) :: 11DJzzr*c|jSrOrqr\s r(rMz'_InstallRequirementBackedCandidate.namernr*ch|j|jj|_|jSrOrUrCrFr\s r(rFz*_InstallRequirementBackedCandidate.version' ==  II--DM}}r*cdj|j|j|jjr|jj S|jS)Nz{} {} (from {}))formatrMrFrPis_file file_pathr\s r(format_for_errorz3_InstallRequirementBackedCandidate.format_for_errorsP '' II LL$(JJ$6$6DJJ   =AJJ  r*ctd)NzOverride in subclass)NotImplementedErrorr\s r(_prepare_distributionz8_InstallRequirementBackedCandidate._prepare_distributions!"899r*cn|jE|j|jk7r,t|jd|j|j|jX|j|j k7r>t|jdt |jt |j yy)z:Check for consistency of project name and version of dist.NrMrF)rTrErrSrUrFr9)rWrCs r(_check_metadata_consistencyz>_InstallRequirementBackedCandidate._check_metadata_consistencys :: !djjD4G4G&G&  ##   == $$,,)F& DMM"DLL!  *G $r*c |j}|j ||S#t$r}|j|_d}~wt$r }d|_d}~wwxYw)NzSee above for output.)r~rrSr8rcontextr)rWrCeexcs r(rVz+_InstallRequirementBackedCandidate._prepares_ --/D ((.  JJAE * 1CK  s % AA A AA with_requiresc#*K|r|jjnd}|D]9}|jjt ||j Ed{;|jj |jjy78wN)rCiter_dependenciesrRmake_requirements_from_specr9rS make_requires_python_requirementrequires_python)rWrrequiresrs r(rz4_InstallRequirementBackedCandidate.iter_dependenciesst4A499..0r UA}}@@QT T T Umm<rLrMrF)get_wheel_cache_entryloggerdebugr+r?is_wheelryrfilenamer rMr rFrx persistentr;cached_wheel_source_linkorigin download_inforsuperrX) rWr+r,rLrMrFrK cache_entryr>wheel wheel_name wheel_versionrbs r(rXzLinkCandidate.__init__s 33KF  " LL6 8H8H I##D)$9yyD   99  dii&7&7$)),,-E*5::6J:% N$j^:'N N%" ' 6 -/1L1S1S]D2/  "99%% %%99$$ $$%%(--8;Q;Q*Q0;-!!-%0%7%7"&: 8N8N&" #  r*ch|jj}|j|jdS)NT)parallel_builds)rRpreparerprepare_linked_requirementrS)rWrs r(r~z#LinkCandidate._prepare_distribution+s+==))224::t2TTr*r rcrr is_editablerrrr rrXrr~ __classcell__rbs@r(r"r"sjK*..2 / / %/  / ~& / *+ /  / bU'7Ur*r"c ZeZdZdZ d dededddeedeed df fd Z d e fd Z xZ S) r!TNr+r,rLrrMrFr$cDt|||t|||||y)Nr)rrXrB)rWr+r,rLrMrFrbs r(rXzEditableCandidate.__init__3s0 /h?  r*c`|jjj|jSrO)rRrprepare_editable_requirementrSr\s r(r~z'EditableCandidate._prepare_distributionDs!}}%%BB4::NNr*rrrs@r(r!r!0siK*..2   %   ~&  *+    "O'7Or*r!ceZdZdZdZdededdddfdZdefd Z defd Z de fd Z d e defd ZedefdZedefdZedefdZedefdZdefdZdedeeefdZdeefdZy)r TNrCr,rLrr$c||_t|||_||_d|_d}|j j |j|y)Nzalready satisfied)rCrHrSrRrUrprepare_installed_requirement)rWrCr,rL skip_reasons r(rXz"AlreadyInstalledCandidate.__init__LsH  0x@   * 66tzz;Or*c,t|jSrO)r9rCr\s r(r]z!AlreadyInstalledCandidate.__str__^s499~r*cN|jjd|jdSr_)rbrcrCr\s r(rdz"AlreadyInstalledCandidate.__repr__as$..))*!DII=::r*cZt|j|j|jfSrO)rfrbrMrFr\s r(rgz"AlreadyInstalledCandidate.__hash__ds T^^TYY =>>r*rhct||jr4|j|jk(xr|j|jk(Syrj)r&rbrMrFrks r(rlz AlreadyInstalledCandidate.__eq__gs8 eT^^ ,99 *Lt||u}}/L Lr*c.|jjSrO)rCrEr\s r(rqz&AlreadyInstalledCandidate.project_namelsyy'''r*c|jSrOrsr\s r(rMzAlreadyInstalledCandidate.nameprnr*ch|j|jj|_|jSrOrur\s r(rFz!AlreadyInstalledCandidate.versiontrvr*c.|jjSrO)rCr7r\s r(rz%AlreadyInstalledCandidate.is_editablezsyy!!!r*c:|jd|jdS)NrZz (Installed)r[r\s r(r{z*AlreadyInstalledCandidate.format_for_error~s))Adll^<88r*rc#K|sy|jjD]9}|jjt ||j Ed{;y7wrO)rCrrRrr9rS)rWrrs r(rz+AlreadyInstalledCandidate.iter_dependenciessO ,,. UA}}@@QT T T U TsAAAAcyrOrr\s r(rz1AlreadyInstalledCandidate.get_install_requirementr*)rcrrrrKrrrXr9r]rdrrgrrrlrr rqrMrrFrr{rrrrrrr*r(r r HsLKPP%P P  P$;#;?#?CD (n((!c!!) "T""9#9UtU+AV8WU 2D)Er*r c deZdZdZdddedeedeeddfdZ defd Z defd Z de fd Z d edefd ZedefdZedefdZedefdZdefdZedefdZedefdZedeefdZdeedeeddfdZdeefdZdedeeefdZ deefdZ!y)ExtrasCandidateaA candidate that has 'extras', indicating additional dependencies. Requirements can be for a project with dependencies, something like foo[extra]. The extras don't affect the project/version being installed directly, but indicate that we need additional dependencies. We model that by having an artificial ExtrasCandidate that wraps the "base" candidate. The ExtrasCandidate differs from the base in the following ways: 1. It has a unique name, of the form foo[extra]. This causes the resolver to treat it as a separate node in the dependency graph. 2. When we're getting the candidate's dependencies, a) We specify that we want the extra dependencies as well. b) We add a dependency on the base candidate. See below for why this is needed. 3. We return None for the underlying InstallRequirement, as the base candidate will provide it, and we don't want to end up with duplicates. The dependency on the base candidate is needed so that the resolver can't decide that it should recommend foo[extra1] version 1.0 and foo[extra2] version 2.0. Having those candidates depend on foo=1.0 and foo=2.0 respectively forces the resolver to recognise that this is a conflict. N)r0baser<r0r$c||_td|D|_|j|j|_|||_y|jj |_y)a :param comes_from: the InstallRequirement that led to this candidate if it differs from the base's InstallRequirement. This will often be the case in the sense that this candidate's requirement has the extras while the base's does not. Unlike the InstallRequirement backed candidates, this requirement is used solely for reporting purposes, it does not do any leg work. c32K|]}t|ywrO)r ).0rs r( z+ExtrasCandidate.__init__..sE 1! 4EN)r frozensetr< difference_unnormalized_extrasrS _comes_from)rWrr<r0s r(rXzExtrasCandidate.__init__sR EfEE %+$5$5dkk$B!)3)?:TYY__r*ct|jjdd\}}dj|dj |j |S)NrZrz {}[{}] {},)r9rsplitrxjoinr<)rWrMrests r(r]zExtrasCandidate.__str__sB^))#q1 d!!$(=tDDr*ch|jjd|jd|jdS)Nz(base=z , extras=ra)rbrcrr<r\s r(rdzExtrasCandidate.__repr__s/..))*& Yt{{oUVWWr*cDt|j|jfSrO)rfrr<r\s r(rgzExtrasCandidate.__hash__sTYY ,--r*rhct||jr4|j|jk(xr|j|jk(Syrj)r&rbrr<rks r(rlzExtrasCandidate.__eq__s8 eT^^ ,99 *Jt{{ell/J Jr*c.|jjSrO)rrqr\s r(rqzExtrasCandidate.project_nameyy%%%r*cVt|jj|jSrp)rrrqr<r\s r(rMzExtrasCandidate.names499114;;??r*c.|jjSrO)rrFr\s r(rFzExtrasCandidate.versionsyy   r*cdj|jjdjt |j S)Nz{} [{}]z, )rxrr{rsortedr<r\s r(r{z ExtrasCandidate.format_for_errors9 II & & ($))F4;;4G*H  r*c.|jjSrO)rrr\s r(rzExtrasCandidate.is_installedrr*c.|jjSrO)rrr\s r(rzExtrasCandidate.is_editableyy$$$r*c.|jjSrO)rrKr\s r(rKzExtrasCandidate.source_linkrr* requestedvalidctfd|D}|syt|D]8}tjdjj j |:y)zEmit warnings for invalid extras being requested. This emits a warning for each requested extra that is not in the candidate's ``Provides-Extra`` list. c3FK|]}|vr|jvr|ywrO)r<)rextrarWrs r(rz7ExtrasCandidate._warn_invalid_extras..s/+ E!$ + s!Nz%%s %s does not provide the extra '%s')rrrwarningrrMrF)rWrrinvalid_extras_to_warnrs` ` r(_warn_invalid_extrasz$ExtrasCandidate._warn_invalid_extrass^"++ "+ " & 23 E NN7     r*cjjj}tfd|D}j |||S)aGet a list of valid extras requested by this candidate. The user (or upstream dependant) may have specified extras that the candidate doesn't support. Any unsupported extras are dropped, and each cause a warning to be logged here. c3lK|]+}jjj|r|-ywrO)rrCis_extra_provided)rrrWs r(rzDExtrasCandidate._calculate_valid_requested_extras..s/! yy~~//6 ! s14)r<unionrrr)rWrequested_extras valid_extrass` r(!_calculate_valid_requested_extrasz1ExtrasCandidate._calculate_valid_requested_extrassP ;;,,T-F-FG ! )!  !!"2LAr*rc#LK|jj}|j|j|sy|j}|jjj |D]0}|j t||j|Ed{2y7wrO) rrRmake_requirement_from_candidaterrCrrr9r)rWrrLrrs r(rz!ExtrasCandidate.iter_dependenciess))$$55dii@@ ==? 11,? A::A      sBB$B"B$cyrOrr\s r(rz'ExtrasCandidate.get_install_requirement)sr*)"rcrrr BaseCandidaterr9rrrXr]rdrrgrrrlrr rqrMrrFr{rrrrKrrrrrrrr*r(rrs:48 UU#U /0 U  U6EEX#X.#.CD &n&&@c@@!)!! # &d&&%T%%%Xd^%%S>~  89S> t+AV8W"2D)Er*rceZdZdZdZdeeedfddfdZde fdZ e de fdZ e de fd Ze defd Zde fd Zd edeeefd ZdeefdZy)RequiresPythonCandidateFNpy_version_info.r$c| t|}ntjdd}tdj d|D|_y)N.c32K|]}t|ywrO)r9)rcs r(rz3RequiresPythonCandidate.__init__..9s(FAQ(Fr)rsys version_infor rrU)rWrrs r(rXz RequiresPythonCandidate.__init__4s?  &1/BL++BQ/L(F(F FG r*c d|jSNzPython rUr\s r(r]zRequiresPythonCandidate.__str__?s((r*ctSrOREQUIRES_PYTHON_IDENTIFIERr\s r(rqz$RequiresPythonCandidate.project_nameB))r*ctSrOrr\s r(rMzRequiresPythonCandidate.nameFr r*c|jSrOrr\s r(rFzRequiresPythonCandidate.versionJs }}r*c d|jSr)rFr\s r(r{z(RequiresPythonCandidate.format_for_errorNs''r*rcyrr)rWrs r(rz)RequiresPythonCandidate.iter_dependenciesQsr*cyrOrr\s r(rz/RequiresPythonCandidate.get_install_requirementTrr*)rcrrrrKrrrrXr9r]rr rqrMrrFr{rrrrrrrr*r(rr0sLKHsCx(AHdH))*n***c**)(#(t+AV8W2D)Er*r):loggingrtypingrrrrrrr r pip._vendor.packaging.utilsr r pip._vendor.packaging.versionr pip._internal.exceptionsrrrpip._internal.metadatarpip._internal.models.linkrrpip._internal.models.wheelrpip._internal.req.constructorsrrpip._internal.req.req_installr&pip._internal.utils.direct_url_helpersrpip._internal.utils.miscrrrrrrrLr getLoggerrcrrrr)r?rBrHrJr"r!r rrrr*r(rsC XXXI1 4<,=G;GG   8 $ ".2QR  x /F  ,2 ,( &80zzz6U66UrO:O0@ @FbibJ%i%r*