Improve handling of Ctrl-C during git-webkit commands. Currently it prints a stack-trace which might not be very readable. e.g.: [WebKit]$git-webkit pr Branch name: ^CTraceback (most recent call last): File "/Volumes/Apple/code/WebKit/Tools/Scripts/git-webkit", line 69, in <module> sys.exit(program.main( File "/Volumes/Apple/code/WebKit/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/__init__.py", line 134, in main return parsed.main( File "/Volumes/Apple/code/WebKit/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/pull_request.py", line 111, in main if Branch.main(args, repository, **kwargs): File "/Volumes/Apple/code/WebKit/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/branch.py", line 79, in main args.issue = Terminal.input('Branch name: ') File "/Volumes/Apple/code/WebKit/Tools/Scripts/libraries/webkitcorepy/webkitcorepy/terminal.py", line 39, in input return (input if sys.version_info > (3, 0) else raw_input)(*args, **kwargs) KeyboardInterrupt
In most cases, I think the stack-trace is the right option. However, a Ctrl-C during input seems like a special case (as the example stack-trace is), and one we could pretty easily handle differently
(In reply to Jonathan Bedard from comment #1) > In most cases, I think the stack-trace is the right option. However, a Ctrl-C during input seems like a special case (as the example stack-trace is), and one we could pretty easily handle differently Yeah, the specific use-case I had in mind was pressing Ctrl-C when user was asked for an input. Re-titled the bug appropriately.
<rdar://problem/88276494>
At the moment, one of the series of commits in https://github.com/WebKit/WebKit/pull/99 has this fix.
Fixed in 246695@main (r288966)
Thanks! Seems to be working fine. e.g.: [/Volumes/Apple/code/WebKit/Tools/CISupport/ews-build]$git-webkit pr 'main' is not a pull request branch, enter name of new branch: ^C User interrupted program