0

My previous Pycharm has broken, and I update my Pycharm to newest version.

However when I run the existing python code, I have met following error message.

Connected to pydev debugger (build 213.7172.26)
Traceback (most recent call last):
  File "<frozen importlib._bootstrap>", line 983, in _find_and_load
  File "<frozen importlib._bootstrap>", line 965, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'numpy'

Process finished with exit code 1
Xusong
  • 9
  • 1

1 Answers1

0

How are you running the program? If it is from the terminal, run pip freeze and then you can see if numpy is in the printed output. If not, run pip install numpy.

However, if you are running it from the run button, click on python packages at the bottom and check that numpy is installed.

Westsi
  • 142
  • 2
  • 10
  • You could improve formatting by backticks around your code example – soundstripe Apr 12 '22 at 13:31
  • Westsi, Thanks for your answer. I just ran across solution accidently. I just open the file "C:\Program Files\JetBrains\PyCharm Community Edition 2021.3.3\plugins\python-ce\helpers\pydev\pydevd.py" with Pycharm editor. After I re-run the job. It is ok already. I do not whether above action is the correct answer. For me, the issue is gone. – Xusong Apr 12 '22 at 15:46