Closed
Description
Summarized from SerenityOS/serenity#25263 by request of @colesbury:
It seems that at least Python 3.13 relies on pthread_self returning the same value in both the parent and the child process.
PyThread_get_thread_ident_ex
POSIX doesn't seem to mention if the value returned by pthread_self should be inherited by the child process.
pthread_self
fork
(It is the case on Linux, Hurd, FreeBSD, OpenBSD, Cygwin. It isn't on SerenityOS, and also not on Solaris 9/HP-UX 11 per https://bugs.python.org/issue7242.
It looks like the code add broke things is from this commit e21057b added in #118523 as part of #117657