Skip to content Skip to sidebar Skip to footer

Pyvenv Installs Wrong Pip Version

I'm creating a virtualenv with pyvenv env but the installed pip version is outdated. I can manually update pip in the virtual env but I would like to have the correct version autom

Solution 1:

You can upgrade pip in a virtual environment manually by executing

pip install -U pip

You are facing this problem, because venv uses ensurepip to add pip into new environments:

Unless the --without-pip option is given, ensurepip will be invoked to bootstrap pip into the virtual environment.

Ensurepip package won't download from the internet or grab files from anywhere else, because all required components are already included into the package. Doing so would add security flaws and is thus unsupported.

Ensurepip is not designed to give you the newest pip, but just "a" pip. To get the newest one use the manual way at the beginning of this post.

Post a Comment for "Pyvenv Installs Wrong Pip Version"