首页 前端知识 npm install --global --production windows-build-tools下载问题

npm install --global --production windows-build-tools下载问题

2024-07-29 00:07:45 前端知识 前端哥 710 904 我要收藏

今天遇到一个项目要去下载各种的依赖其中就包括的但是下载的时候一直提示失败,显示python的依赖一直下载不下来,我尝试了采用切换镜像,cnpm等单独下载等等都没有解决,报错信息

最好采用

命令就能成功下载

npm --python_mirror=https://registry.npmmirror.com/-/binary/python/ install --global windows-build-tools 

参考帖子为node.js - Windows-Build-Tools cannot download python - Stack Overflow 

十分感谢大佬

Downloading python-2.7.15.amd64.msi
Error: getaddrinfo EAI_AGAIN www.python.org:443
Downloading Python failed. Error: { Error: getaddrinfo EAI_AGAIN www.python.org:443
    at Object._errnoException (util.js:992:11)
    at errnoException (dns.js:55:15)
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:92:26)
  code: 'EAI_AGAIN',
  errno: 'EAI_AGAIN',
  syscall: 'getaddrinfo',
  hostname: 'www.python.org',
  host: 'www.python.org',
  port: 443 }
windows-build-tools will now exit.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! windows-build-tools@5.1.0 postinstall: `node ./dist/index.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the windows-build-tools@5.1.0 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\blahblah\AppData\Roaming\npm-cache\_logs\2019-06-13T00_02_38_046Z-debug.log
转载请注明出处或者链接地址:https://www.qianduange.cn//article/14547.html
标签
评论
发布的文章

JQuery中的load()、$

2024-05-10 08:05:15

大家推荐的文章
会员中心 联系我 留言建议 回顶部
复制成功!