Title: PyCell_GET/SET are not thread-safe in free-threaded builds · Issue #127271 · python/cpython · GitHub
Open Graph Title: PyCell_GET/SET are not thread-safe in free-threaded builds · Issue #127271 · python/cpython
X Title: PyCell_GET/SET are not thread-safe in free-threaded builds · Issue #127271 · python/cpython
Description: Bug report Bug description: The PyCell_GET and PyCell_SET macros are not safe for free-threading builds. First, they don't the correct locking. Second, PyCell_GET returns a borrowed reference. For CPython internals, the usages of these m...
Open Graph Description: Bug report Bug description: The PyCell_GET and PyCell_SET macros are not safe for free-threading builds. First, they don't the correct locking. Second, PyCell_GET returns a borrowed reference. For ...
X Description: Bug report Bug description: The PyCell_GET and PyCell_SET macros are not safe for free-threading builds. First, they don't the correct locking. Second, PyCell_GET returns a borrowed reference. ...
Opengraph URL: https://github.com/python/cpython/issues/127271
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"PyCell_GET/SET are not thread-safe in free-threaded builds","articleBody":"# Bug report\n\n### Bug description:\n\nThe `PyCell_GET` and `PyCell_SET` macros are not safe for free-threading builds. First, they don't the correct locking. Second, `PyCell_GET` returns a borrowed reference.\n\nFor CPython internals, the usages of these macros can be replaced (either with `PyCell_GetRef()`, `PyCell_SetTakeRef()`, or similar). For external API users, these macros will need to be marked as deprecated, at least for free-threaded builds.\n\n\n### CPython versions tested on:\n\nCPython main branch\n\n### Operating systems tested on:\n\n_No response_\n\n\u003c!-- gh-linked-prs --\u003e\n### Linked PRs\n* gh-127272\n* gh-130383\n\u003c!-- /gh-linked-prs --\u003e\n","author":{"url":"https://github.com/nascheme","@type":"Person","name":"nascheme"},"datePublished":"2024-11-25T21:58:15.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/127271/cpython/issues/127271"}
| 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:e376e12f-56ef-e1b3-41ec-6e09dc1db671 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E15E:A5979:1563918:1F152A9:6A562E31 |
| html-safe-nonce | 26b082f78a21b5c15413df28241a4ab939ac58f1bef9015d42f22e9d44ae685c |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMTVFOkE1OTc5OjE1NjM5MTg6MUYxNTJBOTo2QTU2MkUzMSIsInZpc2l0b3JfaWQiOiI1Mjc3MzgwNzQzOTI4MzYwNDk3IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | cf16d23f24cfc283396166e07232d487c70ddf6f6e7598b397e504673db143c4 |
| hovercard-subject-tag | issue:2692389195 |
| 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/127271/issue_layout |
| twitter:image | https://opengraph.githubassets.com/7a61232899e90e3900a6960a2296fda4d1d50daaf174a183205d2069d02c008c/python/cpython/issues/127271 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/7a61232899e90e3900a6960a2296fda4d1d50daaf174a183205d2069d02c008c/python/cpython/issues/127271 |
| og:image:alt | Bug report Bug description: The PyCell_GET and PyCell_SET macros are not safe for free-threading builds. First, they don't the correct locking. Second, PyCell_GET returns a borrowed reference. For ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | nascheme |
| hostname | github.com |
| expected-hostname | github.com |
| None | 9d78ea552aac0685ca5f006d44f88166cbbf3bb96843f8da0c5a2c0b9908430b |
| 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 | 160a6fceec0fef718a0c3ac46f2d71ae9d5c0ff5 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width