0
votes

I have a Python project set up in a virtualenv that I created directly from the terminal. When I try to open it in PyCharm, I am able to see the files, but I can't change the project interpreter to use my virtualenv. I am able to see the python executable file both through the WSL terminal and the Windows File Explorer, but when I try to add it as a project interpreter from PyCharm, I am unable to find it.

I have tried deleting my .idea directory and adding the project to PyCharm again. I have tried creating a new project in PyCharm using my project's root directory. I have tried editing the SDK_HOME variable in .idea/workspace.xml to be the location of the python executable, but it didn't change the project interpreter.

Anyone have any ideas?

I am using WSL for the terminal and Windows 10 for my OS.

1
The problem is that it doesn't show up in that drop-down list. - inavda
I have tried adding a project interpreter the normal way already, but it doesn't work. The "ok" button is grayed out. - inavda
What is the virtual env path - electrodragon

1 Answers

0
votes

It is probably because what you have is a symlink and not a copy of the interpreter. Try creating the environment by adding the --copies option:

virtualenv myenv --copies