Home > OS >  My VS Code dont recognize the pip packages
My VS Code dont recognize the pip packages

Time:10-14

Despite im used to program stuff, im new in Python so i decide to learn by myself. So, i install VS code and python. At the moment i tryied to use stuff like tensorflow, is showing an error saying that my imports are missing.

I've already tryed to install everything again, search for a solution online and nothing worked.

If someone knows anything about how to fix this i'd be greatfull.

CodePudding user response:

Whether there are multiple versions of python in your environment, which will make the pip installed in one version of python instead of the python you are using.

Use shortcuts "Ctrl shift P" and type "Python: Select Interpreter" to choose the correct python. Then use pip install packagename to reinstall the package which you need.

Generally, we recommend people new to python to use the enter image description here

CodePudding user response:

Confirm you have downloaded python correctly:

  • Open terminal
  • Run python --version
    • (if that doesn't work try python3 --version
  • Related