4

I've been using a python interpreter that I set in my venv the whole time for this project. Recently I changed my python interpreter which I've set as a default interpreter in my user settings like the vs docs vs code python environments describes it and also set in my JSON settings file refuses to load instead. I'm getting the default conda python interpreter with no other options.

here is my Json file:

settings.json

{
  "python.defaultInterpreterPath": "C:/Users/houst/Envs/Mach/Scripts/python.exe"
}
OneCricketeer
  • 179,855
  • 19
  • 132
  • 245

1 Answers1

1

I think you should use the \ instead of the / in the path. For safety just copy paste the path from the windows explorer.
Another Solution : Writing the path in Json should definitely work. But I prefer using the functionality vscode provides. Now come to my solution. press ctrl+shift+p to open the search bar. now type >Python:Select Interpreter. This should allow you to select the existing interpreter or to add the interpreter path in the vscode. I'm attaching a screen shot for your convenient.

VsCode Python Interpreter

You should keep in mind that, if you add the Python interpreted path in environment path of your system, vscode should automatically find the interpreter.

Sifat Amin
  • 1,091
  • 6
  • 15