1

VS Code refuses to use the virtual environment on my Mac.
I believe it has to do with the fact that Python doesn't get added directly to the venv but as a shortcut instead.

enter image description here

How can I make it so VSCode recognizes my virtual environment?

0

2 Answers 2

1

After about 50 times of trying this, it finally worked.

"python.pythonPath": "env/venv/bin/python3.9"

Sign up to request clarification or add additional context in comments.

Comments

1

In my case I had to open the project folder on the same workspace. Than, worked. Example: I had: folderProject/app/venv. When I open the folder project and try load venv, it doen´t work. But with I open app as my workspace and venv inside app folder everything work,

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.