Skip to content

use virtualenv instead of python -m venv for ubuntu installation #853

@shelper

Description

@shelper

I don't have sudo access on ubuntu 20.04 and i try to use pipx to setup some tools for me, e.g., pipx install poetry.
However, I got error

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/username/.local/pipx/shared/bin/python3', '-Im', 'ensurepip', '--upgrade', '--default-pip']


'/usr/bin/python3 -m venv --clear /home/username/.local/pipx/shared' failed

Later I figured out that i need to use virtualenv instead of /usr/bin/python3 -m venv., so i first run
virtualenv --clear /home/username/.local/pipx/shared, then run pipx install poetry, everything worked.

So the feature i am requesting is to add suppor to use virtualenv tool directly so pipx works on ubuntu without this error of ensurepip not found

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions