Reputation: 9
Pygame module is installed but not working.
ImportError: No module named 'pygame.locals'; 'pygame' is not a package
it worked when I import it in idle without creating a file but not working when .py file is executed through interpreter
Upvotes: 0
Views: 77
Reputation: 369274
Make sure that you're not using pygame.py
as a script filename. It will prevent the import of pygame
module you want.
Rename the file not to conflict. Also make sure there's no remaning pygame.pyc
file.
Upvotes: 1