1

I am currently having trouble getting node inspector to work with Google Chrome. I am on Windows 7 64 bit.

here is info about node-inspector: https://github.com/node-inspector/node-inspector

when I run the following

node-debug app.js 

on a simple JavaScript file called app.js:

a = 5; b = 6; c = a + b; console.log(c); 

and I open up Chrome with the following URL:

 http://localhost:8080/debug?port=5858 

all I get is this empty page with nothing loaded except one little part of the Chrome debugging toolbar, no matter what I do, I even reinstalled Chrome ( and the Canary developer version too):

enter image description here

Anyone have any idea what could be going wrong? This is the simplest JavaScript application ever, and there node-inspector directions does not specify any other steps to take. Like I said, I resinstalled Chrome. I have node version v0.10.30, npm version v1.4.21 version and node-inspector version: v0.7.4.

Does anyone have a good idea how I can test Chrome debugging tools without involving node? I am new to all this.

When I installed node-inspector, I did get what looks like a warning:

enter image description here

4
  • It works for me like you have done. Did you use the -g option in "npm install -g node-inspector"? Commented Sep 3, 2014 at 21:16
  • When the empty page is loaded, open Chrome DevTools. Are there any errors/warning in the Console? Commented Sep 4, 2014 at 9:24
  • yes, used the g option, no errors or warnings in console. I am beginning to suspect that this has to do with the fact I am on a 64 bit machine, since my 32 bit Windows 7 machine works with the same settings. Commented Sep 4, 2014 at 22:54
  • 1
    Your Inspector screen looks like problem with ws module. How you can see some parts of inspector interface was loaded. But on next step inspector needs to open web socket and only after this it will finish to draw interface. Miroslav you can reproduce this problem by commenting this.wsServer.on('connection', handleWebSocketConnection.bind(this)); in debug-server.js Commented Sep 5, 2014 at 15:06

3 Answers 3

3

Try starting it without node-debug wrapper.

So, install node inspector:

npm install -g node-inspector 

In one terminal:

node --debug-brk app.js 

In a different terminal:

node-inspector 

Browse to http://localhost:8080/debug?port=5858

Sign up to request clarification or add additional context in comments.

5 Comments

Yes, originally I had it as you had. But I did get a warning when I ran "npm install -g node-inspector" each time. Please see my edited post above.
That looks fine. Don't see a warning.
I just tried it on Windows and it went fine. node v0.10.22. Does the command node-inspector works?
The same settings work on my other 32 bit Windows 7 machine, so my current hunch is that something to do with my 64 bit Windows 7 machine is causing the issue. All of the versioning is the same for node, npm, node-inspector, so that might be the problem. No idea how to fix it, except perhaps install the 32 bit version of everything on my 64 bit machine.
I have the same issue with node-inspector. The debug-brk doesn't seeem to make any difference. I'm running Ubuntu 14.04 on VirtualBox on Windows 7 64 bit. Everything's been reinstalled so I'm running latest stable releases of node and node-inspector. The app works fine (serving on port 80) but node-inspector can't 'find' server.js - it shows the web page but nothing under 'Source' in the top-left corner. There was an instance at the very beginning when it worked, only once, and since nothing...
1

i had the same issue. i then uninstalled node-inspector, installed it again. closed the cmd prompt which installed node-inspector (maybe this step made the difference). opened another cmd prompt to node-debug my.js. i can see the source file now.

Comments

1

I had a similar issue where going to http://localhost:8080/debug?port=5858 would result in an empty page. However going to http://127.0.0.1:8080/debug?port=5858 seems to do the trick.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.