Having trouble implementing chrome debugging protocol - specifically Debugging.paused with callFrames specified

60 views
Skip to first unread message

Zac Hansen

unread,
Oct 5, 2016, 8:52:11 AM10/5/16
to Google Chrome Developer Tools
If i send Debugging.paused with no callFrames, inspector knows the javascript is paused.

However, if I try to specify callframes, it does not acknowledge it being paused.   I'd like to try to work through this myself, but cannot find the un-minified source for inspector.  

Below is my non-working message.  I know not everything is in there or good (this isn't really undefined), but I don't know what to focus on to get things working.

Any help is appreciated.  

Thank you
--Zac

  1. method:"Debugger.paused"
  2. params:{callFrames: [{callFrameId: "bogus call frame id", functionName: "a",…}], reason: "other",…}
    1. callFrames:[{callFrameId: "bogus call frame id", functionName: "a",…}]
      1. 0:{callFrameId: "bogus call frame id", functionName: "a",…}
        1. callFrameId:"bogus call frame id"
        2. functionName:"a" <== correct function name
        3. location:{scriptId: "55", lineNumber: 13, columnNumber: 0}
          1. columnNumber:0
          2. lineNumber:13 <== correct line number
          3. scriptId:"55" <== This is a correct script id for the script my breakpoint is in
        4. scopeChain:[]
        5. this:{result: {type: "undefined", value: undefined, description: "undefined"}, wasThrown: false}
          1. result:{type: "undefined", value: undefined, description: "undefined"}
            1. description:"undefined" <== hard coded
            2. type:"undefined"
            3. value:undefined
          2. wasThrown:false
    2. hitBreakpoints:["v8toolkit://a9c1cdc8-19c0-4b0b-a9de-4005148f06a7/debugger_sample.js:12:19"]
      1. 0:"v8toolkit://a9c1cdc8-19c0-4b0b-a9de-4005148f06a7/debugger_sample.js:12:19"
    3. reason:"other"

Zac Hansen

unread,
Oct 5, 2016, 9:16:45 AM10/5/16
to Google Chrome Developer Tools
I figured out my specific problem -- it didn't like this "this" being undefined.  I throw an empty object at it and it's happy.

But still any advice for debugging when the messages are valid json but the data isn't acceptable would be great, or just where to find the inspector.js source.

Thank you.

Jason Laster

unread,
Oct 5, 2016, 9:22:52 AM10/5/16
to Google Chrome Developer Tools
Hi Zac,

Here is a link to the protocol viewer, there are debugger events and commands. Events come down from the browser, commands are sent to the browser to do something. Debugger.paused is an event that you should receive with all of the data.

There are several libraries you can use that wrap the protocol and make it easier to work with


I'll be releasing a similar library we use on the Firefox Debugger team to speak the protocol and connect to chrome soon, but here are some links if it helps




--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-chrome-developer-tools/26d54c73-146b-4668-a6e3-68459263815a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Zac Hansen

unread,
Oct 5, 2016, 9:24:52 AM10/5/16
to google-chrome-...@googlegroups.com
I wasn't very specific, I suppose.   I'm building the "server" side of things.   I want my embedded-v8 application to be debuggable by inspector.js.   

To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-chrome-developer-tools/CAH_2F5E%2Bqi1ikQK1B52rBcwYHg621MqQLrk969OwePLHBMvacA%40mail.gmail.com.

Jason Laster

unread,
Oct 5, 2016, 10:43:01 AM10/5/16
to google-chrome-...@googlegroups.com
Ahh, that makes more sense. Depending on what version of V8 you plan on using, you might be able to use the new built in protocol work. 



To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-develo...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-chrome-developer-tools/CABi3GVCiC_LeQC7X4KbdgS_m_ufH8GxOd6MzX6oUCO8S%3DaV8nA%40mail.gmail.com.

Zac Hansen

unread,
Oct 5, 2016, 10:53:33 AM10/5/16
to google-chrome-...@googlegroups.com
"new built-in protocol" ?   I know of the v8::Debug namespace and the debug.js library here:  https://github.com/v8/v8/blob/master/src/debug/debug.js

but I don't know of how either of those integrates with the chrome debugging protocol.

Any insight would be awesome.

To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.

Jason Laster

unread,
Oct 5, 2016, 11:12:58 AM10/5/16
to google-chrome-...@googlegroups.com
Here is the Node issue that describes the chrome team's work on V8 Inspector.


The gist, as I believe it, is that the blink backend is being ported to V8. This will allow projects that use v8 (e.g. node) to expose a debugger server. 

To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-develo...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-develo...@googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-chrome-developer-tools/CABi3GVBUyVe2CQBazwgz7QjphQgLqqgQuLY99JkozZXMD4jHuQ%40mail.gmail.com.

Zac Hansen

unread,
Oct 5, 2016, 11:19:34 AM10/5/16
to google-chrome-...@googlegroups.com
That's very cool - it's exactly what I need.  Any idea where I can follow the development on it?  I posted in the thread you linked, but it's a closed issue, so I'm not sure anyone will see it.

--Zac

To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.

Seth Thompson

unread,
Oct 5, 2016, 2:36:20 PM10/5/16
to google-chrome-...@googlegroups.com
The V8 inspector migration is almost complete--the majority of work has been done. You can follow development in the source repo and via this bug. Upon completion we will document usage on the V8 GitHub wiki.

Cheers,
Seth

To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-develo...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-develo...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-chrome-developer-tools/mjiEae99CxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-chrome-develo...@googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-chrome-developer-tools/CABi3GVAAje4TXkUYaDxHxhK8T9D88R4oYHd0Q4TMf2b9GgpXAQ%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages