← 返回首页
GH-104668: Don't call `PyOS_*` hooks in subinterpreters by brandtbucher · Pull Request #104674 · python/cpython · GitHub
Skip to content

Navigation Menu

Toggle navigation
Sign in
Appearance settings
Search or jump to...

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Include my email address so I can be contacted

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Resetting focus

GH-104668: Don't call PyOS_* hooks in subinterpreters#104674

Merged
brandtbucher merged 6 commits into
python:mainfrom
brandtbucher:global-hooks
May 22, 2023
Merged

GH-104668: Don't call PyOS_* hooks in subinterpreters#104674
brandtbucher merged 6 commits into
python:mainfrom
brandtbucher:global-hooks

Conversation

brandtbucher commented May 19, 2023
edited by github-actions Bot
Loading

Copy link
Copy Markdown
Member

PyOS_InputHook and PyOS_ReadlineFunctionPointer are now only called in the main interpreter.

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

Copy link
Copy Markdown
Contributor

We should advertise this in What's New as well.

ericsnowcurrently left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality Hide comment

LGTM

brandtbucher enabled auto-merge (squash) May 22, 2023 19:25
brandtbucher merged commit 357bed0 into python:main May 22, 2023

arhadthedev commented May 22, 2023
edited
Loading

Copy link
Copy Markdown
Member

Should we backport it to 3.12?

Edit: I noticed that the label isn't added yet.

Copy link
Copy Markdown
Member

@brandtbucher this didn't actually end up in the 3.12 branch. Should we backport it, or is it a new feature that should only go into 3.13?

brandtbucher added the needs backport to 3.12 only security fixes label May 22, 2023

Copy link
Copy Markdown
Contributor

Thanks @brandtbucher for the PR 🌮🎉.. I'm working now to backport this PR to: 3.12.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request May 22, 2023
…-104674) (cherry picked from commit 357bed0) Co-authored-by: Brandt Bucher <brandtbucher@microsoft.com>

Copy link
Copy Markdown

GH-104760 is a backport of this pull request to the 3.12 branch.

bedevere-bot removed the needs backport to 3.12 only security fixes label May 22, 2023

Copy link
Copy Markdown
Member Author

I was waiting for the label. 🙂

brandtbucher added a commit that referenced this pull request May 23, 2023
GH-104668: Don't call PyOS_* hooks in subinterpreters (GH-104674) (cherry picked from commit 357bed0) Co-authored-by: Brandt Bucher <brandtbucher@microsoft.com>
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

Labels

interpreter-core (Objects, Python, Grammar, and Parser dirs) topic-C-API topic-subinterpreters topic-tkinter type-bug An unexpected behavior, bug, or error

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants

Footer

© 2026 GitHub, Inc.