Skip to content

Conversation

@serhiy-storchaka
Copy link
Member

@serhiy-storchaka serhiy-storchaka commented Apr 19, 2022

In expression (?(group)...) an appropriate re.error is now
raised if the group number refers to not defined group.

Previously it raised RuntimeError: invalid SRE code.

Closes #91700.

…n RE In expression (?(group)...) an appropriate re.error is now raised if the group number refers to not defined group. Previously it raised RuntimeError: invalid SRE code.
@serhiy-storchaka serhiy-storchaka added type-bug An unexpected behavior, bug, or error needs backport to 3.9 needs backport to 3.10 only security fixes labels Apr 19, 2022
@serhiy-storchaka serhiy-storchaka merged commit 48ec61a into python:main Apr 22, 2022
@miss-islington
Copy link
Contributor

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.9, 3.10.
🐍🍒⛏🤖

@miss-islington
Copy link
Contributor

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.10 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker 48ec61a89a959071206549819448405c2cea61b0 3.10

@serhiy-storchaka serhiy-storchaka deleted the re-groupref-exists branch April 22, 2022 16:53
@miss-islington
Copy link
Contributor

Sorry @serhiy-storchaka, I had trouble checking out the 3.9 backport branch.
Please backport using cherry_picker on command line.
cherry_picker 48ec61a89a959071206549819448405c2cea61b0 3.9

serhiy-storchaka added a commit to serhiy-storchaka/cpython that referenced this pull request Apr 22, 2022
…ssion in RE (pythonGH-91702) In expression (?(group)...) an appropriate re.error is now raised if the group number refers to not defined group. Previously it raised RuntimeError: invalid SRE code.. (cherry picked from commit 48ec61a) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
@bedevere-bot
Copy link

GH-91831 is a backport of this pull request to the 3.10 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.10 only security fixes label Apr 22, 2022
serhiy-storchaka added a commit that referenced this pull request Apr 22, 2022
…in RE (GH-91702) (GH-91831) In expression (?(group)...) an appropriate re.error is now raised if the group number refers to not defined group. Previously it raised RuntimeError: invalid SRE code. (cherry picked from commit 48ec61a)
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Apr 22, 2022
…ssion in RE (pythonGH-91702) (pythonGH-91831) In expression (?(group)...) an appropriate re.error is now raised if the group number refers to not defined group. Previously it raised RuntimeError: invalid SRE code. (cherry picked from commit 48ec61a) (cherry picked from commit 080781c) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
serhiy-storchaka added a commit that referenced this pull request Apr 22, 2022
…n RE (GH-91702) (GH-91831) (GH-91836) In expression (?(group)...) an appropriate re.error is now raised if the group number refers to not defined group. Previously it raised RuntimeError: invalid SRE code. (cherry picked from commit 48ec61a) (cherry picked from commit 080781c) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
@serhiy-storchaka serhiy-storchaka removed their assignment Apr 25, 2022
hello-adam pushed a commit to hello-adam/cpython that referenced this pull request Jun 2, 2022
…sion in RE (pythonGH-91702) (pythonGH-91831) (pythonGH-91836) In expression (?(group)...) an appropriate re.error is now raised if the group number refers to not defined group. Previously it raised RuntimeError: invalid SRE code. (cherry picked from commit 48ec61a) (cherry picked from commit 080781c) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic-regex type-bug An unexpected behavior, bug, or error

4 participants