Python 3.12 testing
Brian Inglis
Brian.Inglis@SystematicSW.ab.ca
Sun Apr 6 20:58:05 GMT 2025
On 2025-04-06 14:32, dwes1--- via Cygwin wrote:
> To the Python maintainer and anyone else testing Python 3.12:
>
> A few weeks ago, the python developer requested help with evaluating the Python
> 3.12 release.
> I downloaded the python312-test package, and worked out that
> python -m test.test_threading -v
> failed during the second test in the file, sometimes with an immediate segfault,
> sometimes by hanging
> until I tried to attach gdb, which immediately reported an empty stack and a
> null stack pointer.
>
> Adding print calls to the test narrowed the point of failure to some time during
> thread cleanup,
> so I ran the test under gdb, adding breakpoints to pthread_exit and
> pthread::exit, which caught
> the test before the segfault, and displayed a stack working back to
> pthread_wrapper, whose caller
> was set to null. Stepping through the function eventually reached a call to
> ExitThread, then the
> segfault with no reported stack.
>
> My current guess is that ExitThread somehow returns, leading to control falling
> off the end of
> pthread_wrapper and failing to return. (This is rather more sensible than my
> previous guess
> that Python had somehow managed to call the NULL pointer recursively, and not
> noticed until
> gdb took a look at things) I suppose I could try to compile Cygwin with an
> error message after
> ExitThread to see if that prints, but I am otherwise out of ideas.
>
> I first checked this around January on a Windows 10 machine from 2016, then on a
> machine from
> within the last year that is says it is also Windows 10.
>
> I hope this helps
Thanks for helping!
Have you tried running under strace and looking at the output from:
$ strace -o python-312-test-threading.strace python -m test.test_threading -v
or
$ strace -o python-312-test-threading-hung.strace -p PID
--
Take care. Thanks, Brian Inglis Calgary, Alberta, Canada
La perfection est atteinte Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add
mais lorsqu'il n'y a plus rien à retrancher but when there is no more to cut
-- Antoine de Saint-Exupéry
More information about the Cygwin
mailing list