Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem for pipenv with conda #4545

Closed
AlekseiKhatkevich opened this issue Nov 25, 2020 · 3 comments
Closed

Problem for pipenv with conda #4545

AlekseiKhatkevich opened this issue Nov 25, 2020 · 3 comments

Comments

@AlekseiKhatkevich
Copy link

AlekseiKhatkevich commented Nov 25, 2020

In your documentation it said that it is possible to use Pipenv with conda:

https://pipenv.pypa.io/en/latest/advanced/#pipenv-and-other-python-distributions

But it does not work even on a freshly created project:

Expected result - Pipenv would install packages inside Conda envirment and would use conda python interpreter.

Actual result - error during Pipenv initializations

python console

import sys
sys.executable
'C:\\ProgramData\\Miniconda3\\envs\\new_project\\python.exe'

terminal

pipenv install --python=C:\\ProgramData\\Miniconda3\\envs\\new_project\\python.exe

# result

Creating a virtualenv for this project...
Pipfile: C:\Users\hardcase1\PycharmProjects\new_project\Pipfile
Using c:/programdata/miniconda3/envs/new_project/python.exe (3.7.9) to create virtualenv...
[=== ] Creating virtual environment...FileNotFoundError: [Errno 2] No such file or directory: 'c:\\programdata\\miniconda3\\envs\\new_pr
oject\\Lib\\venv\\scripts\\nt\\python.exe'

Failed creating virtual environment

[pipenv.exceptions.VirtualenvCreationException]:
Failed to create virtual environment.

pipenv, version 2020.11.15
conda 4.8.5
Windows 10
python 3.7.9

Would be glad to have this possible bug fixed or point me out what i did wrong if so.

I use Pipenv over 2 years already. Great tool.

Thank you

@Mause
Copy link

Mause commented Nov 25, 2020

Have you tried directing pipenv to use a python.exe that isn't part of an existing virtual environment?

@AlekseiKhatkevich
Copy link
Author

AlekseiKhatkevich commented Nov 26, 2020

Yes. This way it works correctly. Also i have tried install Pipenv inside Conda via 'conda install pipenv' and run it from there. Same error.

@drewgilliam
Copy link

FYI - conda and virtualenv 20.0.34+ don't play well together, see ContinuumIO/anaconda-issues#12094 and pypa/virtualenv#1986. The current suggested workaround is to downgrade to virtualenv 20.0.33.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants