错误! code 1.Why 这个错误消息会发生 npm ERR!代码 1?我该如何解决
npm ERR! code 1.Why this error massage gonna happen npm ERR! code 1? How can I fix it
这是错误代码:
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: 'reactjs-percentage-circle@1.0.0',
npm WARN EBADENGINE required: { node: '>=6.0.0', npm: '~3.3.6' },
npm WARN EBADENGINE current: { node: 'v15.10.0', npm: '7.16.0' }
npm WARN EBADENGINE }
npm ERR! code 1
npm ERR! path D:\Buman Project\geniusClone\node_modules\node-sass
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node-gyp rebuild
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@3.8.0
npm ERR! gyp info using node@15.10.0 | win32 | x64
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
npm ERR! gyp ERR! stack at PythonFinder.failNoPython (D:\Buman Project\geniusClone\node_modules\node-gyp\lib\configure.js:484:19)
npm ERR! gyp ERR! stack at PythonFinder.<anonymous> (D:\Buman Project\geniusClone\node_modules\node-gyp\lib\configure.js:509:16)npm ERR! gyp ERR! stack at callback (D:\Buman Project\geniusClone\node_modules\graceful-fs\polyfills.js:299:20)
npm ERR! gyp ERR! stack at FSReqCallback.oncomplete (node:fs:196:21)
npm ERR! gyp ERR! System Windows_NT 10.0.18363
npm ERR! gyp ERR! command "C:\Program Files\nodejs\node.exe" "D:\Buman Project\geniusClone\node_modules\node-gyp\bin\node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd D:\Buman Project\geniusClone\node_modules\node-sass
npm ERR! gyp ERR! node -v v15.10.0
npm ERR! gyp ERR! node-gyp -v v3.8.0
npm ERR! gyp ERR! not ok
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Zolboo\AppData\Local\npm-cache\_logs21-06-06T12_41_51_207Z-debug.log
有两个问题
是一个警告(可能会被忽略)这个包需要一个 npm 版本 ~3.3.6
这意味着 >= 3.3.6
和 < 3.4
即,每个 3.3.x
其中 x >= 6
。您的 npm 版本 7.16.
不满足此要求。此外,
node-gyp 需要在您的系统上安装 python 但没有找到任何...请参阅 docs 关于如何安装和配置 node-gyp windows.
这是错误代码:
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: 'reactjs-percentage-circle@1.0.0',
npm WARN EBADENGINE required: { node: '>=6.0.0', npm: '~3.3.6' },
npm WARN EBADENGINE current: { node: 'v15.10.0', npm: '7.16.0' }
npm WARN EBADENGINE }
npm ERR! code 1
npm ERR! path D:\Buman Project\geniusClone\node_modules\node-sass
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node-gyp rebuild
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@3.8.0
npm ERR! gyp info using node@15.10.0 | win32 | x64
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
npm ERR! gyp ERR! stack at PythonFinder.failNoPython (D:\Buman Project\geniusClone\node_modules\node-gyp\lib\configure.js:484:19)
npm ERR! gyp ERR! stack at PythonFinder.<anonymous> (D:\Buman Project\geniusClone\node_modules\node-gyp\lib\configure.js:509:16)npm ERR! gyp ERR! stack at callback (D:\Buman Project\geniusClone\node_modules\graceful-fs\polyfills.js:299:20)
npm ERR! gyp ERR! stack at FSReqCallback.oncomplete (node:fs:196:21)
npm ERR! gyp ERR! System Windows_NT 10.0.18363
npm ERR! gyp ERR! command "C:\Program Files\nodejs\node.exe" "D:\Buman Project\geniusClone\node_modules\node-gyp\bin\node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd D:\Buman Project\geniusClone\node_modules\node-sass
npm ERR! gyp ERR! node -v v15.10.0
npm ERR! gyp ERR! node-gyp -v v3.8.0
npm ERR! gyp ERR! not ok
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Zolboo\AppData\Local\npm-cache\_logs21-06-06T12_41_51_207Z-debug.log
有两个问题
是一个警告(可能会被忽略)这个包需要一个 npm 版本
~3.3.6
这意味着>= 3.3.6
和< 3.4
即,每个3.3.x
其中x >= 6
。您的 npm 版本7.16.
不满足此要求。此外,node-gyp 需要在您的系统上安装 python 但没有找到任何...请参阅 docs 关于如何安装和配置 node-gyp windows.