Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ModuleNotFoundError: No module named 'pygame' [duplicate]

I have python 3.7 with 32bit and after I did pip install pygame, I'm still getting

ModuleNotFoundError: No module named 'pygame'

when running my code. I'm using pycharm.

like image 378
altai Avatar asked Sep 03 '25 14:09

altai


2 Answers

I would just like to add to what the first answer is saying: If you are using pycharm, it still won't work until you go to file >> settings >> >> [your project name] >> python interpreter. You will see a list of packages there. If pygame is on it, then good, else, you must double click on the field where the packages are. It leads you to a little pop up box where you can type in things. If you type in pygame, you should be able to install the package.

like image 105
fartgeek Avatar answered Sep 05 '25 16:09

fartgeek


To be sure that you installed the python3 proper module u need to use

pip3 install pygame
like image 33
Mihai Cristian Avatar answered Sep 05 '25 15:09

Mihai Cristian