Skip to content

Commit 572ffc5

Browse files
committed
Remove deprecated sdist reinstall feature for 21.2
1 parent 239a307 commit 572ffc5

File tree

2 files changed

+5
-14
lines changed

2 files changed

+5
-14
lines changed

news/10199.removal.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
New resolver: A source distribution is no longer re-installed automatically if
2+
the currently installed has the same version number. This behaviour has been
3+
deprecated since pip 20.3.

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

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
PipDebuggingReporter,
2020
PipReporter,
2121
)
22-
from pip._internal.utils.deprecation import deprecated
2322
from pip._internal.utils.filetypes import is_archive_file
2423

2524
from .base import Candidate, Requirement
@@ -141,19 +140,8 @@ def resolve(
141140
and candidate.source_link.ext != ".zip"
142141
)
143142
if looks_like_sdist:
144-
# is a local sdist -- show a deprecation warning!
145-
reason = (
146-
"Source distribution is being reinstalled despite an "
147-
"installed package having the same name and version as "
148-
"the installed package."
149-
)
150-
replacement = "use --force-reinstall"
151-
deprecated(
152-
reason=reason,
153-
replacement=replacement,
154-
gone_in="21.2",
155-
issue=8711,
156-
)
143+
# is a local sdist -- skip
144+
continue
157145

158146
# is a local sdist or path -- reinstall
159147
ireq.should_reinstall = True

0 commit comments

Comments
 (0)