You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Pressing CTRL+R inside the macOS-bundled python (/usr/bin/python3, which is compiled against editline) to enter editline history, and then pressing CTRL+C does not properly remove "bck" and does not write KeyboardInterrupt until CTRL+C is pressed two more times for a total of three times.
In other words, inside an editline history search, CTRL+C needs to be sent three times to get back to the normal REPL state.
To be clear, /usr/bin/python3 is the python supplied by Apple as part of Xcode or the Command Line Tools and not Homebrew or python.org macOS installers.
Since python.org's DMG is also built against editline, it's expected to have the same issue. I just installed it and confirmed the same problem exists there (see the video for a better understanding):
milos@air:~$ which python3
/Library/Frameworks/Python.framework/Versions/3.11/bin/python3
milos@air:~$ python3
Python 3.11.1 (v3.11.1:a7a450f84a, Dec 6 2022, 15:24:06) [Clang 13.0.0 (clang-1300.0.29.30)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> ^CenSSL
bck:O
^C
KeyboardInterrupt
>>>
Bug report
With the following in
~/.editrc
:Pressing
CTRL+R
inside the macOS-bundled python (/usr/bin/python3, which is compiled against editline) to enter editline history, and then pressingCTRL+C
does not properly remove "bck" and does not write KeyboardInterrupt until CTRL+C is pressed two more times for a total of three times.In other words, inside an editline history search, CTRL+C needs to be sent three times to get back to the normal REPL state.
This video may help with understanding the issue: Homebrew/homebrew-core#118869 (comment)
Your environment
The text was updated successfully, but these errors were encountered: