This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author kcdodd
Recipients kcdodd
Date 2021-12-29.23:24:11
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1640820251.78.0.719610352005.issue46197@roundup.psfhosted.org>
In-reply-to
Content
A change in behavior was made to the `ensurepip` module in Python 3.8.7 that causes bootstrapping to break out of an isolated environment. This is relevant to the assumption made in the `venv` module, which ran ensurepip as a sub-process with the `-I` flag environment isolation to force installation in the virtual environment directory.

In Python <= 3.8.6, ensurepip ran the bootstrap within the current interpreter, so the environment remained isolated. But in Python >= 3.8.7 it creates a second subprocess without the `-I` flag, and the un-isolated environment appears to be restored for pip. This would then allow a search of any additional paths, and prevent installation of pip and setuptools from being installed in the venv environment directory if they are found somewhere else.
History
Date User Action Args
2021-12-29 23:24:11kcdoddsetrecipients: + kcdodd
2021-12-29 23:24:11kcdoddsetmessageid: <1640820251.78.0.719610352005.issue46197@roundup.psfhosted.org>
2021-12-29 23:24:11kcdoddlinkissue46197 messages
2021-12-29 23:24:11kcdoddcreate