Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=Nonecreated_at=<Date2021-04-09.15:43:50.940>labels= ['3.10']
title='Implement PEP 652 -- Maintaining the Stable ABI'updated_at=<Date2021-12-10.23:34:50.985>user='https://github.com/encukou'
It's part of the limited C API. IMO technically, it's ok to add to the stable ABI. I added it to PC/python3dll.c on purpose. Sadly, it's not available on PyPy, but I don't think that the stable ABI must care about PyPy which is a different use case.
I see that Py_GetArgcArgv it was exported in python3.def (i.e. stable ABI) in bpo-40910, which got backported to 3.9.
And the removal of PyThreadState_DeleteCurrent was reverted: bpo-38266
While we would like to deprecate/remove them in the future, they are now part of the stable ABI.
They are now in internal headers, so I will exclude them from the limited API.
Activity
encukou commented on Apr 9, 2021
This issue tracks implementation of PEP-652.
CPython's Limited C-API and Stable ABI, introduced in PEP-384, will be formalized in a single definitive file, tested, and documented.
encukou commented on Apr 14, 2021
New changeset 92eebf6 by Petr Viktorin in branch 'master':
bpo-43795: Sort PC/python3dll.c (GH-25312)
92eebf6
encukou commented on Apr 16, 2021
Opened as a separate issue: bpo-43868, Remove PyOS_ReadlineFunctionPointer from the stable ABI list
encukou commented on Apr 16, 2021
I unsure about the following symbols.
Victor, do you think they should be part of the stable ABI?
vstinner commented on Apr 16, 2021
No.
bpo-37878 explicitly excluded it from the limited C API. IMO it's too close to the CPython implementation and so must not be added to the stable ABI.
No.
Python 3.10 now provides sys.orig_argv which can be read in C.
https://docs.python.org/dev/library/sys.html#sys.orig_argv
Py_GetArgcArgv() is part of the "legacy" C API to initialize Python. The "new" PyConfig API provides PyConfig.orig_argv.
FYI in the PyPI top 4000 projects, the function seems to be called by the following projects:
2021-02-18/uWSGI-2.0.19.1.tar.gz
2021-02-18/stem-1.8.0.tar.gz
2021-02-18/sphinx-gallery-0.8.2.tar.gz
2021-02-18/setproctitle-1.2.2.tar.gz
2021-02-18/pyuwsgi-2.0.19.1.post0.tar.gz
2021-02-18/mercurial-5.7.tar.gz
2021-02-18/httpretty-1.0.5.tar.gz
2021-02-18/CherryPy-18.6.0.tar.gz
2021-02-18/aws-encryption-sdk-cli-2.1.0.tar.gz
Yes.
It's part of the limited C API. IMO technically, it's ok to add to the stable ABI. I added it to PC/python3dll.c on purpose. Sadly, it's not available on PyPy, but I don't think that the stable ABI must care about PyPy which is a different use case.
encukou commented on Apr 16, 2021
Thanks! I'll send PRs later.
encukou commented on Apr 20, 2021
Thanks for linking to the issues/documentation!
I see that Py_GetArgcArgv it was exported in python3.def (i.e. stable ABI) in bpo-40910, which got backported to 3.9.
And the removal of PyThreadState_DeleteCurrent was reverted: bpo-38266
While we would like to deprecate/remove them in the future, they are now part of the stable ABI.
They are now in internal headers, so I will exclude them from the limited API.
erlend-aasland commented on Apr 20, 2021
Should we mention PEP-652 in Include/README.rst, now that the PEP is accepted?
encukou commented on Apr 20, 2021
No, we should link to the documentation (when it's written). The PEP is a design document; it'll become outdated.
encukou commented on Apr 23, 2021
New changeset e7cc64e by Petr Viktorin in branch 'master':
bpo-43795: PEP-652: Simplify headers for easier static analysis (GH-25483)
e7cc64e
encukou commented on Apr 23, 2021
New changeset 9d6a2d0 by Petr Viktorin in branch 'master':
bpo-43795: PEP-652: Clean up the stable ABI/limited API (GH-25482)
9d6a2d0
vstinner commented on Apr 28, 2021
Right now, running "make regen-limited-abi" adds again functions which were removed from Doc/data/stable_abi.dat:
#25687 (comment)
I guess that you should not be added until this issue is solved.
encukou commented on Apr 28, 2021
I hope the PR fixes that. I plan to merge tomorrow if there ar no objections to it.
On April 28, 2021 5:15:19 PM GMT+02:00, STINNER Victor <report@bugs.python.org> wrote:
7 remaining items
encukou commented on Jun 8, 2021
New changeset 257e400 by Petr Viktorin in branch 'main':
bpo-43795: Note Stable ABI PEP in What's New (GH-26479)
257e400
encukou commented on Jun 8, 2021
New changeset 7518556 by Miss Islington (bot) in branch '3.10':
bpo-43795: Note Stable ABI PEP in What's New (GH-26479) (GH-26603)
7518556
encukou commented on Jun 16, 2021
New changeset 7cad9cb by Petr Viktorin in branch 'main':
bpo-43795: Don't list private names in the limited API (GH-26740)
7cad9cb
miss-islington commented on Jun 16, 2021
New changeset 7fd4010 by Miss Islington (bot) in branch '3.10':
bpo-43795: Don't list private names in the limited API (GH-26740)
7fd4010
encukou commented on Oct 22, 2021
New changeset 276468d by Petr Viktorin in branch 'main':
bpo-43795: Add a test for Stable ABI symbol availability using ctypes (GH-26354)
276468d
ambv commented on Dec 10, 2021
New changeset 98e506a by Petr Viktorin in branch 'main':
bpo-43795: Document stable_abi.txt format and contents (GH-29956)
98e506a
encukou commented on Jun 7, 2022
Another docs fixup: #93581
gh-87961: Remove outdated notes from functions that aren't in the Lim…
pythongh-87961: Remove outdated notes from functions that aren't in t…
pythongh-87961: Remove outdated notes from functions that aren't in t…
gh-87961: Remove outdated notes from functions that aren't in the Lim…
gh-87961: Remove outdated notes from functions that aren't in the Lim…
Revert 30935 defer bpo45162 to 312 (#94285)