Skip to content

Conversation

@tpburns
Copy link
Contributor

@tpburnstpburns commented May 29, 2025

When sanity checking against gettotalrefcount we exclude the blocks for immortalized strings since their references are not tracked/reported. This now matches refleak.py's book-keeping using the same functions.

As such, the current state of the PR is that the check is never skipped - to be be adjusted as needed given CI results and/or feedback.

…zed strings When sanity checking against gettotalrefcount we exclude the blocks for immortalized strings since their references are not tracked/reported. This now matches refleak.py's book-keeping using the same functions.
@python-cla-bot
Copy link

python-cla-botbot commented May 29, 2025

All commit authors signed the Contributor License Agreement.

CLA signed

@bedevere-app
Copy link

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

Copy link
Member

@vstinnervstinner left a comment

Choose a reason for hiding this comment

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

LGTM. It makes sense to use sys.getunicodeinternedsize() here.

@vstinnervstinner merged commit 54ca559 into python:mainJun 3, 2025
48 checks passed
@vstinnervstinner added the needs backport to 3.14 bugs and security fixes label Jun 3, 2025
@miss-islington-app
Copy link

Thanks @tpburns for the PR, and @vstinner for merging it 🌮🎉.. I'm working now to backport this PR to: 3.14.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jun 3, 2025
…zed strings (pythonGH-134871) When sanity checking against gettotalrefcount(), we exclude the blocks for immortalized strings since their references are not tracked/reported. This now matches refleak.py's book-keeping using the same functions. (cherry picked from commit 54ca559) Co-authored-by: tpburns <[email protected]>
@bedevere-app
Copy link

GH-135095 is a backport of this pull request to the 3.14 branch.

@bedevere-appbedevere-appbot removed the needs backport to 3.14 bugs and security fixes label Jun 3, 2025
@vstinner
Copy link
Member

Merged, thank you.

vstinner pushed a commit that referenced this pull request Jun 3, 2025
…ized strings (GH-134871) (#135095) gh-134248 test_getallocatedblocks pre-check to ignore immortalized strings (GH-134871) When sanity checking against gettotalrefcount(), we exclude the blocks for immortalized strings since their references are not tracked/reported. This now matches refleak.py's book-keeping using the same functions. (cherry picked from commit 54ca559) Co-authored-by: tpburns <[email protected]>
Pranjal095 pushed a commit to Pranjal095/cpython that referenced this pull request Jul 12, 2025
…zed strings (python#134871) When sanity checking against gettotalrefcount(), we exclude the blocks for immortalized strings since their references are not tracked/reported. This now matches refleak.py's book-keeping using the same functions.
taegyunkim pushed a commit to taegyunkim/cpython that referenced this pull request Aug 4, 2025
…zed strings (python#134871) When sanity checking against gettotalrefcount(), we exclude the blocks for immortalized strings since their references are not tracked/reported. This now matches refleak.py's book-keeping using the same functions.
Agent-Hellboy pushed a commit to Agent-Hellboy/cpython that referenced this pull request Aug 19, 2025
…zed strings (python#134871) When sanity checking against gettotalrefcount(), we exclude the blocks for immortalized strings since their references are not tracked/reported. This now matches refleak.py's book-keeping using the same functions.
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip newstestsTests in the Lib/test dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@tpburns@vstinner@ZeroIntensity