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-99153: set location on SyntaxError for try with both except and except*#99160

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
iritkatriel merged 4 commits intopython:mainfromiritkatriel:gh-99153
Nov 6, 2022

Conversation

iritkatriel
Copy link
Member

@iritkatrieliritkatriel commentedNov 6, 2022
edited
Loading

Fixes#99153.

I made it point to thetry because we don't know whichexcept orexcept* is incorrect.

% ./python.exe f.py   File "/Users/iritkatriel/src/cpython-1/f.py", line 4    try:    ^^^SyntaxError: cannot have both 'except' and 'except*' on the same 'try'

ProgramRipper reacted with thumbs up emoji
Copy link
Member

@pablogsalpablogsal left a comment

Choose a reason for hiding this comment

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

LGTM

@iritkatrieliritkatriel merged commit61b6c40 intopython:mainNov 6, 2022
@miss-islington
Copy link
Contributor

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

@miss-islington
Copy link
Contributor

Sorry,@iritkatriel, I could not cleanly backport this to3.11 due to a conflict.
Please backport usingcherry_picker on command line.
cherry_picker 61b6c40b645bd8c8568f1646dc46580fa49d107a 3.11

@bedevere-bot
Copy link

GH-99168 is a backport of this pull request to the3.11 branch.

@bedevere-botbedevere-bot removed the needs backport to 3.11only security fixes labelNov 6, 2022
iritkatriel added a commit to iritkatriel/cpython that referenced this pull requestNov 6, 2022
@iritkatrieliritkatriel deleted the gh-99153 branchJuly 25, 2023 18:07
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@pablogsalpablogsalpablogsal approved these changes

@lysnikolaoulysnikolaouAwaiting requested review from lysnikolaoulysnikolaou is a code owner

Assignees

@iritkatrieliritkatriel

Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)type-bugAn unexpected behavior, bug, or error
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

"SyntaxError: cannot have both 'except' and 'except*' on the same 'try'" traceback point to a confusing place
4 participants
@iritkatriel@miss-islington@bedevere-bot@pablogsal

[8]ページ先頭

©2009-2025 Movatter.jp