Spawn node-debug process from atom


#1

I am trying to start and stop a node process from a package in atom. I have been able to do it by using
ls=spawn “node”,[path to file] in the start and @ls.kill in the stop event.

However, I seem to encounter an issue when I try debugging using node-debug. I debug node js applications with the “node-debug filename.js” and everything works fine. When I try spawning the same command, the behaviour is incorrect. The node-debugger starts and runs fine on the intended port of 8080 but it is does not start my filename.js process that is also a server but running at port 8090. Does anyone have an idea as to what might be going wrong? Basically just the “node-debug” command is getting executed and it is not taking the arguments to it. Same problem occurs even on trying with exec( there the entire command is just fed to the exec process)

TO check if it is an issue with Node-inspector I also tried “exec” a process from a node js project and the debugger works totally as expected. It launches chrome and immediately attaches to the target project given as the command. The same command though does not work properly in Atom package. It launches google chrome and doesnt latch on to the target process.


#2

This seems to be an issue with Node-Inspector. Have opened a Issue https://github.com/node-inspector/node-inspector/issues/833