After installing python3
1. Install virtualenv with PIP3
pip3 install -i https://pypi.tuna.tsinghua.edu.cn/simple virtualenv
The above image has been installed successfully
2. Virtualenv: command not found
3. Add environment variable to solve the problem
(1) Using find/- name ‘ virtualenv.py ‘does it exist
It can be found in the figure below
(2) Add environment variable
Steps:
vim /etc/profile
# Add the following to the bottom of the file
PATH=$PATH:/usr/local/python3/bin
# is the command added to take effect
source /etc/profile
# Finally, check if the file was added successfully
echo $PATH
Example card:
(3)Reuse virtual env
# Use virtualenv to create a python3 environment with the command demo1
virtualenv --python=/usr/bin/python3 demo1
# Go to /demo1/bin under the virtual slow directory and start the virtual environment with the command
source activate
Similar Posts:
- Super detail: command not found: the scratch solution (add the scratch environment variable to Zsh under MAC)
- CentOS Error -bash:systemctl:command not found
- ImportError: Couldn’t import Django [How to Solve]
- Linux use the man command error: Man: command not found [How to Solve]
- Solution to fatal error in launcher: unable to create process using ‘”‘In PIP installation
- [Solved] Python virtual environment install Error: returned non zero exit status 1
- Solution to error reporting of CONDA virtual environment due to system environment variables
- Using the jupyter notebook (error/usr/bin/python3: no module named ipykernel) on the local browser remote server_ launcher)
- centos ModuleNotFoundError: No module named ‘_sqlite3’