Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Native virtualenv support for shell configurations #403
added a commit
Feb 3, 2017
referenced this issue
Feb 3, 2017
I just started using virtualenv and hit the similar problem. To my understanding, the virtualenv
VIRTUAL_ENV="/path/to/venv" export VIRTUAL_ENV PATH="$VIRTUAL_ENV/bin:$PATH" export PATH
(in fact it does more fancy stuff to unset those variables when deactivating the env, which is not important here). Bottomline: I don't know what the VIRTUAL_ENV does and if it is really necessary... does anyone know if we need it?
So to mimic the same in Pyzo, all is needed is to set PATH to contain venv's bin directory. This can be done by filling the environ field of Shell config dialog. Then the exe filed in the shell config can be just
@jpauwels entering directly the full path of the python binary from withing the venv directly into the exe field without setting the PATH is cumbersome. E.g., if some of your libraries inside the venv launches another python script using
If others agree this is the correct solution for using virtualenv from within Pyzo I would be for noting this in the official documentation so it is easier do discover it for a user without the deeper knowledge of virtualenv internals.