Title: CPython should not assume that pthread_self returns the same value in fork parent and child · Issue #126688 · python/cpython · GitHub
Open Graph Title: CPython should not assume that pthread_self returns the same value in fork parent and child · Issue #126688 · python/cpython
X Title: CPython should not assume that pthread_self returns the same value in fork parent and child · Issue #126688 · python/cpython
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 s...
Open Graph 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. PyTh...
X 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. PyTh...
Opengraph URL: https://github.com/python/cpython/issues/126688
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"CPython should not assume that pthread_self returns the same value in fork parent and child","articleBody":"Summarized from https://github.com/SerenityOS/serenity/issues/25263 by request of @colesbury:\r\n\r\nIt seems that at least Python 3.13 relies on pthread_self returning the same value in both the parent and the child process.\r\n[PyThread_get_thread_ident_ex](https://github.com/python/cpython/blob/3.13/Python/thread_pthread.h#L349)\r\n\r\nPOSIX doesn't seem to mention if the value returned by pthread_self should be inherited by the child process. \r\n[pthread_self](https://pubs.opengroup.org/onlinepubs/9799919799/functions/pthread_self.html)\r\n[fork](https://pubs.opengroup.org/onlinepubs/9799919799/functions/fork.html)\r\n\r\n(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.\r\n\r\nIt looks like the code add broke things is from this commit https://github.com/python/cpython/commit/e21057b99967eb5323320e6d1121955e0cd2985e added in https://github.com/python/cpython/pull/118523 as part of https://github.com/python/cpython/issues/117657\n\n\u003c!-- gh-linked-prs --\u003e\n### Linked PRs\n* gh-126692\n* gh-126765\n* gh-127121\n\u003c!-- /gh-linked-prs --\u003e\n","author":{"url":"https://github.com/nico","@type":"Person","name":"nico"},"datePublished":"2024-11-11T15:33:00.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":2},"url":"https://github.com/126688/cpython/issues/126688"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:ebb4ad39-9e84-c2eb-9024-5207674652f9 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A522:1363AF:1F320D2:2A45D22:6A599D33 |
| html-safe-nonce | 2da468fe6ba9a79f538d262a8bc65c77d50732d94bd36d8d95b097392e945e09 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNTIyOjEzNjNBRjoxRjMyMEQyOjJBNDVEMjI6NkE1OTlEMzMiLCJ2aXNpdG9yX2lkIjoiNzQ2NTk1MjIzOTUxNTQ0MjQ4MyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 81bf2f39a8a9c9d93e61befdba003ea2463530bfbb313e672de5ea1b3dd70751 |
| hovercard-subject-tag | issue:2649681175 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/cpython/126688/issue_layout |
| twitter:image | https://opengraph.githubassets.com/af2b08db9a5d6b2d691a6bf831f7fc33e4b73d01ed9a140a9de592eb3b5b7b14/python/cpython/issues/126688 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/af2b08db9a5d6b2d691a6bf831f7fc33e4b73d01ed9a140a9de592eb3b5b7b14/python/cpython/issues/126688 |
| og:image:alt | 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. PyTh... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | nico |
| hostname | github.com |
| expected-hostname | github.com |
| None | a540949572872b935b393b36db38922db390ae71c859537d741b8f3eb7e545b5 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 737e0bf019c29d8431b268ae84d528b052789210 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width