安装npm install --save-dev [email protected]错误?

问题描述 投票:2回答:1

我正在尝试安装web3.js库并获得以下问题。

  • Node.js 8.x
  • Windows 7的。

我能够在这个文件夹下找到python安装。

C:\ Users \用户Mabel.windows建造工具\ python27

C:\ Program Files \ nodejs \ node_modules \ npm \ node_modules \ npm-lifecycle \ node-gyp-bin \ .... \ node_modules \ node-gyp \ bin \ node-gyp.js“rebuild”else(node“C :\ Program Files \ nodejs \ node_modules \ npm \ node_modules \ node-gyp \ bin \ node-gyp.js“rebuild)

gyp ERR!配置错误gyp ERR! stack错误:找不到Python可执行文件“python \ path \ to \ executable”,可以设置PYTHON env变量。 gyp ERR!堆栈在PythonFinder.failNoPython(C:\ Program Files \ nodejs \ node_mo dules \ npm \ node_modules \ node-gyp \ lib \ configure.js:483:19)


cmd showing the error on Windows

javascript python-2.7 ethereum web3js
1个回答
0
投票

npm config set python C:\ Python27 \ python.exe

上面的命令解决了这个问题。

© www.soinside.com 2019 - 2024. All rights reserved.