Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some SyntaxWarning in strings are shown twice in the presence of SyntaxErrors #111380

Closed
pablogsal opened this issue Oct 27, 2023 · 0 comments
Closed

Comments

@pablogsal
Copy link
Member

pablogsal commented Oct 27, 2023

Example:

❯ ./python.exe  -Wall
Python 3.13.0a1+ (heads/main:78e6d72e38e, Oct 27 2023, 11:50:08) [Clang 15.0.0 (clang-1500.0.40.1)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> '\e' $
<stdin>:1: SyntaxWarning: invalid escape sequence '\e'
<stdin>:1: SyntaxWarning: invalid escape sequence '\e'
  File "<stdin>", line 1
    '\e' $
         ^
SyntaxError: invalid syntax

Linked PRs

pablogsal added a commit to pablogsal/cpython that referenced this issue Oct 27, 2023
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Oct 27, 2023
…d syntax is encouintered (pythonGH-111381)

(cherry picked from commit 3d2f1f0)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Oct 27, 2023
…d syntax is encouintered (pythonGH-111381)

(cherry picked from commit 3d2f1f0)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
pablogsal added a commit that referenced this issue Oct 27, 2023
…id syntax is encouintered (GH-111381) (#111382)

gh-111380: Show SyntaxWarnings only once when parsing if invalid syntax is encouintered (GH-111381)
(cherry picked from commit 3d2f1f0)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
pablogsal added a commit that referenced this issue Oct 31, 2023
…id syntax is encouintered (GH-111381) (#111383)

gh-111380: Show SyntaxWarnings only once when parsing if invalid syntax is encouintered (GH-111381)
(cherry picked from commit 3d2f1f0)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
aisk pushed a commit to aisk/cpython that referenced this issue Feb 11, 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

No branches or pull requests

1 participant