Pipenv cannot create bin folder Ubuntu 22.04 LTS

Viewed 690

I'm trying to setup Pipenv on Ubuntu 22.04 LTS and I used:

sudo apt install pipenv

but I get an error:

FileNotFoundError: [Errno 2] No such file or directory: '/home/foo/.local/share/virtualenvs/hello-JDpq8NmY/bin/python'

I tried to update pip with:

curl -sS https://bootstrap.pypa.io/get-pip.py | python3.10

Still no use.

I tried the solution suggested here and nothing changed.

The environment is there but the bin folder is missing.

2 Answers

I had the same problem. Remove pipenv from apt package manager and install pipenv with

pip install pipenv

After this you must set your PATH Variable to the pip dictionary.

A possible problem is related to pipenv not finding the python executable.

If this is your case is it possible to specify the path

pipenv install --python=/usr/bin/python3.10

Replace the path with desired python version

source

Related