'Python select interpreter not found VS Code

I started using venvs on Visual Studio Code, and when I am trying to use pandas, by import pandas

it gives me this error

"Import "pandas" could not be resolved from source"

So I tried to use ctrl+shift+p to change python interpreter in vscode, I get this error

"Command Python resulted in an error (comand 'python.setInterpreter' not found).



Solution 1:[1]

I suggest 2 ways to fix this, first uninstalling and reinstalling the extensions. On Linux (and MacOS I believe), deleting ~/.vscode/extensions/ and then manually reinstalling will help. If that does not work you can try manually setting the python interpreter (see: vscode documentation on manually specifying an interpreter).

For more information, I recommend you to look through How to start debugging Python 3.6 in Visual Studio Code?

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Thamognya Kodi