I have a problem while running codes with Pygame. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

I have a problem while running codes with Pygame.

I am using Python 3.6.1 and I downloaded Pygame for it. When I tried if it's working it did. But when I try to run a file which contains Pygame and is downloaded from Internet it couses an error while initing. For more informations check following code (there were some bugs while adding videos in code so I transformed them in links): https://code.sololearn.com/WJWhpm5L7eAJ/?ref=app I already tried reinstalling Pygame and it didn't work. If anyone know what's wrong I will appreciate your answer.

11th Jul 2017, 2:55 PM
Tim Thuma
Tim Thuma - avatar
2 Answers
+ 9
Most likely - you named your file "pygame.py"!!! 🤦 Please rename it, otherwise the 🐍 gets confused ;)
11th Jul 2017, 4:07 PM
Kuba Siekierzyński
Kuba Siekierzyński - avatar
+ 1
Thanks Kuba you're god😄 It's working now.
11th Jul 2017, 4:14 PM
Tim Thuma
Tim Thuma - avatar