]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-40448: ensurepip: Do not use cache (GH-19812)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Mon, 15 Jun 2020 17:44:34 +0000 (10:44 -0700)
committerGitHub <noreply@github.com>
Mon, 15 Jun 2020 17:44:34 +0000 (10:44 -0700)
commitb46beb25e4cf213dbf46a0a0cf3f0ed134894f7d
treea7b14789ab5870e2f5c2e2e81ac6ce7685098cb0
parentaa83935a56d1fd4d72d4de5f0278a240a2d6844d
bpo-40448: ensurepip: Do not use cache (GH-19812)

ensurepip optionally installs or upgrades 'pip' and 'setuptools' using
the version of those modules bundled with Python.  The internal PIP
installation routine by default temporarily uses its cache, if it
exists.  This is undesirable as Python builds and installations may be
independent of the user running the build, whilst PIP cache location
is dependent on the user's environment and outside of the build
environment.

At the same time, there's no value in using the cache while installing
bundled modules.

This change disables PIP caching when used in ensurepip.
(cherry picked from commit 4a3a682b12f93a03888e8b59f439bc5fe30d6055)

Co-authored-by: Krzysztof Konopko <kkonopko@users.noreply.github.com>
Lib/ensurepip/__init__.py
Lib/test/test_ensurepip.py
Misc/ACKS
Misc/NEWS.d/next/Library/2020-06-15-12-22-53.bpo-40448.1dk8Bu.rst [new file with mode: 0644]