报错:
The virtual environment was not created successfully because ensurepip is not
available. On Debian/Ubuntu systems, you need to install the python3-venv
package using the following command.
apt-get install python3-venv
You may need to use sudo with that command. After installing the python3-venv
package, recreate your virtual environment.
Failing command: ['/home/hanqing/xm/ssd_object-1/ssd-object-ven/bin/python', '-Im', 'ensurepip', '--upgrade', '--default-pip']
解决:python的版本问题,如我使用python3.5.6,则使用
sudo apt-get install python3.5-venv
完成后再使用
python3 -m venv 跟环境名称
成功!!
source 环境名称/bin/activate