Does ensurepip still have to include a copy of setuptools?
Hi everyone, ensurepip includes private copies of pip and setuptools. But PEP 453 states that "once pip is able to run pip install --upgrade pip without needing setuptools installed first, then the private copy of setuptools will be removed from ensurepip in subsequent CPython releases." https://www.python.org/dev/peps/pep-0453/#automatic-installation-of-setuptoo... At the moment pip itself includes a needed part of setuptools. https://github.com/pypa/pip/tree/9c474d4862907ae220ced0fcdbd76660955ff732/sr... I experimented with modifying ensurepip in the main branch not to install setuptools, and then used it to install pip. It worked fine. Then I run `./python -m pip install --upgrade pip`, and it upgraded pip successfully. Does this mean that we can drop the copy of setuptools? Note, the venv module has such code `CORE_VENV_DEPS = ('pip', 'setuptools')`. I am not sure whether it requires setuptools from ensurepip. Thanks, Illia
participants (5)
-
Antoine Pitrou
-
Illia Volochii
-
Nick Coghlan
-
Paul Moore
-
Thomas Grainger