用EclipsedebuggingNode.js

我正在尝试使用Google的V8debugging器插件来debuggingNode.js(v0.6.1)。 我Eclipse v4.1.0 on Windows7使用Eclipse v4.1.0 on Windows7 。 我按照github上的详细说明 ,但每当我尝试附加到正在运行的node.js(端口5858)进程,我得到一个popup式错误消息说:

 An internal error occurred during: "Debug session initialization: Node-5858". Exception occured in callback 

有什么build议么 ?

我一直在寻找类似的问题,这是我发现的

设置它的说明,可能只是值得重新阅读这些以确保一切都是应该的:

https://github.com/joyent/node/wiki/Using-Eclipse-as-Node-Applications-Debugger

请注意,当我在Google代码上find这个帮助票据时,发现类似的问题时,它涉及到一些在Windows上有Node.js问题的用户:

http://code.google.com/p/chromedevtools/issues/detail?id=53

这可能是值得下载最新版本的Node.js,因为我相信现在已经有了修复程序,否则下载修复文件,然后在故障单中提及。

您可以尝试testingNodeclipse版本0.2.0testing版。

http://www.tomotaro1065.com/nodeclipse/

expression项目的生成

 Select the [File]-[New]-[Project] menu. Select [Node]-[Express Project], and push [Next] button. Enter [Project name], and push [Finish] button. 

debugging

 Open the JavaScript source files that you want to set breakpoints. Double-click on the ruler at the left end of the line you want to set a breakpoint. If you want to remove a breakpoint, double-click on the ruler again. Select the main source file of Node Application on the Project Explorer, open the context menu by right-clicking, select the [Debug As]-[Node Application] menu. 

试试这个:

创build项目后,转到cmd并提供要debugging的文件的文件path。 现在运行命令节点–debug-brk demo_node.js(其中demo_node.js是文件名)

现在来到eclipse方面,打开相同的文件并设置断点。 右键单击源文件并select[debugging方式] – [节点应用程序]。