Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

pipenv only installs .venv in home directory

Tags:

python

pipenv

Trying pipenv for the first time:

> cd ~
> mkdir foo
> cd foo
> pipenv install
> pipenv --venv
> [/Users/richardlyon/.venv]
> cd ..
> mkdir bar
> cd bar
> pipenv install
> pipenv --venv
> [/Users/richardlyon/.venv]

I cannot relate this to my reading of the pipenv manual, which suggests that a separate virtual environment should created for each directory in which pipenv is invoked. Nor can I see the advantage of this arrangement.

Could anyone shed any light? Thank you.

like image 252
Richard Lyon Avatar asked Jul 13 '18 16:07

Richard Lyon


Video Answer


1 Answers

OK. Looks like fiddling around had created file Pipfile in the root which was making pipenv treat root as an existing virtual environment. Deleting it fixed the problem.

Leaving this here in case anyone else (new) comes across this - it didn't show up as an issue in a web search.

like image 191
Richard Lyon Avatar answered Oct 08 '22 19:10

Richard Lyon