Closed Bug 613813 Opened 9 years ago Closed 9 years ago

Mochitest websocket server shouldn't terminate on ctrl-c when debugging with gdb

Categories

(Testing :: Mochitest, defect)

x86_64
Linux
defect
Not set

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: justin.lebar+bug, Assigned: justin.lebar+bug)

References

Details

Attachments

(1 file, 1 obsolete file)

STR:

*  $ EXTRA_TEST_ARGS='--debugger=gdb' make mochitest-plain
*  Press ctrl-c at the gdb prompt

Actual results:

  Mochitest webserver receives the SIGINT and kills itself.

Expected results:

  Mochitest webserver should keep running.

Patch in a moment.
Attached patch Patch v1 (obsolete) — Splinter Review
Assignee: nobody → justin.lebar+bug
Status: NEW → ASSIGNED
Attachment #492134 - Flags: review?(ted.mielczarek)
Is it just the pywebsocket server that dies? We already have SIGINT ignored for interactive debugging, right?

I think all that pywebsocket code is from an upstream somewhere, I don't know if we want to take local patches.
(In reply to comment #2)
> Is it just the pywebsocket server that dies? We already have SIGINT ignored for
> interactive debugging, right?

Correct.  Other modules already ignore ctrl+c, but the pywebsocket server sometimes captures it and dies.
The pywebsocket code comes from http://code.google.com/p/pywebsocket/.
Summary: Mochitest server shouldn't terminate on ctrl-c when debugging with gdb → Mochitest websocket server shouldn't terminate on ctrl-c when debugging with gdb
Comment on attachment 492134 [details] [diff] [review]
Patch v1

Can you try to upstream the pywebsocket bits of this? Otherwise we're likely to overwrite them if we have to update the code from upstream in the future.
Attachment #492134 - Flags: review?(ted.mielczarek) → review+
The pywebsocket people suggested wrapping the invocation of standalone.py in a separate script which ignores SIGINT.

Ted, how would you feel about that?
Attachment #492134 - Attachment is obsolete: true
Attached patch Patch v2Splinter Review
Attachment #497699 - Flags: review?(ted.mielczarek)
Attachment #497699 - Flags: review?(ted.mielczarek) → review+
Moving out of Testing product so I can request a2.0.  Although I think this is NPOTB, I guess it's debatable.
Assignee: justin.lebar+bug → nobody
Component: Mochitest → Build Config
Product: Testing → Core
QA Contact: mochitest → build-config
Attachment #497699 - Flags: approval2.0?
test-only changes historically do not require approval. Just land with a=testonly.
Assignee: nobody → justin.lebar+bug
Component: Build Config → Mochitest
Flags: approval2.0?
Product: Core → Testing
QA Contact: build-config → mochitest
http://hg.mozilla.org/mozilla-central/rev/fcd0e21db895
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.