Bug 176393

Summary: Log stack-trace for run-webkit-tests when interrupted
Product: WebKit Reporter: Jonathan Bedard <jbedard>
Component: Tools / TestsAssignee: Jonathan Bedard <jbedard>
Status: RESOLVED FIXED    
Severity: Normal CC: aakash_jain, buildbot, commit-queue, darin, ews-watchlist, glenn, lforschler, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=178402
Bug Depends on: 178587    
Bug Blocks: 178402    
Attachments:
Description Flags
Patch
none
Patch
none
Patch
none
Patch
none
Patch
none
Patch
none
Patch none

Jonathan Bedard
Reported 2017-09-05 12:32:57 PDT
We have a number of circumstances where run-webkit-tests gets stuck. Debugging these issues is difficult since these issues can often only be reproduced on specific configurations and even then, are frequently flakey. If run-webkit-tests printed a stack-trace when interrupted, these issues would be much easier to debug.
Attachments
Patch (4.87 KB, patch)
2017-09-05 12:36 PDT, Jonathan Bedard
no flags
Patch (5.70 KB, patch)
2017-09-06 08:52 PDT, Jonathan Bedard
no flags
Patch (5.92 KB, patch)
2017-11-17 09:48 PST, Jonathan Bedard
no flags
Patch (6.17 KB, patch)
2019-04-08 16:30 PDT, Jonathan Bedard
no flags
Patch (6.18 KB, patch)
2019-04-08 16:56 PDT, Jonathan Bedard
no flags
Patch (2.73 KB, patch)
2019-04-08 17:00 PDT, Jonathan Bedard
no flags
Patch (6.18 KB, patch)
2019-04-08 17:11 PDT, Jonathan Bedard
no flags
Radar WebKit Bug Importer
Comment 1 2017-09-05 12:33:27 PDT
Jonathan Bedard
Comment 2 2017-09-05 12:36:49 PDT
Darin Adler
Comment 3 2017-09-05 20:55:14 PDT
Comment on attachment 319924 [details] Patch This is great for someone who is working on run-webkit-tests, or who is annoyed that it is stuck, but makes things worse if you are not working on run-webkit-test and are not annoyed, but just want to cancel it so you can correct a mistake or type another command. I don’t think this should be turned on for everybody. I find these tools that dump stack traces whenever you interrupt them super-frustrating when just trying to use the tools to do my work.
Darin Adler
Comment 4 2017-09-05 20:56:03 PDT
Comment on attachment 319924 [details] Patch Maybe have it just dump the stack trace into a file?
Jonathan Bedard
Comment 5 2017-09-06 08:52:39 PDT
WebKit Commit Bot
Comment 6 2017-10-02 07:59:32 PDT
Comment on attachment 320024 [details] Patch Clearing flags on attachment: 320024 Committed r222709: <http://trac.webkit.org/changeset/222709>
WebKit Commit Bot
Comment 7 2017-10-02 07:59:33 PDT
All reviewed patches have been landed. Closing bug.
WebKit Commit Bot
Comment 8 2017-10-20 09:06:58 PDT
Re-opened since this is blocked by bug 178587
Jonathan Bedard
Comment 9 2017-11-17 09:48:23 PST
Jonathan Bedard
Comment 10 2017-11-17 09:51:32 PST
Updating the patch so that when multiple processes print stack traces, they don't all go to the same file.
Jonathan Bedard
Comment 11 2019-04-08 15:43:42 PDT
I think we should revive this change, it was just quite valuable in root-causing <https://bugs.webkit.org/show_bug.cgi?id=196694>.
Lucas Forschler
Comment 12 2019-04-08 15:44:42 PDT
Comment on attachment 327187 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=327187&action=review the two functions appear to be nearly identical to each other. is there any way to simplify the do reduce code duplication? > Tools/Scripts/webkitpy/common/interupt_debugging.py:28 > + nit: please alphabetize > Tools/Scripts/webkitpy/common/interupt_debugging.py:63 > +def log_stack_trace_on_cntrl_c(output_file=None): I usually see control abbreviated as CTRL > Tools/Scripts/webkitpy/common/interupt_debugging.py:74 > + file.write('cntrl C received\n') CTRL+C received
Jonathan Bedard
Comment 13 2019-04-08 16:30:04 PDT
Lucas Forschler
Comment 14 2019-04-08 16:46:02 PDT
Comment on attachment 366996 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=366996&action=review lgtm. > Tools/Scripts/webkitpy/common/interupt_debugging.py:28 > + nit: alphabetize
Jonathan Bedard
Comment 15 2019-04-08 16:56:17 PDT
Jonathan Bedard
Comment 16 2019-04-08 17:00:26 PDT
EWS Watchlist
Comment 17 2019-04-08 17:03:17 PDT
Attachment 367000 [details] did not pass style-queue: ERROR: Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py:39: No name 'interrupt_debugging' in module 'webkitpy.common' [pylint/E0611] [5] Total errors found: 1 in 2 files If any of these errors are false positives, please file a bug against check-webkit-style.
Jonathan Bedard
Comment 18 2019-04-08 17:11:42 PDT
WebKit Commit Bot
Comment 19 2019-04-08 18:32:22 PDT
Comment on attachment 367003 [details] Patch Clearing flags on attachment: 367003 Committed r244064: <https://trac.webkit.org/changeset/244064>
WebKit Commit Bot
Comment 20 2019-04-08 18:32:24 PDT
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.