Closed Bug 1532244 Opened 5 years ago Closed 5 years ago

Debugger state gets confused when debugging gmail on beta

Categories

(DevTools :: Debugger, defect, P2)

defect

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1394998

People

(Reporter: Gijs, Unassigned)

References

Details

+++ This bug was initially created as a clone of Bug #1532240 +++

STR:

  1. 66beta12, on mac

  2. open gmail and log in.

  3. open inspector

  4. click {event} bubble on <html> (this doesn't work on nightly, see bug 1532237) . Expand the first 'click' event handler (there are a lot).

  5. click the "go to this in the debugger" button

  6. stare in confusion at the minified JS, and click "pretty print" button in the bottom left hand corner

  7. lose your place, so go back to inspector, repeat step 3/4 (I'm assuming this is already on file elsewhere).

  8. the debugger focuses the addEventListener call.

    b.addEventListener(c.toString(), e, f);

  9. set a breakpoint here.

  10. click an empty bit of space in the page (e.g. to the right of the search field, and to the left of the set of icons in the top right corner)

ER:
the breakpoint either gets hit or doesn't get hit, and the focused line will be the line that has the breakpoint on it.

AR:
the debugger stops for the breakpoint, but for handling the click event in the actual event listener, which is a few lines down in the source code. The screenshot in bug 1431400 shows this case.

Priority: -- → P2

With the recent breakpoint work, I wonder if this still persists. Could you help by re-testing, :Gijs?

Flags: needinfo?(gijskruitbosch+bugs)

(In reply to :Harald Kirschner :digitarald from comment #1)

With the recent breakpoint work, I wonder if this still persists. Could you help by re-testing, :Gijs?

Following the steps in comment #0 on current beta (67), I get stuck at step 6 because repeating the steps always loads the non-pretty-printed version of the script, so I can't even see the event listener I want to debug. So things haven't really improved much for this case.

Flags: needinfo?(gijskruitbosch+bugs) → needinfo?(hkirschner)

Following the steps in comment #0 on current beta (67), I get stuck at step 6 because repeating the steps always loads the non-pretty-printed version of the script, so I can't even see the event listener I want to debug.

This works for me. It even jumps to the right event listener. Breakpoints also worked, including Logpoints.

Flags: needinfo?(hkirschner)

(In reply to :Harald Kirschner :digitarald from comment #3)

Following the steps in comment #0 on current beta (67), I get stuck at step 6 because repeating the steps always loads the non-pretty-printed version of the script, so I can't even see the event listener I want to debug.

This works for me. It even jumps to the right event listener. Breakpoints also worked, including Logpoints.

On beta or on nightly?

Flags: needinfo?(hkirschner)

Nightly.

Flags: needinfo?(hkirschner)

(In reply to :Harald Kirschner :digitarald from comment #5)

Nightly.

On Nightly, for me the line in question gets hit for mousemove events, but not for click events, and although the "Paused on breakpoint" warning shows up, the line is sometimes not highlighted. I haven't been able to figure out a pattern for when this does and doesn't happen.

Do you want me to file a separate bug for pretty print and "go to this event listener in the debugger" not working properly on beta? Are you aware of a separate bug already on file, and/or are we OK shipping that regression to beta?

Flags: needinfo?(hkirschner)

Do you want me to file a separate bug for pretty print and "go to this event listener in the debugger" not working properly on beta? Are you aware of a separate bug already on file, and/or are we OK shipping that regression to beta?

This long-standing issue should be tracked in bug 1532240, which is why I am thinking about closing this bug as dupe and make sure that bug 1532240 fixes both the position and potentially the highlighting (which does have issues apart from pretty printing, so probably not too related).

Flags: needinfo?(hkirschner)
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.