gh-125666: Avoid PyREPL exiting when a null byte is in input#125732
Merged
pablogsal merged 5 commits intopython:mainfrom Oct 27, 2024
Merged
gh-125666: Avoid PyREPL exiting when a null byte is in input#125732pablogsal merged 5 commits intopython:mainfrom
pablogsal merged 5 commits intopython:mainfrom
Conversation
…reter._showtraceback.
rruuaanng
reviewed
Oct 21, 2024
Member
Author
|
Thank you very much! If you can, propose it as a code change and I'll accept it, so your contribution gets recorded in a commit. |
Member
That person was a bot user, sorry! |
ZeroIntensity
approved these changes
Oct 24, 2024
Member
ZeroIntensity
left a comment
There was a problem hiding this comment.
I think this looks fine.
pablogsal
approved these changes
Oct 27, 2024
pablogsal
reviewed
Oct 27, 2024
pablogsal
approved these changes
Oct 27, 2024
Member
|
Thanks for the contribution @devdanzin and thanks @ZeroIntensity for the review! |
|
Thanks @devdanzin for the PR, and @pablogsal for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13. |
miss-islington
pushed a commit
to miss-islington/cpython
that referenced
this pull request
Oct 27, 2024
…ythonGH-125732) (cherry picked from commit 44becb8) Co-authored-by: devdanzin <74280297+devdanzin@users.noreply.github.com>
|
GH-126023 is a backport of this pull request to the 3.13 branch. |
Yhg1s
pushed a commit
that referenced
this pull request
Dec 2, 2024
ebonnal
pushed a commit
to ebonnal/cpython
that referenced
this pull request
Jan 12, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This PR adds a guard against
SyntaxError.linenobeingNoneincode.InteractiveInterpreter._showtraceback, which should avoidPyREPLexiting the interpreter when a null byte is present in the input.Not sure both new tests are necessary, happy to remove one or the other if it's better.