npm ERR! gyp ERR! stack FetchError: request to https://nodejs.org/download/release/v16.14.2/node-v16.14.2-headers.tar.gz failed, reason: self signed certificate in certificate chain
Details
When I try to install winax or win32ole package
I get the following error below
I tried:
-
npm config set strict-ssl falseand -
set NODE_TLS_REJECT_UNAUTHORIZED=0and -
npm config set ca ""
nothing helps :(
npm ERR! code 1
npm ERR! path D:\WebDev\Node\PusherPoll\node_modules\winax
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 [email protected]
npm ERR! gyp info using [email protected] | win32 | x64
npm ERR! gyp info find Python using Python version 3.8.6 found at "C:\Program Files\Python38\python.exe"
npm ERR! gyp http GET https://nodejs.org/download/release/v16.14.2/node-v16.14.2-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/v16.14.2/node-v16.14.2-headers.tar.gz failed, reason: self signed certificate in certificate chain
npm ERR! gyp ERR! stack at ClientRequest.<anonymous> (D:\Data\Users\yitzi-zi\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:526:28)
npm ERR! gyp ERR! stack at TLSSocket.socketErrorListener (node:_http_client:442:9)
npm ERR! gyp ERR! stack at emitErrorNT (node:internal/streams/destroy:157:8)
npm ERR! gyp ERR! stack at emitErrorCloseNT (node:internal/streams/destroy:122:3)
npm ERR! gyp ERR! stack at processTicksAndRejections (node:internal/process/task_queues:83:21)
npm ERR! gyp ERR! System Windows_NT 10.0.19042
npm ERR! gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\Data\\Users\\yitzi-zi\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd D:\WebDev\Node\PusherPoll\node_modules\winax
npm ERR! gyp ERR! node -v v16.14.2
npm ERR! gyp ERR! node-gyp -v v9.0.0
npm ERR! gyp ERR! not ok
Node.js version
v16.14.2
Example code
No response
Operating system
Windows 7
Scope
npm install winax or npm install win32ole
Module and version
Not applicable.
I'm experiencing this as well in v16.14+
v16.13 seems to work as expected.
一样的问题,更换v16.17.0, v18.12.0...最后安装最新的v19.0.0运行正常
same error in v20.11.1
Hi there, if this issue is reprocible with the latest and/or LTS version of Node.js. Please open a single new issue, with all information needed to reproduce.
这是来自QQ邮箱的自动回复邮件。您好,我已收到您发送的邮件,我会及时查看。非常感谢您的联系!