为了账号安全,请及时绑定邮箱和手机立即绑定

cnpm安装依赖时,总是不成功呢?

cnpm安装依赖时,总是不成功呢?

慕姐9452250 2018-04-08 15:32:21
cnpm安装依赖时,总是出现错误,C:\Users\Administrator\Desktop\dasuan-front\dasuan-front\node_modules\_nodejieba@1.4.11@nodejieba>node "D:\newstudy\nodejs\node_global\node_modules\cnpm\node_modules\npminstall\node-gyp-bin\\node-gyp.js" rebuildgyp ERR! configure errorgyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.gyp ERR! stack     at PythonFinder.failNoPython (D:\newstudy\nodejs\node_global\node_modules\cnpm\node_modules\node-gyp\lib\configure.js:483:19)gyp ERR! stack     at PythonFinder.<anonymous> (D:\newstudy\nodejs\node_global\node_modules\cnpm\node_modules\node-gyp\lib\configure.js:508:16)gyp ERR! stack     at D:\newstudy\nodejs\node_global\node_modules\cnpm\node_modules\graceful-fs\polyfills.js:284:29gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:152:21)gyp ERR! System Windows_NT 6.1.7601gyp ERR! command "D:\\newstudy\\nodejs\\node.exe" "D:\\newstudy\\nodejs\\node_global\\node_modules\\cnpm\\node_modules\\npminstall\\node-gyp-bin\\node-gyp.js" "rebuild"gyp ERR! cwd C:\Users\Administrator\Desktop\dasuan-front\dasuan-front\node_modules\_nodejieba@1.4.11@nodejiebagyp ERR! node -v v8.9.3gyp ERR! node-gyp -v v3.6.2gyp ERR! not ok[nodejieba@^1.3.0] optional install error: Error: Run "C:\Windows\system32\cmd.exe /d /s /c node-gyp rebuild" error, exit code 1    at ChildProcess.proc.on.code (D:\newstudy\nodejs\node_global\node_modules\cnpm\node_modules\runscript\index.js:74:21)    at emitTwo (events.js:126:13)    at ChildProcess.emit (events.js:214:7)    at maybeClose (internal/child_process.js:925:16)    at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)platform unsupported babel-loader@6.4.1 › webpack@2.7.0 › watchpack@1.5.0 › chokidar@2.0.3 › fsevents@^1.1.2 Package require os(darwin) not compatible with your platform(win32)[fsevents@^1.1.2] optional install error: Package require os(darwin) not compatible with your platform(win32)Downloading binary from https://npm.taobao.org/mirrors/node-sass/v4.8.3/win32-x64-57_binding.nodeDownload completeBinary saved to C:\Users\Administrator\Desktop\dasuan-front\dasuan-front\node_modules\_node-sass@4.8.3@node-sass\vendor\win32-x64-57\binding.nodeCaching binary to C:\Users\Administrator\.npminstall_tarball\node-sass\4.8.3\win32-x64-57_binding.nodeBinary found at C:\Users\Administrator\Desktop\dasuan-front\dasuan-front\node_modules\_node-sass@4.8.3@node-sass\vendor\win32-x64-57\binding.nodeTesting binaryBinary is finepeerDependencies link ajv@4.11.8 in C:\Users\Administrator\Desktop\dasuan-front\dasuan-front\node_modules\_ajv-keywords@1.5.1@ajv-keywords unmet with C:\Users\Administrator\Desktop\dasuan-front\dasuan-front\node_modules\ajv(5.5.2)peerDependencies WARNING axios-status@0.0.12 requires a peer of axios@^0.14.0 but axios@0.15.3 was installeddeprecate babel-preset-es2015@^6.24.1 ????  Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update!Recently updated (since 2018-04-01): 11 packages (detail see file C:\Users\Administrator\Desktop\dasuan-front\dasuan-front\node_modules\.recently_updates.txt)  Today:    → vue-touch@2.0.0-beta.4 › rollup-plugin-node-resolve@2.1.1 › resolve@^1.1.6(1.7.0) (05:38:05)    → html-webpack-plugin@2.30.1 › html-minifier@^3.2.3(3.5.14) (03:51:32)    → html-webpack-plugin@2.30.1 › html-minifier@3.5.14 › uglify-js@3.3.x(3.3.20) (03:08:55)    → node-sass@4.8.3 › request@2.79.0 › aws4@^1.2.1(1.7.0) (06:24:14)该怎么解决啊
查看完整描述

1 回答

?
西兰花伟大炮

TA贡献376条经验 获得超318个赞

好像是没设置python的环境变量

查看完整回答
反对 回复 2018-04-10
  • 1 回答
  • 0 关注
  • 7314 浏览
慕课专栏
更多

添加回答

举报

0/150
提交
取消
微信客服

购课补贴
联系客服咨询优惠详情

帮助反馈 APP下载

慕课网APP
您的移动学习伙伴

公众号

扫描二维码
关注慕课网微信公众号