◐ Shell
clean mode source ↗

gh-146636: Add Free-threaded Stable ABI migration guide by clin1234 · Pull Request #148453 · python/cpython

da-woods

da-woods

@clin1234 clin1234 marked this pull request as ready for review

April 12, 2026 17:44

@clin1234 clin1234 marked this pull request as ready for review

May 17, 2026 09:33
This document provides detailed instructions on how to use the Free Threading Stable ABI in CPython, including guidelines for module initialization, API usage, and thread safety considerations.
Clarified access restrictions on PyObject members and recommended functions for type and reference count manipulation.
Clarified that direct access to PyObject members is prohibited.
Co-authored-by: da-woods <dw-git@d-woods.co.uk>
Updated documentation to clarify the identification of free-threaded limited API builds in C, including changes to macros and initialization methods.
Updated the documentation to clarify the use of the stable ABI and GIL management in Python extensions, including changes to member access and initialization methods.
Removed sections on API guidelines, critical sections, and thread safety from the documentation.

@clin1234

da-woods