update install.sh to use a python virtual environment #1080
november781
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
currently the automatic install script on Linux runs
pip install
with the requirements file in the default system environment unless the user activates a virtual environment before executing install.sh.I personally think it would be better practice to have the install script create a virtual environment for the user and activate it before calling pip install to avoid module conflicts with other system resources and other projects.
virtual enviroments are built into python 3.4 and above with the venv command and since the project seems to be targeting 3.8+ at least, it shouldn't be an issue.
creating a virtual environment can be done with
python -m venv {environment_name}
and can be activated withsource {environment_name}/bin/activate
before runningpip install
in the script and that should cover anyone running install.shby using a virtual environment you could drop the --user flag from pip install
Beta Was this translation helpful? Give feedback.
All reactions