8000 gh-130698: Add safe methods to get prompts for new REPL by sergey-miryanov · Pull Request #131110 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-130698: Add safe methods to get prompts for new REPL #131110

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

Open
wants to merge 14 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Update docstring for __get_prompt_str
Co-authored-by: Chris Eibl <138194463+chris-eibl@users.noreply.github.com>
  • Loading branch information
sergey-miryanov and chris-eibl authored Apr 20, 2025
commit 60c189f53e9c9690a85d2fdc3abb6233ed1b640e
2 changes: 1 addition & 1 deletion Lib/_pyrepl/reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ def __get_prompt_str(prompt: object, default_prompt: str) -> str:
"""
Convert prompt object to string.

If prompt raise BaseException, MemoryError and SystemError then stop
If str(prompt) raises BaseException, MemoryError or SystemError then stop
the REPL. For other exceptions return default_prompt.
"""
try:
Expand Down
Loading
0