I have installed virtualenv
:
pip3 install --user virtualenv
Then I was trying to create an environment for my folder with the next command:
folder_name$ python -m venv ll_env
But instead of the desired result I've got an error:
__The virtual environment was not created successfully because ensurepip is not available.
On Debian/Ubuntu systems, you need to install 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.__
However despite thr error virtualenv
folder named ll_env
created.
I have no idea why I receive this error. I'm new to Linux. I tried to check if virtualenv
exists on system with this command:
pip3 show virtualenv
And I got:
Name: virtualenv
Version: 16.0.0
Summary: Virtual Python Environment builder
Home-page: https://virtualenv.pypa.io/
Author: Ian Bicking
Author-email: ianb@colorstudy.com
License: MIT
Location: /home/just_maverick/.local/lib/python3.6/site-packages
Requires:
python3-venv
by running the commandsudo apt-get install python3-venv
? – AlexP May 27 '18 at 15:18
– Alex May 27 '18 at 15:21pip install --user virtualenv
virtualenv foldername
yet...? – sugab May 27 '18 at 15:25apt-get install python3-venv E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied) E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
– Elder Geek May 27 '18 at 17:30sudo
, maybe referring to Python modules. I believe that they are in confusion about what they have read, where it applies, and why. That's why I wanted to elicit a remembrance of said reading. – AlexP May 27 '18 at 17:51