Your IP : 3.23.103.203


Current Path : /opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/
Upload File :
Current File : //opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pyc

�
�Rec@s�ddlZddlZddlmZddlmZddlmZmZddlm	Z
ddlmZddl
mZddlmZdd	lmZdd
lmZddlmZddlmZd
dlmZd
dlmZer�ddlmZmZm Z m!Z!m"Z"ddl#m$Z$ddl%m&Z&ddl'm(Z(ddl)m*Z*ddl+m,Z,ddl
m-Z-ddlm.Z.nej/e0�Z1defd��YZ	d�Z2d�Z3dS(i����N(tsix(tcanonicalize_name(tBaseReportertResolutionImpossible(tResolver(tInstallationError(tcheck_invalid_constraint_type(tRequirementSet(tBaseResolver(tPipProvider(tdist_is_editable(tMYPY_CHECK_RUNNINGi(t
Constraint(tFactory(tDicttListtOptionaltSettTuple(tResult(tGraph(t
WheelCache(t
PackageFinder(tRequirementPreparer(tInstallRequirement(tInstallRequirementProviderRcBs8eZdddhZded�Zd�Zd�ZRS(teagersonly-if-neededsto-satisfy-onlyc

Cs�tt|�j�|r)tjd�n|
|jks>t�td|d|d|d|d|d|	d|d	|d
|d|�
|_||_	|
|_
d|_dS(Ns�pip is using lazily downloaded wheels using HTTP range requests to obtain dependency information. This experimental feature is enabled through --use-feature=fast-deps and it is not ready for production.tfindertpreparertmake_install_reqtwheel_cachet
use_user_sitetforce_reinstalltignore_installedtignore_requires_pythontpy_version_infot
lazy_wheel(
tsuperRt__init__tloggertwarningt_allowed_strategiestAssertionErrorR
tfactorytignore_dependenciestupgrade_strategytNonet_result(
tselfRRRRRR,R!R"R R-R#R$((s�/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pyR&'s&
		cCs�i}t�}g}x�|D]�}|jr�t|�}|rLt|��n|j�s^qnt|j�}||kr�||c|M<qtj|�||<q|j	r�|jr�|j
t|j��n|jj|dd�}	|	dk	r|j|	�qqWtd|jd|d|jd|jd|�}
t�}t|
|�}y"d}
|j|d|
�|_Wn5tk
r�}|jj|�}tj||�nXtd	|�}x$|jjj�D]}|j�}|dkr�q�n|jj|�}|dkrt|_ nZ|jj!r/t"|_ nB|j#|j$krMt"|_ n$t%|�|j&kr�t"|_ nq�|j'}|r�|j(r�d
j)d|jd|j$d
|d|j*p�d�}t+j,|�n|j-|�q�W|S(Ntrequested_extrasR+tconstraintsR,R-tuser_requestedi��t
max_roundstcheck_supported_wheelsu�The candidate selected for download or install is a yanked version: {name!r} candidate (version {version} at {link})
Reason for being yanked: {reason}tnametversiontlinktreasonu<none given>((.tsett
constraintRRt
match_markersRR6Rt	from_ireqt
user_suppliedtaddR+t!make_requirement_from_install_reqR.tappendR	R,R-Rt
RLResolvertresolveR/Rtget_installation_errorRt
raise_fromRtmappingtvaluestget_install_requirementtget_dist_to_uninstalltFalsetshould_reinstallR tTruetparsed_versionR7R
tis_editabletsource_linkt	is_yankedtformatt
yanked_reasonR'R(tadd_named_requirement(R0t	root_reqsR5R2R3trequirementstreqtproblemR6trtprovidertreportertresolvert try_to_avoid_resolution_too_deepteterrortreq_sett	candidatetireqtinstalled_distR8tmsg((s�/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pyRCQsx	
							
				cCs�|jdk	std��|jj}t|�}t|jj�dtj	t
d|�dt�}g|D]\}}|^qjS(sGet order for installation of requirements in RequirementSet.

        The returned list contains a requirement before another that depends on
        it. This helps ensure that the environment is kept consistent as they
        get installed one-by-one.

        The current implementation creates a topological ordering of the
        dependency graph, while breaking any cycles in the graph at arbitrary
        points. We make no guarantees about where the cycle would be broken,
        other than they would be broken.
        smust call resolve() firsttkeytweightstreverseN(R/R.R*tgraphtget_topological_weightstsortedRUtitemst	functoolstpartialt_req_set_item_sorterRL(R0R_RgRetsorted_itemst_Ra((s�/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pytget_installation_order�s
	N(t__name__t
__module__R)R.RJR&RCRp(((s�/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pyR$s
	^csit��i�����fd���d��ddksGt�t��t��kset��S(s�Assign weights to each node based on how "deep" they are.

    This implementation may change at any point in the future without prior
    notice.

    We take the length for the longest path to any node from root, ignoring any
    paths that contain a single node twice (i.e. cycles). This is done through
    a depth-first search through the graph, while keeping track of the path to
    the node.

    Cycles in the graph result would result in node being revisited while also
    being it's own path. In this case, take no action. This helps ensure we
    don't get stuck in a cycle.

    When assigning weight, the longer path (i.e. larger length) is preferred.
    cs}|�krdS�j|�x!�j|�D]}�|�q-W�j|��j|d�}t|t����|<dS(Ni(R?t
iter_childrentremovetgettmaxtlen(tnodetchildtlast_known_parent_count(RgtpathtvisitRe(s�/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pyR|�s

iN(R:R.R*Rw(Rg((RgR{R|Res�/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pyRh�s	
cCst|d�}|||fS(s)Key function used to sort install requirements for installation.

    Based on the "weight" mapping calculated in ``get_installation_order()``.
    The canonical package name is returned as the second member as a tie-
    breaker to ensure the result is predictable, which is useful in tests.
    i(R(titemReR6((s�/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pyRm�s(4Rktloggingtpip._vendorRtpip._vendor.packaging.utilsRtpip._vendor.resolvelibRRRRBtpip._internal.exceptionsRtpip._internal.req.req_installRtpip._internal.req.req_setRtpip._internal.resolution.baseRt,pip._internal.resolution.resolvelib.providerR	tpip._internal.utils.miscR
tpip._internal.utils.typingRtbaseRR+R
ttypingRRRRRt pip._vendor.resolvelib.resolversRtpip._vendor.resolvelib.structsRtpip._internal.cacheRt"pip._internal.index.package_finderRt pip._internal.operations.prepareRRRt	getLoggerRqR'RhRm(((s�/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.pyt<module>s6(�	.

?>