EvanNotFound / hexo-theme-redefine

Simplicity in Speed, Purity in Design. Redefine Your Hexo Journey.
https://redefine.ohevan.com
GNU General Public License v3.0
1.41k stars 116 forks source link

[BUG] npm install nodejieba@2.5.2 安装错误 #355

Closed wkk-dev closed 3 months ago

wkk-dev commented 6 months ago

提交 Issue 前检查清单

Bug 描述

Node版本 18/20 hexo 7.1.0 主题版本2.6.1 操作系统 Windows11 Git版本2.44.0

npm install nodejieba@2.5.2 时报错如下 $ npm install nodejieba@2.5.2 npm ERR! code 1 npm ERR! path C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba npm ERR! command failed npm ERR! command C:\Windows\system32\cmd.exe /d /s /c node-pre-gyp install --fallback-to-build npm ERR! Failed to execute ‘C:\Program Files\nodejs\node.exe C:\Users\ADMIN\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba\build\Release\nodejieba.node --module_name=nodejieba --module_path=C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba\build\Release --napi_version=9 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v108’ (1) npm ERR! node-pre-gyp info it worked if it ends with ok npm ERR! node-pre-gyp info using node-pre-gyp@1.0.11 npm ERR! node-pre-gyp info using node@18.19.1 | win32 | x64 npm ERR! node-pre-gyp info check checked for “C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba\build\Release\nodejieba.node” (not found) npm ERR! node-pre-gyp http GET https://github.com/yanyiwu/nodejieba/releases/download/v2.5.2/nodejieba-v2.5.2-node-v108-win32-x64.tar.gz npm ERR! node-pre-gyp ERR! install response status 404 Not Found on https://github.com/yanyiwu/nodejieba/releases/download/v2.5.2/nodejieba-v2.5.2-node-v108-win32-x64.tar.gz npm ERR! node-pre-gyp WARN Pre-built binaries not installable for nodejieba@2.5.2 and node@18.19.1 (node-v108 ABI, unknown) (falling back to source compile with node-gyp) npm ERR! node-pre-gyp WARN Hit error response status 404 Not Found on https://github.com/yanyiwu/nodejieba/releases/download/v2.5.2/nodejieba-v2.5.2-node-v108-win32-x64.tar.gz npm ERR! gyp info it worked if it ends with ok npm ERR! gyp info using node-gyp@10.0.1 npm ERR! gyp info using node@18.19.1 | win32 | x64 npm ERR! gyp info ok npm ERR! gyp info it worked if it ends with ok npm ERR! gyp info using node-gyp@10.0.1 npm ERR! gyp info using node@18.19.1 | win32 | x64 npm ERR! gyp info find Python using Python version 3.12.1 found at “C:\Python312\python.exe” npm ERR! gyp http GET https://nodejs.org/download/release/v18.19.1/node-v18.19.1-headers.tar.gz npm ERR! gyp WARN install got an error, rolling back install npm ERR! gyp ERR! configure error npm ERR! gyp ERR! stack FetchError: request to https://nodejs.org/download/release/v18.19.1/node-v18.19.1-headers.tar.gz failed, reason: read ECONNRESET npm ERR! gyp ERR! stack at ClientRequest. (C:\Users\ADMIN\AppData\Roaming\npm\node_modules\npm\node_modules\minipass-fetch\lib\index.js:130:14) npm ERR! gyp ERR! stack at ClientRequest.emit (node:events:517:28) npm ERR! gyp ERR! stack at _destroy (node:_http_client:882:13) npm ERR! gyp ERR! stack at onSocketNT (node:_http_client:902:5) npm ERR! gyp ERR! stack at process.processTicksAndRejections (node:internal/process/task_queues:83:21) npm ERR! gyp ERR! System Windows_NT 10.0.22631 npm ERR! gyp ERR! command “C:\Program Files\nodejs\node.exe” “C:\Users\ADMIN\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js” “configure” “–fallback-to-build” “–module=C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba\build\Release\nodejieba.node” “–module_name=nodejieba” “–module_path=C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba\build\Release” “–napi_version=9” “–node_abi_napi=napi” “–napi_build_version=0” “–node_napi_label=node-v108” npm ERR! gyp ERR! cwd C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba npm ERR! gyp ERR! node -v v18.19.1 npm ERR! gyp ERR! node-gyp -v v10.0.1 npm ERR! gyp ERR! not ok npm ERR! node-pre-gyp ERR! build error npm ERR! node-pre-gyp ERR! stack Error: Failed to execute ‘C:\Program Files\nodejs\node.exe C:\Users\ADMIN\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba\build\Release\nodejieba.node --module_name=nodejieba --module_path=C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba\build\Release --napi_version=9 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v108’ (1) npm ERR! node-pre-gyp ERR! stack at ChildProcess. (C:\Users\ADMIN\Desktop\redefine\node_modules@mapbox\node-pre-gyp\lib\util\compile.js:89:23) npm ERR! node-pre-gyp ERR! stack at ChildProcess.emit (node:events:517:28) npm ERR! node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1098:16) npm ERR! node-pre-gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:303:5) npm ERR! node-pre-gyp ERR! System Windows_NT 10.0.22631 npm ERR! node-pre-gyp ERR! command “C:\Program Files\nodejs\node.exe” “C:\Users\ADMIN\Desktop\redefine\node_modules\@mapbox\node-pre-gyp\bin\node-pre-gyp” “install” “–fallback-to-build” npm ERR! node-pre-gyp ERR! cwd C:\Users\ADMIN\Desktop\redefine\node_modules\nodejieba npm ERR! node-pre-gyp ERR! node -v v18.19.1 npm ERR! node-pre-gyp ERR! node-pre-gyp -v v1.0.11 npm ERR! node-pre-gyp ERR! not ok

npm ERR! A complete log of this run can be found in: C:\Users\ADMIN\AppData\Local\npm-cache_logs\2024-03-22T14_15_43_681Z-debug-0.log

望作者赶快回复/修复

复现方法

No response

预期结果

No response

截图

Snipaste_2024-03-22_22-22-10 Snipaste_2024-03-22_22-22-25 Snipaste_2024-03-22_22-22-31

电脑操作系统

Windows 11

浏览器

Microsoft Edge

版本

122.0.2365.92 X64 位

移动端设备

Android 13

移动端操作系统

MIUI 14

浏览器

Microsoft Edge

版本

122.0.2365.92

其他

No response

FrederickBun commented 5 months ago

尝试使用 npm install nodejieba@2.6.0 安装新版本nodejieba看看

wkk-dev commented 5 months ago

似乎卡在这里了

wwwwwwwwwwwwSnipaste_2024-04-04_17-50-43
FrederickBun commented 5 months ago

安装完了吗

FrederickBun commented 5 months ago

我macOS装了2.5.2安装试过了,但是部署的时候报错,就换成了2.6.0

wkk-dev commented 5 months ago

不行啊,还是同样的问题 gpy

FrederickBun commented 5 months ago

我之前windows也装不上这玩意儿

FrederickBun commented 5 months ago

nodejieba写的很烂

FrederickBun commented 5 months ago

对了对了,你运行 node -vnpm -v 截图给我看看

wkk-dev commented 5 months ago

look image

FrederickBun commented 5 months ago

看起来没啥问题,你去加evan微信问问

me.ohevan.com

wkk-dev commented 5 months ago

image

FrederickBun commented 5 months ago

搜索 evanovation

FrederickBun commented 5 months ago

搜索 evanovation

用微信搜啊

wkk-dev commented 5 months ago

o

EvanNotFound commented 5 months ago

网络问题

FrederickBun commented 5 months ago

网络问题

但是我Windows之前也是同样的报错,换mac之后为啥就可以装

wkk-dev commented 5 months ago

image

它是指这个问题

FrederickBun commented 5 months ago

image

它是指这个问题

666

github-actions[bot] commented 3 months ago

This issue is stale because it has been open for 30 days with no activity.