Skip to content

gh-120244: Fix re.sub() reference leak#120245

Merged
serhiy-storchaka merged 3 commits into
python:mainfrom
neonene:re_sub
Jun 8, 2024
Merged

gh-120244: Fix re.sub() reference leak#120245
serhiy-storchaka merged 3 commits into
python:mainfrom
neonene:re_sub

Conversation

@neonene

@neonene neonene commented Jun 7, 2024

Copy link
Copy Markdown
Contributor
>python_d -X showrefcount -c "import re; re.sub(r'()', r'\1', '')"
[7140 refs, 4669 blocks]  # Before
[0 refs, 0 blocks]        # After

This patch is based on the commit: 75a6fad.

cc @serhiy-storchaka

@serhiy-storchaka serhiy-storchaka 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.

LGTM. Please add a NEWS entry, this is a user visible change.

Comment thread Misc/NEWS.d/next/Library/2024-06-08-09-45-31.gh-issue-120244.8o9Dzr.rst Outdated
@serhiy-storchaka serhiy-storchaka enabled auto-merge (squash) June 8, 2024 09:58
@serhiy-storchaka serhiy-storchaka added needs backport to 3.12 only security fixes needs backport to 3.13 bugs and security fixes labels Jun 8, 2024
@serhiy-storchaka serhiy-storchaka merged commit 38a25e9 into python:main Jun 8, 2024
@miss-islington-app

Copy link
Copy Markdown

Thanks @neonene for the PR, and @serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.12, 3.13.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jun 8, 2024
(cherry picked from commit 38a25e9)

Co-authored-by: neonene <53406459+neonene@users.noreply.github.com>
@bedevere-app

bedevere-app Bot commented Jun 8, 2024

Copy link
Copy Markdown

GH-120264 is a backport of this pull request to the 3.13 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jun 8, 2024
(cherry picked from commit 38a25e9)

Co-authored-by: neonene <53406459+neonene@users.noreply.github.com>
@bedevere-app bedevere-app Bot removed the needs backport to 3.13 bugs and security fixes label Jun 8, 2024
@bedevere-app

bedevere-app Bot commented Jun 8, 2024

Copy link
Copy Markdown

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

@bedevere-app bedevere-app Bot removed the needs backport to 3.12 only security fixes label Jun 8, 2024
@neonene

neonene commented Jun 8, 2024

Copy link
Copy Markdown
Contributor Author

Thanks.

@neonene neonene deleted the re_sub branch June 8, 2024 10:25
serhiy-storchaka pushed a commit that referenced this pull request Jun 8, 2024
(cherry picked from commit 38a25e9)

Co-authored-by: neonene <53406459+neonene@users.noreply.github.com>
serhiy-storchaka pushed a commit that referenced this pull request Jun 8, 2024
(cherry picked from commit 38a25e9)

Co-authored-by: neonene <53406459+neonene@users.noreply.github.com>
noahbkim pushed a commit to hudson-trading/cpython that referenced this pull request Jul 11, 2024
estyxx pushed a commit to estyxx/cpython that referenced this pull request Jul 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants