Skip to content

Commit 622f650

Browse files
authored
Merge pull request #3355 from oddbookworm/update-debug-info-for-nogil
Updated print_debug_info to output the status of the GIL
2 parents 158dbe5 + 5bfba1d commit 622f650

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src_py/_debug.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,11 @@ def _get_platform_info():
7676
)
7777

7878
ret += f"Python:\t\t\t{platform.python_implementation()} {sys.version}\n"
79+
ret += (
80+
f"GIL Enabled:\t\t{sys._is_gil_enabled()}\n"
81+
if hasattr(sys, "_is_gil_enabled")
82+
else "GIL Enabled:\t\tTrue\n"
83+
)
7984
ret += f"pygame version:\t\t{ver}\n"
8085
return ret
8186

0 commit comments

Comments
 (0)