Python 3 virtualenvs

Laura Creighton lac at openend.se
Sun Nov 29 09:12:20 EST 2015


In a message of Sun, 29 Nov 2015 13:23:19 +0000, Jon Ribbens writes:
>I don't know if, in future, pyvenv will be the way to go and
>virtualenv will be deprecated, but either way we do not appear
>to be there yet.

pyenv is going away.  python -m venv is the preferred way to get a venv

https://bugs.python.org/issue25154

Of course if you try it, you may get:

  Error: Command '['<directory>/bin/python3.4', '-Im', 'ensurepip', '--upgrade', '--default-pip']' returned non-zero exit status 1

which turns out to mean:

Your Python isn't configured with ensure-pip!

.....

Right now, I personally don't know why there is a venv at all.  Despite
the similarity of names, it doesn't seem to be about doing what virtualenv
does.  I think it is only meant to be used by people who want to install
packages but not site-wide, but I am not sure about that.  I don't think
there are any plans to give venv the functionality of virtualenv, so
presumably there are people who like it just fine the way it is now.
They must have very different needs than I do.

Laura



More information about the Python-list mailing list