WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
53462
Using Control-C to cancel webkit-patch or other python tools causes unpleasant traceback console spew
https://bugs.webkit.org/show_bug.cgi?id=53462
Summary
Using Control-C to cancel webkit-patch or other python tools causes unpleasan...
Darin Adler
Reported
2011-01-31 15:57:42 PST
For example, I hit Control-C when webkit-patch was asking me about a diff Was that diff correct? [Y/n]: Traceback (most recent call last): File "/Users/darin/Safari/OpenSource/Tools/Scripts/webkit-patch", line 70, in <module> main() File "/Users/darin/Safari/OpenSource/Tools/Scripts/webkit-patch", line 65, in main WebKitPatch(__file__).main() File "/Volumes/Home/darin/Safari/OpenSource/Tools/Scripts/webkitpy/tool/multicommandtool.py", line 308, in main result = command.check_arguments_and_execute(options, args, self) File "/Volumes/Home/darin/Safari/OpenSource/Tools/Scripts/webkitpy/tool/multicommandtool.py", line 117, in check_arguments_and_execute return self.execute(options, args, tool) or 0 File "/Volumes/Home/darin/Safari/OpenSource/Tools/Scripts/webkitpy/tool/commands/abstractsequencedcommand.py", line 51, in execute self._sequence.run_and_handle_errors(tool, options, state) File "/Volumes/Home/darin/Safari/OpenSource/Tools/Scripts/webkitpy/tool/commands/stepsequence.py", line 70, in run_and_handle_errors self._run(tool, options, state) File "/Volumes/Home/darin/Safari/OpenSource/Tools/Scripts/webkitpy/tool/commands/stepsequence.py", line 64, in _run step(tool, options).run(state) File "/Volumes/Home/darin/Safari/OpenSource/Tools/Scripts/webkitpy/tool/steps/confirmdiff.py", line 73, in run diff_correct = self._tool.user.confirm("Was that diff correct?") File "/Volumes/Home/darin/Safari/OpenSource/Tools/Scripts/webkitpy/common/system/user.py", line 128, in confirm response = raw_input("%s [%s]: " % (message, choice)) KeyboardInterrupt Yuck! Who else should I cc on this bug?
Attachments
Patch
(973 bytes, patch)
2011-02-01 11:22 PST
,
Adam Barth
no flags
Details
Formatted Diff
Diff
Patch
(1.11 KB, patch)
2011-02-01 11:39 PST
,
Adam Barth
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Eric Seidel (no email)
Comment 1
2011-01-31 15:59:25 PST
We could catch these, sure. For now we've enjoyed the default handler's print-the-stacktrace behavior.
Darin Adler
Comment 2
2011-01-31 16:09:54 PST
Since I’m using the scripts, not developing them, the traceback is never useful to me.
Eric Seidel (no email)
Comment 3
2011-01-31 16:11:36 PST
Yes, I think you are correct that these scripts have moved from a development stage to being deployed and used and we should get rid of debug messages like these. I agree with this bug completely.
Adam Barth
Comment 4
2011-02-01 11:22:26 PST
Created
attachment 80793
[details]
Patch
Mihai Parparita
Comment 5
2011-02-01 11:35:22 PST
Comment on
attachment 80793
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=80793&action=review
> Tools/Scripts/webkit-patch:72 > + pass
Exiting with a non-0 exit code seems better (see
http://trac.webkit.org/browser/trunk/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py#L440
)
Adam Barth
Comment 6
2011-02-01 11:39:15 PST
Created
attachment 80797
[details]
Patch
Eric Seidel (no email)
Comment 7
2011-02-01 12:23:28 PST
Comment on
attachment 80797
[details]
Patch I would hav elogged "user interupted". I might even put this in the multicommandtool.py instead. Also, isn't there a python helper for the 128 + bit? I don't think this should exit 0 though, so you're right in returning the signal code.
WebKit Commit Bot
Comment 8
2011-02-01 12:35:58 PST
Comment on
attachment 80797
[details]
Patch Clearing flags on attachment: 80797 Committed
r77275
: <
http://trac.webkit.org/changeset/77275
>
WebKit Commit Bot
Comment 9
2011-02-01 12:36:04 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug