Debugger becomes unresponsive when breaking on exception thrown in function called by console

RESOLVED WORKSFORME

Status

RESOLVED WORKSFORME
4 years ago
2 months ago

People

(Reporter: jonathan, Unassigned)

Tracking

(Blocks: 1 bug)

35 Branch
x86
Mac OS X

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

4 years ago
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:33.0) Gecko/20100101 Firefox/33.0 (Beta/Release)
Build ID: 20140808004001

Steps to reproduce:

http://codepen.io/joallard/debug/JuEDc

1. Open debugger and console
2. Breakpoint on JuEDc:21 (throw line)
3. Call `doIt()` in console, execution stops
4. Enter `{}` in console, submit
=> No response
5. Click play


Actual results:

Console does not respond.

Even after reloading, the console will stop answering any command.

After pressing play, the following errors in browser console:

"""
error occurred while processing 'autocomplete: Error: Debugger.Frame is not live
Stack: WCA_onAutocomplete@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/actors/webconsole.js:792:9
DSC_onPacket@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/main.js:1223:15
LocalDebuggerTransport.prototype.send/<@resource://gre/modules/devtools/dbg-client.jsm -> resource://gre/modules/devtools/transport/transport.js:545:11
makeInfallible/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/DevToolsUtils.js:83:14
makeInfallible/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/DevToolsUtils.js:83:14
Line: 792, column: 8
"""

"""
onPacket threw an exception: Error: Server did not specify an actor, dropping packet: {"error":"unknownError","message":"error occurred while processing 'autocomplete: Error: Debugger.Frame is not live\nStack: WCA_onAutocomplete@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/actors/webconsole.js:792:9\nDSC_onPacket@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/main.js:1223:15\nLocalDebuggerTransport.prototype.send/<@resource://gre/modules/devtools/dbg-client.jsm -> resource://gre/modules/devtools/transport/transport.js:545:11\nmakeInfallible/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/DevToolsUtils.js:83:14\nmakeInfallible/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/DevToolsUtils.js:83:14\nLine: 792, column: 8"}
Stack: DebuggerClient.prototype.onPacket/<@resource://gre/modules/devtools/dbg-client.jsm:865:1
resolve@resource://gre/modules/devtools/deprecated-sync-thenables.js:40:40
then@resource://gre/modules/devtools/deprecated-sync-thenables.js:20:43
then@resource://gre/modules/devtools/deprecated-sync-thenables.js:58:9
DebuggerClient.prototype.onPacket@resource://gre/modules/devtools/dbg-client.jsm:861:1
LocalDebuggerTransport.prototype.send/<@resource://gre/modules/devtools/dbg-client.jsm -> resource://gre/modules/devtools/transport/transport.js:545:11
makeInfallible/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/DevToolsUtils.js:83:14
makeInfallible/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/DevToolsUtils.js:83:14
Line: 865, column: 0
"""



Expected results:

Console continues working.
(Reporter)

Updated

4 years ago
Component: Untriaged → Developer Tools: Debugger
(Reporter)

Comment 1

4 years ago
Also to notice, calling the function by clicking the "Do it" button instead of step 3 does not reproduce the bug.
I can't reproduce this in either Aurora or Nightly. window.doIt is always undefined for me. Do I have to do something else after setting the breakpoint and before evaluating "doIt()" in the console?

Updated

4 years ago
Blocks: 1070885
(Reporter)

Comment 3

4 years ago
No, you wouldn't be supposed to do something else. As you can see from the code, "window.doIt()" has been explicitly defined.

I've just re-checked reproduction in Nightly.
We shouldn't be breaking on exceptions triggered by console errors to begin with, so fixing bug 925569 would probably fix this bug as well.

Updated

4 years ago
Summary: Debugger becomes unresponsive when breaking on exception called by console → Debugger becomes unresponsive when pausing on exception thrown by console
(Reporter)

Comment 5

4 years ago
Eddy, I didn't mean the "pause/break on exception" feature, but rather when you add a breakpoint in code and call it with the console to debug it.
(Reporter)

Updated

4 years ago
Version: 33 Branch → 35 Branch
(Reporter)

Updated

4 years ago
Summary: Debugger becomes unresponsive when pausing on exception thrown by console → Debugger becomes unresponsive when breaking on exception thrown in function called by console
(Reporter)

Comment 6

3 years ago
Can't reproduce anymore in Fx 40.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → WORKSFORME

Updated

2 months ago
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.