FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-132775: Drop PyUnstable_InterpreterState_GetMainModule() by ericsnowcurrently · Pull Request #132978 · python/cpython · GitHub

/ cpython Public

gh-132775: Drop PyUnstable_InterpreterState_GetMainModule() - #132978

Merged
ericsnowcurrently merged 2 commits into
python:mainfrom
ericsnowcurrently:replace-pyUnstable_interpreterstate_get-main-module
Apr 28, 2025
Merged

gh-132775: Drop PyUnstable_InterpreterState_GetMainModule()#132978
ericsnowcurrently merged 2 commits into
python:mainfrom
ericsnowcurrently:replace-pyUnstable_interpreterstate_get-main-module

Conversation

ericsnowcurrently commented Apr 25, 2025
edited
Loading

Copy link
Copy Markdown
Member

We replace it with _Py_GetMainModule(), and add _Py_CheckMainModule(), but in the internal-only C-API. We also add _PyImport_GetModulesRef(), which is the equivalent of _PyImport_GetModules() that incref's while the lock is held.

This is used by a later change related to pickle and handling __main__.


📚 Documentation preview 📚: https://cpython-previews--132978.org.readthedocs.build/

ericsnowcurrently force-pushed the replace-pyUnstable_interpreterstate_get-main-module branch from ed0d690 to 9c9c41c Compare April 25, 2025 23:02
ericsnowcurrently merged commit fe462f5 into python:main Apr 28, 2025
ericsnowcurrently deleted the replace-pyUnstable_interpreterstate_get-main-module branch April 28, 2025 18:46
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant


Back | FazBrowse Home | New Git URL