File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed
src/pip/_internal/resolution/resolvelib Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change 1- Include user-supplied constraints in dependency conflict resolution logs for consistency with error reporting .
1+ Include relevant user-supplied constraints in logs when reporting dependency conflicts .
Original file line number Diff line number Diff line change @@ -100,6 +100,15 @@ def __init__(
100100 self ._upgrade_strategy = upgrade_strategy
101101 self ._user_requested = user_requested
102102
103+ @property
104+ def constraints (self ) -> dict [str , Constraint ]:
105+ """Public view of user-specified constraints.
106+
107+ Exposes the provider's constraints mapping without encouraging
108+ external callers to reach into private attributes.
109+ """
110+ return self ._constraints
111+
103112 def identify (self , requirement_or_candidate : Requirement | Candidate ) -> str :
104113 return requirement_or_candidate .name
105114
Original file line number Diff line number Diff line change @@ -87,7 +87,7 @@ def resolve(
8787 if "PIP_RESOLVER_DEBUG" in os .environ :
8888 reporter : BaseReporter [Requirement , Candidate , str ] = PipDebuggingReporter ()
8989 else :
90- reporter = PipReporter (constraints = provider ._constraints )
90+ reporter = PipReporter (constraints = provider .constraints )
9191
9292 resolver : RLResolver [Requirement , Candidate , str ] = RLResolver (
9393 provider ,
You can’t perform that action at this time.
0 commit comments