Reloading with a breakpoint set causes: "TypeError: info is null"

NEW
Unassigned

Status

()

Firefox
Developer Tools: Debugger
4 years ago
10 months ago

People

(Reporter: jryans, Unassigned)

Tracking

(Blocks: 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

STR:

1. Go to mozilla.org
2. Set a breakpoint at tabzilla.js:74 (the line says |var minimumJQuery = '1.7.1'|)
3. Reload the page

Things seem function okay, but the following stack is logged:

Handler function threw an exception: TypeError: info is null
Stack: _addBreakpoint@resource://gre/modules/commonjs/toolkit/loader.js -> resource:///modules/devtools/sourceeditor/debugger.js:137:5
addBreakpoint/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource:///modules/devtools/sourceeditor/debugger.js:153:37
makeInfallible/<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/DevToolsUtils.js:83:14
EventLoop.prototype.enter@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/actors/script.js:410:5
ThreadActor.prototype._pushThreadPause@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/actors/script.js:609:5
ThreadActor.prototype._pauseAndRespond@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/actors/script.js:783:7
BreakpointActor.prototype.hit@resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/server/actors/script.js:4464:12
Tabzilla<@https://mozorg.cdn.mozilla.net/en-US/tabzilla/tabzilla.js?build=cef0a04:74:9
@https://mozorg.cdn.mozilla.net/en-US/tabzilla/tabzilla.js?build=cef0a04:72:17
Line: 137, column: 4
Created attachment 8480617 [details] [diff] [review]
Restore the timeout for updateEditorBreakpoints to avoid a race in CodeMirror

Turns out that the patch from bug 1016310 isn't as successful as the one from bug 957174 for regular browser use, although it seemed to have a bigger impact in reducing oranges. In this patch I'm just putting the timeout back, as I still haven't found the time to dig into CodeMirror and understand the reason for this race. I verified that it fixes this case.
Attachment #8480617 - Flags: review?(vporof)
Assignee: nobody → past
Status: NEW → ASSIGNED
Comment on attachment 8480617 [details] [diff] [review]
Restore the timeout for updateEditorBreakpoints to avoid a race in CodeMirror

Review of attachment 8480617 [details] [diff] [review]:
-----------------------------------------------------------------

::: browser/devtools/debugger/debugger-controller.js
@@ +1172,5 @@
>      // both in the editor and the breakpoints pane.
>      DebuggerController.Breakpoints.updatePaneBreakpoints();
> +    setNamedTimeout("update-editor-bp", EDITOR_BREAKPOINTS_UPDATE_DELAY, () => {
> +      DebuggerController.Breakpoints.updateEditorBreakpoints();
> +    });

Shouldn't we do the same thing in the other function?
Attachment #8480617 - Flags: review?(vporof) → review+
It doesn't seem necessary, because the _onNewSource path is the one that we hit when we set a breakpoint on reload. I've been trying to minimize the extent of these workarounds, but I'm watching it closely and if I ever see a stack trace that includes the _onSourcesAdded path, I'll change it, too.

Updated

4 years ago
Summary: Reload with breakpoint set: TypeError: info is null → Reloading with a breakpoint set causes: "TypeError: info is null"
Duplicate of this bug: 1104936
Duplicate of this bug: 1109304
Blocks: 1088153
Duplicate of this bug: 1088153

Updated

4 years ago
Blocks: 1074182
I tried it a couple of times, but I can no longer reproduce this using the given STR. Panos, could you confirm this?
Flags: needinfo?(past)
Try the STR in bug 1104936. That still throws for me.
Flags: needinfo?(past)
I no longer have the time to work on this.
Assignee: past → nobody
Status: ASSIGNED → NEW
Attachment #8480617 - Attachment is obsolete: true
Created attachment 8876340 [details]
tex-image-with-format-and-type.html

I can reproduce this, it just happened to me while I was fixing another bug
with WebGL conformance.

Steps:
1) Open attached html in nightly
2) add '?webglVersion=2' to end of url
2) Open web inspector
3) Open debugger tab and enable split console
4) Type random stuff (1 + 2 + 3) into the js console, it will evaluate it
5) Reload the page
6) Let it hit the 'debugger;' statement I inserted and press continue
until page is fully reloaded
7) Reload again
8) Continue to debugger; statement
9) Evaluation in the js console no longer works.

I was able to reproduce this three times using Nightly 55.0a1 (64-bit / Linux).
The fourth time it stopped doing it so I'm not sure what changed.
You need to log in before you can comment on or make changes to this bug.