As a security precaution, we have turned on the setting "Require API key authentication for API requests" for everyone. If this has broken something, please contact
Last Comment Bug 659885 - Create GCLI command to support restarting the debugger
: Create GCLI command to support restarting the debugger
Product: Firefox
Classification: Client Software
Component: Developer Tools (show other bugs)
: Trunk
: All All
: -- normal (vote)
: ---
Assigned To: Joe Walker [:jwalker] (needinfo me or ping on irc)
: J. Ryan Stinnett [:jryans] (use ni?)
Depends on:
  Show dependency treegraph
Reported: 2011-05-26 01:42 PDT by Joe Walker [:jwalker] (needinfo me or ping on irc)
Modified: 2012-06-27 11:34 PDT (History)
1 user (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Description User image Joe Walker [:jwalker] (needinfo me or ping on irc) 2011-05-26 01:42:29 PDT
From dcamp:

OK, so if you build from the remote debug repo[1], there is a
DebuggerUI global on each navigator:browser chrome window (same scope
you'd normally be able to get at gBrowser from).

DebuggerUI has two methods of interest for you:

startDebugger() will fire up a debugger on the currently-selected tab
(due to some unfinished business, you can't start debuggers on
arbitrary tabs - only the currently-selected one).  It will return a
debugger pane object (I'll get to that in a minute).

getDebugger(aTab) will return the debugger pane for the given browser
tab.  I suggest calling it with gBrowser.selectedTab to get the
debugger on the currently-selected browser.

The debugger pane object[2] keeps an eye on the html debugger UI.  The
most interesting thing it has at the moment is a property called
"activeThread" which accesses the ThreadClient[3] object for the
currently-running debugger.  The only interesting method the
ThreadClient currently has on it is resume(), which will resume a
thread already paused at a debugger; statement.  I would suggest that
you check the ThreadClient's state property to make sure it is
"paused" before trying to resume - it won't fail usefully right now.

This is all very very rough, but hopefully it'll give you something to
play with.  Things should tighten up over the next week or two, and I
intend to dangle more useful commands/objects off of DebuggerUI that
should be useful for the command line.


Comment 1 User image Joe Walker [:jwalker] (needinfo me or ping on irc) 2011-05-26 02:52:06 PDT
Follow along:
Comment 2 User image Joe Walker [:jwalker] (needinfo me or ping on irc) 2011-05-27 02:40:45 PDT
See this patch:
(which depends on the other patches in the patch queue, but which should apply cleanly over
Comment 3 User image Joe Walker [:jwalker] (needinfo me or ping on irc) 2011-06-21 02:47:43 PDT
Marking verified because there is no UI proof that the bug is fixed. The proof is in the code.

Note You need to log in before you can comment on or make changes to this bug.