gh-135069: Fix exception message in encodings.idna module by danielhollas · Pull Request #135071 · python/cpython · GitHub | Latest TMZ Celebrity News & Gossip | Watch TMZ Live
Skip to content

gh-135069: Fix exception message in encodings.idna module #135071

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

Merged
merged 4 commits into from
Jul 3, 2025

Conversation

danielhollas
Copy link
Contributor

@danielhollas danielhollas commented Jun 3, 2025

Fixes #135069.

Requires backport to 3.13 and 3.14 branches.

Fix the 'Unsupported error handling' error message
in the encodings.idna.IncrementalDecoder class.
@danielhollas
Copy link
Contributor Author

danielhollas commented Jun 3, 2025

The docs build fails with

cpython/cpython/Doc/build/NEWS:91: WARNING: py:meth reference target not found: encodings.idna.IncrementalDecoder.decode [ref.meth]

The decode method comes from a parent class I believe. Should a link to the private _buffer_decode method instead?

@tomasr8
Copy link
Member

tomasr8 commented Jun 3, 2025

Should a link to the private _buffer_decode method instead?

You could also just link to IncrementalDecoder

@danielhollas
Copy link
Contributor Author

danielhollas commented Jun 3, 2025

You could also just link to IncrementalDecoder

Thanks, makes sense to me. I tried to change it but still got an error:

cpython/Doc/build/NEWS:91: WARNING: py:class reference target not found: encodings.idna.IncrementalDecoder [ref.class]

No matter how long I stare at it the new blurb looks correct to me? Apologies if that is something obvious, I don't have much experience with rst.

EDIT: The windows build failure looks like a transient http error?

@tomasr8
Copy link
Member

tomasr8 commented Jun 4, 2025

Maybe we can suppress the reference with !? Something like

 `:class:`!encodings.idna.IncrementalDecoder

@danielhollas
Copy link
Contributor Author

Maybe we can suppress the reference with !?

That worked, thanks!

Copy link
Member

@tomasr8 tomasr8 left a comment

Choose a reason for hiding this comment

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

LGTM, thanks! The news entry could be even shorter (and with less detail) but I think this is also fine 🙂

@danielhollas
Copy link
Contributor Author

@tomasr8 @ZeroIntensity congratulations to both on becoming core developers! 👏

I guess this PR could be merged if you re-apply your review now? 😊

Copy link
Member

@ZeroIntensity ZeroIntensity left a comment

Choose a reason for hiding this comment

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

Would you like to hit the green button @tomasr8?

@tomasr8
Copy link
Member

tomasr8 commented Jun 23, 2025

Feel free to press it @ZeroIntensity! 🙂 I'm a bit busy today 😅

@kumaraditya303 kumaraditya303 merged commit 8dc3383 into python:main Jul 3, 2025
47 checks passed
@miss-islington-app
Copy link

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

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jul 3, 2025
…onGH-135071)

(cherry picked from commit 8dc3383)

Co-authored-by: Daniel Hollas <daniel.hollas@bristol.ac.uk>
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jul 3, 2025
…onGH-135071)

(cherry picked from commit 8dc3383)

Co-authored-by: Daniel Hollas <daniel.hollas@bristol.ac.uk>
@bedevere-app
Copy link

bedevere-app bot commented Jul 3, 2025

GH-136235 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.14 bugs and security fixes label Jul 3, 2025
@bedevere-app
Copy link

bedevere-app bot commented Jul 3, 2025

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

@bedevere-app bedevere-app bot removed the needs backport to 3.13 bugs and security fixes label Jul 3, 2025
kumaraditya303 pushed a commit that referenced this pull request Jul 3, 2025
…135071) (#136235)

gh-135069: Fix exception message in encodings.idna module (GH-135071)
(cherry picked from commit 8dc3383)

Co-authored-by: Daniel Hollas <daniel.hollas@bristol.ac.uk>
kumaraditya303 pushed a commit that referenced this pull request Jul 3, 2025
…135071) (#136236)

gh-135069: Fix exception message in encodings.idna module (GH-135071)
(cherry picked from commit 8dc3383)

Co-authored-by: Daniel Hollas <daniel.hollas@bristol.ac.uk>
@danielhollas danielhollas deleted the encodings-fix-fstring branch July 3, 2025 10:44
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

Successfully merging this pull request may close these issues.

encodings.idna: Unexpanded f-string in "Unsupported error handling" exception
4 participants

TMZ Celebrity News – Breaking Stories, Videos & Gossip

Looking for the latest TMZ celebrity news? You've come to the right place. From shocking Hollywood scandals to exclusive videos, TMZ delivers it all in real time.

Whether it’s a red carpet slip-up, a viral paparazzi moment, or a legal drama involving your favorite stars, TMZ news is always first to break the story. Stay in the loop with daily updates, insider tips, and jaw-dropping photos.

🎥 Watch TMZ Live

TMZ Live brings you daily celebrity news and interviews straight from the TMZ newsroom. Don’t miss a beat—watch now and see what’s trending in Hollywood.