Something in my windows setup is causing pygame to fail

College Instructor needs help. pygame failing after bad program install on windows..

II fear I installed a bad program that my guess has messed up my windows settings and generating lots of python issues. No problems before installing a program from China that installed Android package for Windows and changes windows language and region settings

My OS is:

Windows 11 Home, Version 25H2 (up to date as per Windows Update)

Initial issue was that programs using pygame fonts started failing (pygame was working well before bad program install) errors indicated that pygame could not find the system fonts. ( pygame error p = os.fspath(p) TypeError expected str or os.PathLike object not int). Same failure running file using IDLE, Thonny and pyCharm IDEs. Went through obvious settings (region and languages were set to Chinese) and did Windows restart. Upgraded Microsoft Visual C++ to latest available. Uninstalled IDLE, Python, Thonny and pyCharm. Restarted again. Upgraded pip to 26.1. downloaded and installed Python Install Manager from python.org. Installed python 3.14.4 without major issues. Have tried several pip commands to install pygame (specifying version and not) and consistent issue is

ERROR: Failed to build ‘pygame’ when getting requirements to build wheel

Command:

C:\Users\jr_bo>pip install pygame
Collecting pygame
Using cached pygame-2.6.1.tar.gz (14.8 MB)
Installing build dependencies … done
Getting requirements to build wheel … error
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1

In the traceback dump there are several concerning lines like

ModuleNotFoundError: No module named ‘setuptools._distutils.msvccompiler’

I am in the middle of grading student projects, some of which use pygame and would be very grateful for help resolving this issue.

Try the community edition, which is better supported:

pip install pygame-ce

pygame istalled properly with this command. Thank you!

pygame problem still present. Error trace attempting to run student’s program:

pygame-ce 2.5.7 (SDL 2.32.10, Python 3.14.4)
Traceback (most recent call last):
File “C:\Users\jr_bo\Documents\Lander1\CIS 130 Spring 2026\Final Project Stuff\Student Submissions\CONNECT4 Mueller.py”, line 130, in
cursive_font_big = pygame.font.SysFont(“lucidahandwriting”, 70)
File “C:\Users\jr_bo\AppData\Local\Python\pythoncore-3.14-64\Lib\site-packages\pygame\sysfont.py”, line 454, in SysFont
initsysfonts()
File “C:\Users\jr_bo\AppData\Local\Python\pythoncore-3.14-64\Lib\site-packages\pygame\sysfont.py”, line 356, in initsysfonts
fonts = initsysfonts_win32()
File “C:\Users\jr_bo\AppData\Local\Python\pythoncore-3.14-64\Lib\site-packages\pygame\sysfont.py”, line 80, in initsysfonts_win32
if splitext(font)[1].lower() not in OpenType_extensions:
File “”, line 244, in splitext
TypeError: expected str, bytes or os.PathLike object, not int

Pygame is known not to not support Python 3.14. You can downgrade Python to 3.13 if you want Pygame support.

Downgraded to 3.13 and error persisted. Traced a lot of code and found bad registry item. Deleted the bad item and python program using pygame now working