I'm using Ubuntu 20.04.4 LTS. When I try
python3 -m venv env, I get:
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 install python3.8-venv You may need to use sudo with that command. After installing the python3-venv package, recreate your virtual environment. Failing command: ['/home/ubuntu/env/bin/python3', '-Im', 'ensurepip', '--upgrade', '--default-pip']
Then I tried:
sudo apt-get update sudo apt-get install python3.8-venv
and got this output
Reading package lists... Done Building dependency tree... Done Reading state information... Done Package python3.8-venv is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package 'python3.8-venv' has no installation candidate
If that package is not available any more, I want to know how can I be able to create a virtual environment (the package
python3-pip is also missing, so
pip is also not available).
The only way I could create a virtual environment is using
conda, but I want to avoid that.