I am trying to install virtual environment on my Ubuntu and my python is 3.5. My command is:
python3 -m venv my-env/
It reminds me to install python3-venv first, but then got the following error.
apt-get install python3-venv
Reading package lists... Done
Building dependency tree
Reading state information... Done
python3-venv is already the newest version (3.5.1-3).
0 upgraded, 0 newly installed, 0 to remove and 95 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
Setting up cython3 (0.23.4-0ubuntu5) ...
Traceback (most recent call last):
File "/usr/bin/py3compile", line 34, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr, \
ImportError: No module named 'debpython'
dpkg: error processing package cython3 (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
cython3
E: Sub-process /usr/bin/dpkg returned an error code (1)
Is this because Python3.5 doesn't work with python3 -m venv
? If I can't upgrade python3.5, what can I do?