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 — gh-111609: Test `end_offset` in SyntaxError subclass by nineteendo · Pull Request #127830 · python/cpython

Conversation

@nineteendo

@nineteendo nineteendo commented Dec 11, 2024 •
edited by bedevere-app Bot
Loading

Uh oh!

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

Copy link
Copy Markdown
Contributor

This was fixed as a side effect of #110702, but wasn't tested.

class CustomSyntaxError(SyntaxError):
    pass

raise CustomSyntaxError("Error message", (None, 1, 5, 'a = sin(3)', 1, 9))

Output:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "<string>", line 1
    a = sin(3)
        ^^^^
CustomSyntaxError: Error message
  • Issue: end_offset is ignored in subclasses of SyntaxError (3.12-only) #111609

Sorry, something went wrong.

Uh oh!

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

All reactions
@nineteendo
Test end_offset in SyntaxError subclass
874ed68
@bedevere-app bedevere-app Bot mentioned this pull request Dec 11, 2024
end_offset is ignored in subclasses of SyntaxError (3.12-only) #111609
Closed
@bedevere-app bedevere-app Bot added the tests Tests in the Lib/test dir label Dec 11, 2024
@nineteendo nineteendo mentioned this pull request Dec 11, 2024
[3.12] gh-111609: end_offset is ignored in subclasses of SyntaxError #127554
Merged
@ZeroIntensity ZeroIntensity added skip news needs backport to 3.12 only security fixes needs backport to 3.13 only security fixes labels Dec 11, 2024
@nineteendo

nineteendo commented Dec 11, 2024

Copy link
Copy Markdown
Contributor Author

Peter, this test is already on 3.12, so doesn't need to be backported.

All reactions

Sorry, something went wrong.

Uh oh!

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

@nineteendo
nineteendo marked this pull request as ready for review December 11, 2024 15:54
@nineteendo
nineteendo requested a review from iritkatriel as a code owner December 11, 2024 15:54
@bedevere-app bedevere-app Bot added the awaiting review label Dec 11, 2024
Eclips4
Eclips4 reviewed Dec 11, 2024
View reviewed changes
Comment thread Lib/test/test_exceptions.py Resolved

Uh oh!

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

@Eclips4 Eclips4 removed the needs backport to 3.12 only security fixes label Dec 11, 2024
Eclips4
Eclips4 approved these changes Dec 11, 2024
View reviewed changes

@Eclips4 Eclips4 left a comment

Copy link
Copy Markdown
Member

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.

Thank you.

Sorry, something went wrong.

Uh oh!

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

All reactions
@bedevere-app bedevere-app Bot added awaiting merge and removed awaiting review labels Dec 11, 2024
pablogsal
pablogsal approved these changes Dec 11, 2024
View reviewed changes
@pablogsal
pablogsal merged commit e8f4e27 into python:main Dec 11, 2024
@miss-islington-app

miss-islington-app Bot commented Dec 11, 2024

Copy link
Copy Markdown

Thanks @nineteendo for the PR, and @pablogsal for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

All reactions

Sorry, something went wrong.

Uh oh!

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

@bedevere-app bedevere-app Bot removed the awaiting merge label Dec 11, 2024
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Dec 11, 2024
@nineteendo @miss-islington
pythongh-111609: Test end_offset in SyntaxError subclass (pythonGH-…
5f5a017
…127830)

Test `end_offset` in SyntaxError subclass
(cherry picked from commit e8f4e27)

Co-authored-by: Nice Zombies <[email protected]>
@nineteendo
nineteendo deleted the patch-1 branch December 11, 2024 18:40
srinivasreddy pushed a commit to srinivasreddy/cpython that referenced this pull request Jan 8, 2025
@nineteendo @srinivasreddy
pythongh-111609: Test end_offset in SyntaxError subclass (python#12…
561297c
…7830)

Test `end_offset` in SyntaxError subclass
@hugovk hugovk added needs backport to 3.13 only security fixes and removed needs backport to 3.13 only security fixes labels Feb 21, 2025
@miss-islington-app

miss-islington-app Bot commented Feb 21, 2025

Copy link
Copy Markdown

Thanks @nineteendo for the PR, and @pablogsal for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

All reactions

Sorry, something went wrong.

Uh oh!

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

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Feb 21, 2025
@nineteendo @miss-islington
pythongh-111609: Test end_offset in SyntaxError subclass (pythonGH-…
005bf39
…127830)

Test `end_offset` in SyntaxError subclass
(cherry picked from commit e8f4e27)

Co-authored-by: Nice Zombies <[email protected]>
@bedevere-app

bedevere-app Bot commented Feb 21, 2025

Copy link
Copy Markdown

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

All reactions

Sorry, something went wrong.

Uh oh!

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

@bedevere-app bedevere-app Bot removed the needs backport to 3.13 only security fixes label Feb 21, 2025
hugovk pushed a commit that referenced this pull request Feb 21, 2025
@miss-islington @nineteendo
[3.13] gh-111609: Test end_offset in SyntaxError subclass (GH-127830)…
cb8d89d
… (#130407)

Co-authored-by: Nice Zombies <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@pablogsal pablogsal pablogsal approved these changes
@Eclips4 Eclips4 Eclips4 approved these changes
@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 tests Tests in the Lib/test dir

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.

5 participants

@nineteendo @pablogsal @Eclips4 @hugovk @ZeroIntensity
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.