GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — [3.13] gh-131927: Prevent emitting optimizer warnings twice in the REPL (GH-131993) by tomasr8 · Pull Request #132463 · python/cpython

Conversation

@tomasr8

@tomasr8 tomasr8 commented Apr 13, 2025 •
edited by picnixz
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

(cherry picked from commit 3d08c8a)

  • Issue: Compilation emits multiple warnings in the finally block #131927

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@tomasr8
[3.13] pythongh-131927: Prevent emitting optimizer warnings twice in …
f0d8917
…the REPL (pythonGH-131993)

(cherry picked from commit 3d08c8a)

Co-authored-by: Tomas R. <[email protected]>
@tomasr8
tomasr8 requested review from iritkatriel and markshannon as code owners April 13, 2025 07:16
@bedevere-app bedevere-app Bot added the awaiting review label Apr 13, 2025
This was referenced Apr 13, 2025
Compilation emits multiple warnings in the finally block #131927
Closed
gh-131927: Prevent emitting optimizer warnings twice in the REPL #131993
Merged
@bedevere-app bedevere-app Bot added the skip news label Apr 13, 2025
@picnixz picnixz changed the title [3.13] gh-131927: Prevent emitting optimizer warnings twice in the RE… [3.13] gh-131927: Prevent emitting optimizer warnings twice in the REPL Apr 13, 2025
tomasr8
tomasr8 commented Apr 13, 2025
View reviewed changes
Comment thread Python/compile.c
}
if (PyErr_WarnExplicitObject(PyExc_SyntaxWarning, msg, c->c_filename,
loc.lineno, NULL, NULL) < 0)
if (_PyErr_WarnExplicitObjectWithContext(PyExc_SyntaxWarning, msg,

@tomasr8 tomasr8 Apr 13, 2025

Copy link
Copy Markdown
Member Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Just a note, 3.13 uses compiler_warn instead of _PyErr_EmitSyntaxWarning to emit warnings.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@picnixz picnixz changed the title [3.13] gh-131927: Prevent emitting optimizer warnings twice in the REPL [3.13] gh-131927: Prevent emitting optimizer warnings twice in the REPL (#131993) Apr 13, 2025
@picnixz picnixz changed the title [3.13] gh-131927: Prevent emitting optimizer warnings twice in the REPL (#131993) [3.13] gh-131927: Prevent emitting optimizer warnings twice in the REPL (GH-131993) Apr 13, 2025
@tomasr8
tomasr8 requested a review from serhiy-storchaka April 13, 2025 07:40
@serhiy-storchaka
Update test_interact.py
99d3b5b
serhiy-storchaka
serhiy-storchaka approved these changes Apr 13, 2025
View reviewed changes
@bedevere-app bedevere-app Bot added awaiting merge and removed awaiting review labels Apr 13, 2025
@serhiy-storchaka
serhiy-storchaka enabled auto-merge (squash) April 13, 2025 08:21
@serhiy-storchaka
serhiy-storchaka merged commit 4ff5d88 into python:3.13 Apr 13, 2025
@bedevere-app bedevere-app Bot removed the awaiting merge label Apr 13, 2025
@tomasr8
tomasr8 deleted the backport-3d08c8a-3.13 branch April 13, 2025 09:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@serhiy-storchaka serhiy-storchaka serhiy-storchaka approved these changes
@markshannon markshannon Awaiting requested review from markshannon markshannon is a code owner
@iritkatriel iritkatriel Awaiting requested review from iritkatriel iritkatriel is a code owner

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

skip news

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@tomasr8 @serhiy-storchaka
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.