You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
proposal: programmatically expose the V8 inspector URL #11496
This is a feature request to add a method to the v8 module that exposes the V8 inspector URL if the process has been started with --inspect. The motivation for this feature is to conveniently add links or buttons to a website that the developer can click to open the V8 inspector.
We have plans of introducing bindings for inspector API (it is currently blocked on inspector becoming the default debug API, e.g. by installing the debug signal handler). I believe we could expose this url as a part of that API. API details are still TBD (e.g. I did not even open a pull request)...
FWIW you can get the URI and other metadata like the UUID from the JSON returned from http://localhost:9229/json/list (or http://localhost:9229/json) too. See #11207 for an example of that output.
This seems like a good idea. Perhaps even one step further ... an API that simply returns the same data as the /json/list endpoint.
As for where it should live, perhaps when running with --inspect, this can be exposed via process.inspectInfo() API. When running without --inspect, it would simply return undefined
WIP JS bindings version I have (
https://github.com/eugeneo/node/tree/js-bindings) has a project.inspector
object so it will be easy to expose targets there. But I am not sure what
it will take to land such an API change.
On Wed, Feb 22, 2017 at 8:48 AM James M Snell ***@***.***> wrote:
This seems like a good idea. Perhaps even one step further ... an API that
simply returns the same data as the /json/list endpoint.
As for where it should live, perhaps when running with --inspect, this
can be exposed via process.inspectInfo() API. When running without
--inspect, it would simply return undefined
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#11496 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AARkrYsCgBAIOA_y0MiGiuGqHrlwBzZxks5rfGbagaJpZM4MIT8_>
.
I think this URI should be also predictable and partially configurable from command line. As I mentioned in #11701 I'm working with remote debug and automated tools doesn't allow to extract this URI from node output.
Activity
bnoordhuis commentedon Feb 22, 2017
Should be easy enough to do but let's see what @nodejs/v8-inspector thinks.
Fishrock123 commentedon Feb 22, 2017
Sounds like a good idea to me. I think it should probably not be on the V8 module though?
eugeneo commentedon Feb 22, 2017
We have plans of introducing bindings for inspector API (it is currently blocked on inspector becoming the default debug API, e.g. by installing the debug signal handler). I believe we could expose this url as a part of that API. API details are still TBD (e.g. I did not even open a pull request)...
joshgav commentedon Feb 22, 2017
FWIW you can get the URI and other metadata like the UUID from the JSON returned from
http://localhost:9229/json/list(orhttp://localhost:9229/json) too. See #11207 for an example of that output.@ofrobots @cristiancavalli @eugeneo are working on providing a JS API to Inspector in general, perhaps access to the
listJSON object could be part of that API and cover this request too./cc @nodejs/diagnostics
jasnell commentedon Feb 22, 2017
This seems like a good idea. Perhaps even one step further ... an API that simply returns the same data as the
/json/listendpoint.As for where it should live, perhaps when running with
--inspect, this can be exposed viaprocess.inspectInfo()API. When running without--inspect, it would simply returnundefinedeugeneo commentedon Feb 22, 2017
rumkin commentedon Mar 5, 2017
I think this URI should be also predictable and partially configurable from command line. As I mentioned in #11701 I'm working with remote debug and automated tools doesn't allow to extract this URI from node output.
Trott commentedon Jul 30, 2017
Is this in progress? Stalled? Blocked? Help wanted? I guess /cc @eugeneo but really anyone that knows?
TimothyGu commentedon Jul 30, 2017
The requested feature is now provided in inspector.url(), so closing.
inspector: allow --inspect=host:port from js