Skip to content

Meaningful node inspect context titles #16600

Description

@filmerjarred

Problem: When inspecting multiple node contexts using the new --inspect flag paired with the dedicated node inspect in chrome dev tools, knowing which process you're currently inspecting can be confusing as they're all called "Nodejs Main Context" as per (I think):

contextCreated(env->context(), "Node.js Main Context");

Potential solutions:

  • Taking an optional environment variable like NODE_CONTEXT_TITLE (looks like the env might already be being passed in there, not sure if same env as process.env?)
  • Could pass in a flag along the lines of --inspect-context-title

Activity

  1. added
    feature requestIssues requesting new Node.js features.
    inspectorIssues and PRs related to the V8 inspector protocol.
    on Oct 30, 2017
  2. Fishrock123 commented on Nov 2, 2017

    @Fishrock123
    Contributor

    Shouldn't it just take process.title?

  3. filmerjarred commented on Nov 3, 2017

    @filmerjarred
    Author

    Often the process title is just 'npm' or 'node' so you get the same problem. Ideally, I'd like to click the context dropdown and see 'Service A' and 'Service B' for ease of debugging. Changing process.title also has limitations and side effects on other things as I understand it

  4. addaleax commented on Nov 28, 2017

    @addaleax
    Member

    @bnoordhuis I guess this was fixed by #17087?

  5. filmerjarred commented on Nov 28, 2017

    @filmerjarred
    Author

    Looks to be 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature requestIssues requesting new Node.js features.inspectorIssues and PRs related to the V8 inspector protocol.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions