问题
I have installed some files (pygame
, python-docx
) through pip
. They appear in pycharm
in the site-packages
folder, but I cannot import anything from that folder. I get a ModuleNotFoundError
. The site-packages folder and sub-folders all appear as red.
Any ideas what I should do?
I have python 3.7
and pycharm community edition 2018.2.3
回答1:
Try to check if your current project interpreter is correct: you should see the path to your python environment where all packages are installed as shown in the picture.
python interpreter path
来源:https://stackoverflow.com/questions/52621583/pycharm-site-packages-folder-marked-red-and-modules-cannot-be-imported