相关文章推荐
无邪的大熊猫  ·  VUE3+Typescript ...·  10 月前    · 
豪情万千的花生  ·  SQL SERVER ...·  1 年前    · 
when install open cv in windows error comes : node-pre-gyp ERR! Tried to download(403): https://node-opencv.s3.amazonaws.com/opencv/v6.0.0/Release/node-v48-win32-x64.tar.gz
opencv@6.0.0 install C:\Users\mukulsoftwap\Desktop\node-opencv-master
node-pre-gyp install --fallback-to-build
node-pre-gyp ERR! Tried to download(403): https://node-opencv.s3.amazonaws.com/opencv/v6.0.0/Release/node-v48-win32-x64.tar.gz
node-pre-gyp ERR! Pre-built binaries not found for opencv@6.0.0 and node@6.9.1 (node-v48 ABI) (falling back to source compile with node-gyp)
C:\Users\mukulsoftwap\Desktop\node-opencv-master>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\....\node_modules\node-gyp\bin\node-gyp.js" clean ) else (node "" clean )
C:\Users\mukulsoftwap\Desktop\node-opencv-master>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\....\node_modules\node-gyp\bin\node-gyp.js" configure --fallback-to-build --module=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64\opencv.node --module_name=opencv --module_path=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64 ) else (node "" configure --fallback-to-build --module=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64\opencv.node --module_name=opencv --module_path=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64 )
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "C:\Users\mukulsoftwap\AppData\Local\Programs\Python\Python35-32", you can set the PYTHON env variable.
gyp ERR! stack at failNoPython (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\configure.js:449:14)
gyp ERR! stack at C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\configure.js:404:11
gyp ERR! stack at FSReqWrap.oncomplete (fs.js:123:15)
gyp ERR! System Windows_NT 10.0.10240
gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "configure" "--fallback-to-build" "--module=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64\opencv.node" "--module_name=opencv" "--module_path=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64"
gyp ERR! cwd C:\Users\mukulsoftwap\Desktop\node-opencv-master
gyp ERR! node -v v6.9.1
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute 'node-gyp.cmd configure --fallback-to-build --module=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64\opencv.node --module_name=opencv --module_path=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64' (1)
node-pre-gyp ERR! stack at ChildProcess. (C:\Users\mukulsoftwap\Desktop\node-opencv-master\node_modules\node-pre-gyp\lib\util\compile.js:83:29)
node-pre-gyp ERR! stack at emitTwo (events.js:106:13)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:191:7)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:877:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
node-pre-gyp ERR! System Windows_NT 10.0.10240
node-pre-gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\mukulsoftwap\Desktop\node-opencv-master\node_modules\node-pre-gyp\bin\node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd C:\Users\mukulsoftwap\Desktop\node-opencv-master
node-pre-gyp ERR! node -v v6.9.1
node-pre-gyp ERR! node-pre-gyp -v v0.6.31
node-pre-gyp ERR! not ok
Failed to execute 'node-gyp.cmd configure --fallback-to-build --module=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64\opencv.node --module_name=opencv --module_path=C:\Users\mukulsoftwap\Desktop\node-opencv-master\build\opencv\v6.0.0\Release\node-v48-win32-x64' (1)
npm ERR! Windows_NT 10.0.10240
npm ERR! argv "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js" "install"
npm ERR! node v6.9.1
npm ERR! npm v3.10.8
npm ERR! code ELIFECYCLE
npm ERR! opencv@6.0.0 install: node-pre-gyp install --fallback-to-build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the opencv@6.0.0 install script 'node-pre-gyp install --fallback-to-build'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the opencv package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-pre-gyp install --fallback-to-build
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs opencv
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls opencv
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\Users\mukulsoftwap\Desktop\node-opencv-master\npm-debug.log
 👍 16
@vinnitu
vinnitu commented on 9 Nov 2016
$ wget https://node-opencv.s3.amazonaws.com/opencv/v6.0.0/Release/node-v11-linux-x64.tar.gz
--2016-11-09 10:24:41-- https://node-opencv.s3.amazonaws.com/opencv/v6.0.0/Release/node-v11-linux-x64.tar.gz
Resolving node-opencv.s3.amazonaws.com (node-opencv.s3.amazonaws.com)... 54.231.73.27
Connecting to node-opencv.s3.amazonaws.com (node-opencv.s3.amazonaws.com)|54.231.73.27|:443... connected.
HTTP request sent, awaiting response... 403 Forbidden
2016-11-09 10:24:42 ERROR 403: Forbidden.

解决:
1.remove package-lock.json
2.remove node_modules
3.npm install

@ mapbox / node-pre-gyp @ mapbox / node-pre-gyp使得从二进制文件发布和安装Node.js C ++插件变得容易 @mapbox/node-pre-gyp介于和 @mapbox/node-pre-gyp之间,并提供跨平台的二进制部署方法。 前一包装的特别说明 在2021年2月9日@mapbox/node-pre-gyp@1.0.0被。 不属于@mapbox组织的较旧的,不受范围限制的版本已被弃用,只有@mapbox/node-pre-gyp才会看到更新。 要升级到新软件包,请执行以下操作: npm uninstall node-pre-gyp --save npm install @mapbox/node-pre-gyp --save 一个名为node-pre-gyp的命令行工具,可以从二进制文件安装软件包的C ++模块。 各种针对开 二进制下载器 该模块根据给定版本的Node.js的要求下载远程二进制文件。 它还简化了对这些模块的需求。 它旨在实现Node.js v4兼容性(这就是为什么它使用tar和semver模块的旧版本的原因)。 该模块的目标是在无法进行本地构建时提供一种简单且轻巧的方式来处理预构建的本机模块。 npm install -S binary-downloader 此模块在package.json与node-pre-gyp相同的binary字段。 但是,它仅支持以下标签: platform node_napi_label 对于其他标签,请随时打开问题或公关! 另外,要获取下载的二进制文件的require字符串,您还必须执行以下操作: const PackageJSON = require ( './package.json' ) ; const bi 与一起使用可轻松支持本机模块的prebuilds。 笔记。 预node-gyp-build@4名称在和node-gyp-build@4 node-gyp-build@4已更改。 请参阅下面的文档。 node-gyp-build工作原理与 gyp相似,不同之处在于它将在重建项目之前检查是否存在构建或预构建。 它的主要用途是作为本机模块的npm安装脚本和绑定加载器,这些模块使用捆绑预 。 首先将node-gyp-build作为安装脚本添加到您的本机项目中 "scripts" : { "install" : "node-gyp-build" 然后在index.js ,而不是使用模块,而是使用node-gyp-build来加载 4.然后就报出如下错误 localhost:react-first changwei$ npm install --save react-router npm WARN deprecated core-js@1.2.7: core-js@ fsevents@1.2.4 install /Users/changwei/project/react-first/node_modules/fsevents > node in 请参考文章【重磅推荐】关于npm之代码升级顺利成功的完美攻略【package.json和package-lock.json的作用】:https://blog.csdn.net/weixin_4334.. 原因:node-zopfli的问题,node-zopfli是compression-webpack-plugin 0.3.2版本引用的依赖 解决:compression-webpack-plugin 2.0.0没有依赖node-zopfli,切换到2.0.0版本 package.json文件: package-lock.json文... 参考:http://blog.csdn.net/qq_26819733/article/details/55549241?locationNum=11&fps=1当github上下载别人的vue项目时候,在npm install 时候报错,亲测已解决npm install -g grunt-node-inspector 偶见另一方法:http://www.mamicode.com/inf 感觉这个错误很常见,解决方法也很简单粗暴,像截图中说的一样,更新一下就好了,也就是重新install一下 参考:https://www.npmjs.com/package/node-pre-gyp 这里说node-pre-gyp只能全局安装 所以小伙伴们只能退出项目目录,cd回到主目录,然后执行: sudo npm install node-pre-gyp -g 安装成功后回到你的项目目录继...