简体   繁体   中英

VS Code doesn't see the installed modules

For some reason VS Code asked me to choose the default program for running code, I missed and chose NotePad. When I would hit "run" all it would do is open Notepad. Then I changed the default app to VS Code (in Windows settings), and nothing would happen after hitting "run".

I reinstalled VS Code. Now it doesn't see the installed modules (from PyPi):

ModuleNotFoundError: No module named 'pandas'

The modules are installed and were seen in the past (before I accidentally changed the settings).

You need to select the correct python interpreter version and try importing pandas again. If it doesn't work then you need install pandas using python version used by your VS Code. You can do this by opening terminal in VS Code and executing the following command

python3 -m pip install pandas

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM