node-gyp icon indicating copy to clipboard operation
node-gyp copied to clipboard

Doesn't build on NodeJS 19.0.1

Open ThatOneCalculator opened this issue 3 years ago • 1 comments

  • Node Version: v19.0.1
  • Platform: Linux Ubuntu SMP x86_64 GNU/Linux
  • Compiler: gcc version 9.4.0 (Ubuntu 9.4.0-1ubuntu1~20.04.1)
  • Module: re2
Verbose output (from npm or node-gyp):
➤ YN0008: │ esbuild@npm:0.14.54 must be rebuilt because its dependency tree changed
➤ YN0009: │ re2@npm:1.17.7 couldn't be built successfully (exit code 1, logs can be found here: /tmp/xfs-6a01c75b/build.log)
➤ YN0000: └ Completed in 24s 261ms
➤ YN0000: Failed with errors in 46s 646ms
➜  calckey git:(develop) ✗ cat /tmp/xfs-6a01c75b/build.log
# This file contains the result of Yarn building a package (re2@npm:1.17.7)
# Script name: install

Trying https://github.com/uhop/node-re2/releases/download/1.17.7/linux-x64-111.br ...
Trying https://github.com/uhop/node-re2/releases/download/1.17.7/linux-x64-111.gz ...
Building locally ...

> [email protected] rebuild
> node-gyp rebuild

gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | linux | x64
gyp info find Python using Python version 3.8.10 found at "/usr/bin/python3"
gyp http GET https://nodejs.org/download/release/v19.0.1/node-v19.0.1-headers.tar.gz
gyp http 200 https://nodejs.org/download/release/v19.0.1/node-v19.0.1-headers.tar.gz
gyp http GET https://nodejs.org/download/release/v19.0.1/SHASUMS256.txt
gyp http 500 https://nodejs.org/download/release/v19.0.1/SHASUMS256.txt
gyp WARN install got an error, rolling back install
gyp ERR! configure error 
gyp ERR! stack Error: 500  status code downloading checksum
gyp ERR! stack     at downloadShasums (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:214:15)
gyp ERR! stack     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
gyp ERR! stack     at async Promise.all (index 1)
gyp ERR! stack     at async go (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:189:5)
gyp ERR! stack     at async install (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:62:18)
gyp ERR! System Linux 5.4.0-122-generic
gyp ERR! command "/home/misskey/.nvm/versions/node/v19.0.1/bin/node" "/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/misskey/calckey/node_modules/.store/re2-npm-1.17.7-02f9dd5be3/node_modules/re2
gyp ERR! node -v v19.0.1
gyp ERR! node-gyp -v v9.1.0
gyp ERR! not ok 
node:internal/process/promises:289
            triggerUncaughtException(err, true /* fromPromise */);
            ^

[UnhandledPromiseRejection: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason "1".] {
  code: 'ERR_UNHANDLED_REJECTION'
}

Node.js v19.0.1

> [email protected] rebuild
> node-gyp rebuild

gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | linux | x64
gyp info find Python using Python version 3.8.10 found at "/usr/bin/python3"
gyp http GET https://nodejs.org/download/release/v19.0.1/node-v19.0.1-headers.tar.gz
gyp http 200 https://nodejs.org/download/release/v19.0.1/node-v19.0.1-headers.tar.gz
gyp http GET https://nodejs.org/download/release/v19.0.1/SHASUMS256.txt
gyp http 500 https://nodejs.org/download/release/v19.0.1/SHASUMS256.txt
gyp WARN install got an error, rolling back install
gyp ERR! configure error 
gyp ERR! stack Error: 500  status code downloading checksum
gyp ERR! stack     at downloadShasums (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:214:15)
gyp ERR! stack     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
gyp ERR! stack     at async Promise.all (index 1)
gyp ERR! stack     at async go (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:189:5)
gyp ERR! stack     at async install (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:62:18)
gyp ERR! System Linux 5.4.0-122-generic
gyp ERR! command "/home/misskey/.nvm/versions/node/v19.0.1/bin/node" "/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/misskey/calckey/node_modules/.store/re2-npm-1.17.7-02f9dd5be3/node_modules/re2
gyp ERR! node -v v19.0.1
gyp ERR! node-gyp -v v9.1.0
gyp ERR! not ok 
➜  calckey git:(develop) ✗  "/home/misskey/.nvm/versions/node/v19.0.1/bin/node" "/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | linux | x64
gyp info find Python using Python version 3.8.10 found at "/usr/bin/python3"
gyp http GET https://nodejs.org/download/release/v19.0.1/node-v19.0.1-headers.tar.gz
gyp http 200 https://nodejs.org/download/release/v19.0.1/node-v19.0.1-headers.tar.gz
gyp http GET https://nodejs.org/download/release/v19.0.1/SHASUMS256.txt
gyp http 500 https://nodejs.org/download/release/v19.0.1/SHASUMS256.txt
gyp WARN install got an error, rolling back install
gyp ERR! configure error 
gyp ERR! stack Error: 500  status code downloading checksum
gyp ERR! stack     at downloadShasums (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:214:15)
gyp ERR! stack     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
gyp ERR! stack     at async Promise.all (index 1)
gyp ERR! stack     at async go (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:189:5)
gyp ERR! stack     at async install (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:62:18)
gyp ERR! System Linux 5.4.0-122-generic
gyp ERR! command "/home/misskey/.nvm/versions/node/v19.0.1/bin/node" "/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/misskey/calckey
gyp ERR! node -v v19.0.1
gyp ERR! node-gyp -v v9.1.0
gyp ERR! not ok 
gyp http GET https://nodejs.org/download/release/v19.0.1/node-v19.0.1-headers.tar.gz
gyp http 200 https://nodejs.org/download/release/v19.0.1/node-v19.0.1-headers.tar.gz
gyp http GET https://nodejs.org/download/release/v19.0.1/SHASUMS256.txt
gyp http 500 https://nodejs.org/download/release/v19.0.1/SHASUMS256.txt
gyp WARN install got an error, rolling back install
gyp ERR! configure error 
gyp ERR! stack Error: 500  status code downloading checksum
gyp ERR! stack     at downloadShasums (/home/misskey/.nvm/versions/node/v19.0.1/lib/node_modules/npm/node_modules/node-gyp/lib/install.js:214:15)
gyp ERR! stack     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
gyp ERR! stack     at async Promise.all (index 1)

Seems to be a checksum error.

ThatOneCalculator avatar Nov 04 '22 20:11 ThatOneCalculator

This seems to happen randomly. It worked for me after ~3-4 tries, unsure of what's wrong and whether it's something specific of node-gyp or something with nodejs.org itself not liking Node.js v19.

jeda avatar Nov 08 '22 21:11 jeda