From bf64a582f00a030fee11b7f89c6a02ea967990ca Mon Sep 17 00:00:00 2001 From: Peter Bierma Date: Mon, 13 Jan 2025 09:36:54 -0500 Subject: gh-128400: Only show the current thread in `Py_FatalError` on the free-threaded build (#128758) --- Python/pylifecycle.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Python/pylifecycle.c') diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c index 8a15a09a01d..9a8a92aaceb 100644 --- a/Python/pylifecycle.c +++ b/Python/pylifecycle.c @@ -3034,7 +3034,11 @@ _Py_FatalError_DumpTracebacks(int fd, PyInterpreterState *interp, PUTS(fd, "\n"); /* display the current Python stack */ +#ifndef Py_GIL_DISABLED _Py_DumpTracebackThreads(fd, interp, tstate); +#else + _Py_DumpTraceback(fd, tstate); +#endif } /* Print the current exception (if an exception is set) with its traceback, -- cgit v1.2.3