René's URL Explorer Experiment


Title: [C API] Deprecate _Py_Identifier API · Issue #142217 · python/cpython · GitHub

Open Graph Title: [C API] Deprecate _Py_Identifier API · Issue #142217 · python/cpython

X Title: [C API] Deprecate _Py_Identifier API · Issue #142217 · python/cpython

Description: I propose to deprecate the private _Py_Identifier API. Deprecate private _PyObject_CallMethodId(), _PyObject_GetAttrId(), _PyUnicode_FromId(). Remove immediately internal functions using _Py_Identifier. See also the discussions: #141049 ...

Open Graph Description: I propose to deprecate the private _Py_Identifier API. Deprecate private _PyObject_CallMethodId(), _PyObject_GetAttrId(), _PyUnicode_FromId(). Remove immediately internal functions using _Py_Identi...

X Description: I propose to deprecate the private _Py_Identifier API. Deprecate private _PyObject_CallMethodId(), _PyObject_GetAttrId(), _PyUnicode_FromId(). Remove immediately internal functions using _Py_Identi...

Opengraph URL: https://github.com/python/cpython/issues/142217

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[C API] Deprecate _Py_Identifier API","articleBody":"I propose to [deprecate the private](github.com/python/cpython/issues/141049) `_Py_Identifier` API.\n\n* Deprecate private `_PyObject_CallMethodId()`, `_PyObject_GetAttrId()`, `_PyUnicode_FromId()`.\n* Remove immediately internal functions using `_Py_Identifier`.\n\nSee also the discussions:\n\n* https://github.com/python/cpython/issues/141049\n* https://discuss.python.org/t/c-api-how-much-private-is-the-private-py-identifier-api/29190 (2023).\n* https://mail.python.org/archives/list/python-dev@python.org/thread/DNMZAMB4M6RVR76RDZMUK2WRLI6KAAYS/  (2022)\n\nSince 2022, CPython has been modified to replace `_Py_IDENTIFIER()` with `_Py_STR()`. Python no longer uses the `_Py_IDENTIFIER()` API anymore.\n\nSee also issue https://github.com/python/cpython/issues/141049 \"Deprecate private C API functions\".\n\n\u003c!-- gh-linked-prs -->\n### Linked PRs\n* gh-142219\n* gh-142221\n* gh-142746\n* gh-157638\n\u003c!-- /gh-linked-prs -->\n","author":{"url":"https://github.com/vstinner","@type":"Person","name":"vstinner"},"datePublished":"2025-12-03T11:14:45Z","url":"https://github.com/python/cpython/issues/142217"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:36bde4f4-234e-1492-a007-e3d84814b9c1
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-id9DAE:3A73AA:2BB3873:377A42B:6B01E852
html-safe-nonce8609606c47146321cebd5eab4e30dc30e8dee36e40f0b5fd4da68802b2c70c31
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5REFFOjNBNzNBQToyQkIzODczOjM3N0E0MkI6NkIwMUU4NTIiLCJ2aXNpdG9yX2lkIjoiMTg2OTM1MDQ2MjU4MzU5NzEzOSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac07cbcb73dda83ea96bb6dd190379d8c634c512ea8a1c3e89e79ac6cf5b4ad62e
hovercard-subject-tagissue:3689780111
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/cpython/142217/issue_layout
twitter:imagehttps://opengraph.githubassets.com/e69d6cb79fdfd6bffcd17ac0d7b220f1aec8837865028c67b417331c81d26fd6/python/cpython/issues/142217
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/e69d6cb79fdfd6bffcd17ac0d7b220f1aec8837865028c67b417331c81d26fd6/python/cpython/issues/142217
og:image:altI propose to deprecate the private _Py_Identifier API. Deprecate private _PyObject_CallMethodId(), _PyObject_GetAttrId(), _PyUnicode_FromId(). Remove immediately internal functions using _Py_Identi...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamevstinner
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
turbo-cache-controlno-preview
go-importgithub.com/python/cpython git https://github.com/python/cpython.git
octolytics-dimension-user_id1525981
octolytics-dimension-user_loginpython
octolytics-dimension-repository_id81598961
octolytics-dimension-repository_nwopython/cpython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id81598961
octolytics-dimension-repository_network_root_nwopython/cpython
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/python/cpython/issues/142217#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fissues%2F142217
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fissues%2F142217
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=python%2Fcpython
Reloadhttps://github.com/python/cpython/issues/142217
Reloadhttps://github.com/python/cpython/issues/142217
Reloadhttps://github.com/python/cpython/issues/142217
pythonhttps://github.com/python
cpythonhttps://github.com/python/cpython
Codehttps://github.com/python/cpython
Issues5k+ (5k+)https://github.com/python/cpython/issues
Pull requests2.4k (2.4k)https://github.com/python/cpython/pulls
Actionshttps://github.com/python/cpython/actions
Projectshttps://github.com/python/cpython/projects
Security and qualityhttps://github.com/python/cpython/security
Insightshttps://github.com/python/cpython/insights
https://github.com/python/cpython
New issuehttps://github.com/login?return_to=https://github.com/python/cpython/issues/142217
New issuehttps://github.com/login?return_to=https://github.com/python/cpython/issues/142217
[C API] Deprecate _Py_Identifier APIhttps://github.com/python/cpython/issues/142217#top
interpreter-core(Objects, Python, Grammar, and Parser dirs)https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22interpreter-core%22
topic-C-APIhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22topic-C-API%22
type-featureA feature request or enhancementhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22type-feature%22
https://github.com/vstinner
vstinnerhttps://github.com/vstinner
on Dec 3, 2025https://github.com/python/cpython/issues/142217#issue-3689780111
deprecate the privatehttps://github.com/python/cpython/issues/github.com/python/cpython/issues/141049
Deprecate private C API functions #141049https://github.com/python/cpython/issues/141049
https://discuss.python.org/t/c-api-how-much-private-is-the-private-py-identifier-api/29190https://discuss.python.org/t/c-api-how-much-private-is-the-private-py-identifier-api/29190
https://mail.python.org/archives/list/python-dev@python.org/thread/DNMZAMB4M6RVR76RDZMUK2WRLI6KAAYS/https://mail.python.org/archives/list/python-dev@python.org/thread/DNMZAMB4M6RVR76RDZMUK2WRLI6KAAYS/
#141049https://github.com/python/cpython/issues/141049
gh-142217: Remove internal _Py_Identifier functions #142219https://github.com/python/cpython/pull/142219
gh-142217: Deprecate the private _Py_Identifier C API #142221https://github.com/python/cpython/pull/142221
gh-142217: Recommend PyUnicode_InternFromString() to replace _PyUnicode_FromId() #142746https://github.com/python/cpython/pull/142746
gh-142217: Add tests on the deprecated _Py_Identifier C API #157638https://github.com/python/cpython/pull/157638
vstinnerhttps://github.com/vstinner
topic-C-APIhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22topic-C-API%22
on Dec 3, 2025https://github.com/python/cpython/issues/142217#event-21330100890
vstinnerhttps://github.com/vstinner
on Dec 3, 2025https://github.com/python/cpython/issues/142217#event-21330334555
pythongh-142217: Remove internal _Py_Identifier functionshttps://github.com/vstinner/cpython/commit/ff6a2a012d3701aebafb3f8c134fc8514aab601a
pythongh-142217https://github.com/python/cpython/issues/142217
ff6a2a0https://github.com/vstinner/cpython/commit/ff6a2a012d3701aebafb3f8c134fc8514aab601a
picnixzhttps://github.com/picnixz
type-featureA feature request or enhancementhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22type-feature%22
interpreter-core(Objects, Python, Grammar, and Parser dirs)https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22interpreter-core%22
on Dec 3, 2025https://github.com/python/cpython/issues/142217#event-21331303741
vstinnerhttps://github.com/vstinner
on Dec 3, 2025https://github.com/python/cpython/issues/142217#event-21333017029
gh-142217: Remove internal _Py_Identifier functions (#142219)https://github.com/python/cpython/commit/7e5fcae09bb0e87ed48cb593f7f46d715e48a102
gh-142217https://github.com/python/cpython/issues/142217
#142219https://github.com/python/cpython/pull/142219
7e5fcaehttps://github.com/python/cpython/commit/7e5fcae09bb0e87ed48cb593f7f46d715e48a102
pythongh-142217: Deprecate the private _Py_Identifier C APIhttps://github.com/vstinner/cpython/commit/c7b7c5177833ef568df7e5685bfb54dc3fac84bb
pythongh-142217https://github.com/python/cpython/issues/142217
c7b7c51https://github.com/vstinner/cpython/commit/c7b7c5177833ef568df7e5685bfb54dc3fac84bb
StanFromIrelandhttps://github.com/StanFromIreland
on Dec 6, 2025https://github.com/python/cpython/issues/142217#event-21401827729
pythongh-142217: Remove internal _Py_Identifier functions (python#142219https://github.com/StanFromIreland/cpython/commit/4d86e4e691f8df1b32df5d84f41b0c6e6de99b20
pythongh-142217https://github.com/python/cpython/issues/142217
python#142219https://github.com/python/cpython/pull/142219
4d86e4ehttps://github.com/StanFromIreland/cpython/commit/4d86e4e691f8df1b32df5d84f41b0c6e6de99b20
vstinnerhttps://github.com/vstinner
on Dec 12, 2025https://github.com/python/cpython/issues/142217#event-21527730175
gh-142217: Deprecate the private _Py_Identifier C API (#142221)https://github.com/python/cpython/commit/7aa353c414509e6881c61acc93cb504a611b0b40
gh-142217https://github.com/python/cpython/issues/142217
#142221https://github.com/python/cpython/pull/142221
7aa353chttps://github.com/python/cpython/commit/7aa353c414509e6881c61acc93cb504a611b0b40
https://github.com/cdce8p
cdce8phttps://github.com/cdce8p
on Dec 14, 2025https://github.com/python/cpython/issues/142217#issuecomment-3651780372
#142221https://github.com/python/cpython/pull/142221
python/mypy@f287f7dhttps://github.com/python/mypy/commit/f287f7d5d28fec318420d3887eacf0ade86c58f5
mentionshttps://discuss.python.org/t/c-api-how-much-private-is-the-private-py-identifier-api/29190/8
python/mypy@dbbc992https://github.com/python/mypy/commit/dbbc992faab55f65881729be26fdcecaccc4cda0
https://github.com/encukou
encukouhttps://github.com/encukou
on Dec 15, 2025https://github.com/python/cpython/issues/142217#issuecomment-3655374720
mentionshttps://discuss.python.org/t/c-api-how-much-private-is-the-private-py-identifier-api/29190/8
@vstinnerhttps://github.com/vstinner
vstinnerhttps://github.com/vstinner
on Dec 15, 2025https://github.com/python/cpython/issues/142217#event-21565538952
pythongh-142217: Recommend PyUnicode_InternFromString() to replace _P…https://github.com/vstinner/cpython/commit/051a1fe4250f87ae80440d520b1d3b5bf502e170
pythongh-142217https://github.com/python/cpython/issues/142217
051a1fehttps://github.com/vstinner/cpython/commit/051a1fe4250f87ae80440d520b1d3b5bf502e170
https://github.com/vstinner
vstinnerhttps://github.com/vstinner
on Dec 15, 2025https://github.com/python/cpython/issues/142217#issuecomment-3655423092
@vstinnerhttps://github.com/vstinner
#142746https://github.com/python/cpython/pull/142746
encukouhttps://github.com/encukou
on Dec 15, 2025https://github.com/python/cpython/issues/142217#event-21566594969
gh-142217: Recommend PyUnicode_InternFromString() to replace _PyUnico…https://github.com/python/cpython/commit/14d3974db01b6c4b14a4829b4310b2511993aa8e
gh-142217https://github.com/python/cpython/issues/142217
14d3974https://github.com/python/cpython/commit/14d3974db01b6c4b14a4829b4310b2511993aa8e
fateleihttps://github.com/fatelei
on Dec 16, 2025https://github.com/python/cpython/issues/142217#event-21587638947
pythongh-142217: Recommend PyUnicode_InternFromString() to replace _P…https://github.com/fatelei/cpython/commit/aa94cb6f5ffc12caa02a8fc2f614863c13c52bf9
pythongh-142217https://github.com/python/cpython/issues/142217
aa94cb6https://github.com/fatelei/cpython/commit/aa94cb6f5ffc12caa02a8fc2f614863c13c52bf9
https://github.com/vstinner
vstinnerhttps://github.com/vstinner
on Dec 16, 2025https://github.com/python/cpython/issues/142217#issuecomment-3660093350
python/mypy@f287f7dhttps://github.com/python/mypy/commit/f287f7d5d28fec318420d3887eacf0ade86c58f5
vstinnerhttps://github.com/vstinner
completedhttps://github.com/python/cpython/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
on Dec 16, 2025https://github.com/python/cpython/issues/142217#event-21590480335
https://github.com/cdce8p
cdce8phttps://github.com/cdce8p
on Dec 22, 2025https://github.com/python/cpython/issues/142217#issuecomment-3684541507
python/mypy#20460https://github.com/python/mypy/pull/20460
vstinnerhttps://github.com/vstinner
on Sep 16, 2026https://github.com/python/cpython/issues/142217#event-31270606745
pythongh-142217: Add tests on the deprecated _Py_Identifier C APIhttps://github.com/vstinner/cpython/commit/d5b636902611f3a6eb36a09ac32a2de316f86862
pythongh-142217https://github.com/python/cpython/issues/142217
d5b6369https://github.com/vstinner/cpython/commit/d5b636902611f3a6eb36a09ac32a2de316f86862
pythongh-142217: Add tests on the deprecated _Py_Identifier C APIhttps://github.com/vstinner/cpython/commit/6d18912dd664a0beaab21d264cc6a5d7de4c21f2
pythongh-142217https://github.com/python/cpython/issues/142217
6d18912https://github.com/vstinner/cpython/commit/6d18912dd664a0beaab21d264cc6a5d7de4c21f2
gh-142217: Add tests on the deprecated _Py_Identifier C API (#157638)https://github.com/python/cpython/commit/21403afa9ba5baa63dc7dd7cf6e109c335d26bb4
gh-142217https://github.com/python/cpython/issues/142217
#157638https://github.com/python/cpython/pull/157638
21403afhttps://github.com/python/cpython/commit/21403afa9ba5baa63dc7dd7cf6e109c335d26bb4
vstinnerhttps://github.com/vstinner
on Oct 16, 2026https://github.com/python/cpython/issues/142217#event-33454954836
[3.15] gh-156939: Add tests on the PyUnicode C API (#159533)https://github.com/python/cpython/commit/bcbe9bcbad03d44dd1188422beb22f2f434e28c4
gh-156939https://github.com/python/cpython/issues/156939
#159533https://github.com/python/cpython/pull/159533
bcbe9bchttps://github.com/python/cpython/commit/bcbe9bcbad03d44dd1188422beb22f2f434e28c4
[3.14] gh-156939: Add tests on the PyUnicode C API (#159533) (#159539)https://github.com/python/cpython/commit/21aae35f49b4013f4e2f3de89a7f6455244ee6f1
gh-156939https://github.com/python/cpython/issues/156939
#159533https://github.com/python/cpython/pull/159533
#159539https://github.com/python/cpython/pull/159539
21aae35https://github.com/python/cpython/commit/21aae35f49b4013f4e2f3de89a7f6455244ee6f1
Sign up for freehttps://github.com/signup?return_to=https://github.com/python/cpython/issues/142217
Sign in to commenthttps://github.com/login?return_to=https://github.com/python/cpython/issues/142217
interpreter-core(Objects, Python, Grammar, and Parser dirs)https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22interpreter-core%22
topic-C-APIhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22topic-C-API%22
type-featureA feature request or enhancementhttps://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22type-feature%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.