【发布时间】:2015-09-22 04:46:14
【问题描述】:
我试图在我的操作系统(Ubuntu 14.04)上为 AngularJs 设置 nodeJs,如下:guideline for installing angular js components 但是当尝试运行最后一个命令时,发现了这个错误。谁能帮忙。
usman@usman-cs:~/angular-phonecat$ npm run protractor
angular-phonecat@0.0.0 量角器 /home/usman/angular-phonecat npm run update-webdriver
angular-phonecat@0.0.0 preupdate-webdriver /home/usman/angular-phonecat npm 安装
angular-phonecat@0.0.0 安装后 /home/usman/angular-phonecat 凉亭安装
angular-phonecat@0.0.0 update-webdriver /home/usman/angular-phonecat webdriver-manager 更新
selenium 独立版是最新的。 chromedriver 是最新的。
angular-phonecat@0.0.0 量角器 /home/usman/angular-phonecat 量角器测试/protractor-conf.js
Starting selenium standalone server...
[launcher] Running 1 instances of WebDriver
[launcher] Process exited with error code 1
events.js:72
throw er; // Unhandled 'error' event
^
Error: spawn ENOENT
at errnoException (child_process.js:988:11)
at Process.ChildProcess._handle.onexit (child_process.js:779:34)
npm ERR! weird error 8
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
/usr/share/doc/nodejs/README.Debian
npm ERR! not ok code 0
usman@usman-cs:~/angular-phonecat$
【问题讨论】:
-
ENOENT错误一般是因为没有找到东西。错误说您可能有一个遗留节点二进制文件,并且 npm 可能正在寻找未找到的东西。检查您的安装是否正常 -
您的路径上可能安装了错误的“节点”二进制文件。
which node或where node说什么? (或者,如果您运行node,您会收到 nodejs 提示或其他提示吗?)如错误所示,请阅读 /usr/share/doc/nodejs/README.Debian
标签: angularjs node.js npm protractor