Skip to content

Commit dad133e

Browse files
committed
add repr to RequiresPythonCandidate
1 parent 2a3e2fd commit dad133e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/pip/_internal/resolution/resolvelib/candidates.py

+3
Original file line numberDiff line numberDiff line change
@@ -552,6 +552,9 @@ def __init__(self, py_version_info: Optional[Tuple[int, ...]]) -> None:
552552
def __str__(self) -> str:
553553
return f"Python {self._version}"
554554

555+
def __repr__(self) -> str:
556+
return f"{self.__class__.__name__}({self._version!r})"
557+
555558
@property
556559
def project_name(self) -> NormalizedName:
557560
return REQUIRES_PYTHON_IDENTIFIER

0 commit comments

Comments
 (0)