Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

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

Provide feedback

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

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-123241: Document restrictions fortp_traverse implementations#142272

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
colesbury merged 1 commit intopython:mainfromcolesbury:gh-123241-docs
Dec 8, 2025

Conversation

@bedevere-appbedevere-appbot added docsDocumentation in the Doc dir skip news labelsDec 4, 2025
@colesburycolesbury changed the titlegh-12324: Document restrictions fortp_traverse implementationsgh-123241: Document restrictions fortp_traverse implementationsDec 4, 2025
@colesburycolesbury marked this pull request as ready for reviewDecember 4, 2025 21:49
Copy link
Contributor

@mpagempage left a comment

Choose a reason for hiding this comment

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

LGTM

@encukou
Copy link
Member

If we just add it to the docs like this, how are maintainers of old code expected to find out about it?

AFAICS, this is a new requirement, and making CPython rely on it will be a breaking change.
I assume there can't be a period of deprecation warnings. Does this need a PEP 387 exception?

@pablogsal
Copy link
Member

If we just add it to the docs like this, how are maintainers of old code expected to find out about it?

AFAICS, this is a new requirement, and making CPython rely on it will be a breaking change.

I assume there can't be a period of deprecation warnings. Does this need a PEP 387 exception?

This was unfortunately always a requirement for correctness but we never documented it. Calling it a "new requirement" is probably not very productive because if you were doing this before you have a bug and you can affect the correctness of the algorithm or crash depending on the version and the situation.

We could perhaps raise some warnings with time time cost in debug build by checking the total ref count.

colesbury reacted with thumbs up emoji

@DinoV
Copy link
Contributor

Arguably the "create or destroy" objects is redundant given that involves modifying a reference count but LGTM.

@colesburycolesbury merged commit37988c5 intopython:mainDec 8, 2025
34 checks passed
@github-project-automationgithub-project-automationbot moved this fromTodo toDone inDocs PRsDec 8, 2025
@colesburycolesbury deleted the gh-123241-docs branchDecember 8, 2025 17:22
@colesburycolesbury added needs backport to 3.13bugs and security fixes needs backport to 3.14bugs and security fixes labelsDec 8, 2025
@miss-islington-app
Copy link

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

@miss-islington-app
Copy link

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

miss-islington pushed a commit to miss-islington/cpython that referenced this pull requestDec 8, 2025
…ons (pythongh-142272)(cherry picked from commit37988c5)Co-authored-by: Sam Gross <colesbury@gmail.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this pull requestDec 8, 2025
…ons (pythongh-142272)(cherry picked from commit37988c5)Co-authored-by: Sam Gross <colesbury@gmail.com>
@bedevere-app
Copy link

GH-142422 is a backport of this pull request to the3.13 branch.

@bedevere-appbedevere-appbot removed the needs backport to 3.13bugs and security fixes labelDec 8, 2025
@bedevere-app
Copy link

GH-142423 is a backport of this pull request to the3.14 branch.

@bedevere-appbedevere-appbot removed the needs backport to 3.14bugs and security fixes labelDec 8, 2025
colesbury added a commit that referenced this pull requestDec 8, 2025
…ions (gh-142272) (#142423)(cherry picked from commit37988c5)Co-authored-by: Sam Gross <colesbury@gmail.com>
colesbury added a commit that referenced this pull requestDec 8, 2025
…ions (gh-142272) (#142422)(cherry picked from commit37988c5)Co-authored-by: Sam Gross <colesbury@gmail.com>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@DinoVDinoVDinoV approved these changes

@mpagempagempage approved these changes

@pablogsalpablogsalpablogsal approved these changes

@encukouencukouAwaiting requested review from encukou

Assignees

No one assigned

Labels

docsDocumentation in the Doc dirskip news

Projects

Status: Done

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

5 participants

@colesbury@encukou@pablogsal@DinoV@mpage

[8]ページ先頭

©2009-2025 Movatter.jp