C
C
Coder3212017-08-13 17:13:29
Code editor
Coder321, 2017-08-13 17:13:29

How to debug two processes in VS code?

There is a main process and child with ws servers. I launch the child through child_process fork.
Debugger settings:

"configurations": [
        {
            "name": "Launch via NPM",
            "type": "node",
            "request": "launch",
            "cwd": "${workspaceRoot}/server",
            "runtimeExecutable": "npm",
            "runtimeArgs": [
                "run-script",
                "start:debug"
            ],
            "port": 5858
        }
    ]

"start:debug": "npm run build && node --nolazy --inspect-brk=5858 src/app.js"

The main process debugs without problems, the child does not. How to fix? Is it even possible to debug all processes at the same time?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
SergeyBugai, 2017-08-13
@Coder321

There is a field in the config for this more details

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question