node npm install --production, dependency error - benchpressjs files are missing
-
Again i have installation problem, this time i cant (don't have time right now) reinstall OS to check if it is OS problem.
Each time installation stops on benchpressjs.
2345 warn optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.1.2 (node_modules/chokidar/node_modules/fsevents): 2346 warn notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"}) 2347 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Valid OS: darwin 2347 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Valid Arch: any 2347 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Actual OS: linux 2347 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Actual Arch: x64 2348 warn [email protected] requires a peer of nodebb-plugin-emoji@^2.0.0 but none is installed. You must install peer dependencies yourself. 2349 warn [email protected] requires a peer of textcomplete@^0.14.2 but none is installed. You must install peer dependencies yourself. 2350 warn [email protected] requires a peer of eslint@^5.16.0 || ^6.8.0 but none is installed. You must install peer dependencies yourself. 2351 verbose stack Error: [email protected] install: `cd rust/benchpress-rs && npm install` 2351 verbose stack Exit status 1 2351 verbose stack at EventEmitter.<anonymous> (/home/user/.nvm/versions/node/v10.22.1/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16) 2351 verbose stack at EventEmitter.emit (events.js:198:13) 2351 verbose stack at ChildProcess.<anonymous> (/home/user/.nvm/versions/node/v10.22.1/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14) 2351 verbose stack at ChildProcess.emit (events.js:198:13) 2351 verbose stack at maybeClose (internal/child_process.js:982:16) 2351 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5) 2352 verbose pkgid [email protected] 2353 verbose cwd /home/user/webapps/nodebb 2354 verbose Linux 4.4.217 2355 verbose argv "/home/user/.nvm/versions/node/v10.22.1/bin/node" "/home/user/.nvm/versions/node/v10.22.1/bin/npm" "install" "--production" 2356 verbose node v10.22.1 2357 verbose npm v6.14.8 2358 error code ELIFECYCLE 2359 error errno 1 2360 error [email protected] install: `cd rust/benchpress-rs && npm install` 2360 error Exit status 1 2361 error Failed at the [email protected] install script. 2361 error This is probably not a problem with npm. There is likely additional logging output above. 2362 verbose exit [ 1, true ]
Benchpressjs directory and files are not created.
namei -l /home/user/webapps/nodebb/node_modules/benchpressjs/rust/
f: /home/user/webapps/nodebb/node_modules/benchpressjs/rust/
drwxr-xr-x root root /
drwxr-xr-x root root home
drwxr-x--- user nginx user
drwxr-x--- user nginx webapps
drwxr-x--- user nginx nodebb
drwxr-xr-x user users node_modules
benchpressjs - No such file or directory
So from this log i see that command
node npm install --production
cant install benchpressjs. So what I can do more to try to install benchpressjs?I also tried removing node_modules, reinstalling by hand, downgrading but the saem error presist.
/home/user/.nvm/versions/node/v10.22.1/bin/node /home/user/.nvm/versions/node/v10.22.1/bin/npm install -g [email protected]
/home/user/.nvm/versions/node/v10.22.1/bin/node /home/user/.nvm/versions/node/v10.22.1/bin/npm install -g npm
/home/user/.nvm/versions/node/v10.22.1/bin/node /home/user/.nvm/versions/node/v10.22.1/bin/npm cache clean --force
/home/user/.nvm/versions/node/v10.22.1/bin/node /home/user/.nvm/versions/node/v10.22.1/bin/npm install --production
Below error is from reinstalling by hand
npm install --production
.> [email protected] install /home/user/webapps/nodebb/node_modules/benchpressjs > cd rust/benchpress-rs && npm install > [email protected] install /home/user/webapps/nodebb/node_modules/benchpressjs/rust/benchpress-rs > node scripts/install internal/modules/cjs/loader.js:638 throw err; ^ Error: Cannot find module '/home/user/webapps/nodebb/node_modules/benchpressjs/rust/benchpress-rs/scripts/install' at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15) at Function.Module._load (internal/modules/cjs/loader.js:562:25) at Function.Module.runMain (internal/modules/cjs/loader.js:831:12) at startup (internal/bootstrap/node.js:283:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! [email protected] install: `node scripts/install` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the [email protected] install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /home/user/.npm/_logs/2020-10-10T12_55_17_601Z-debug.log npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.1.2 (node_modules/chokidar/node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"}) npm WARN [email protected] requires a peer of eslint@^5.16.0 || ^6.8.0 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of canvas@^2.5.0 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of nodebb-plugin-emoji@^2.0.0 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of pg-native@>=2.0.0 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of textcomplete@^0.14.2 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of bufferutil@^4.0.1 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of utf-8-validate@^5.0.2 but none is installed. You must install peer dependencies yourself. npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! [email protected] install: `cd rust/benchpress-rs && npm install` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the [email protected] install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /home/user/.npm/_logs/2020-10-10T12_55_18_902Z-debug.log
and this is
./nodebb upgrade
errorUpdating NodeBB... 1. Updating package.json file with defaults... OK 2. Bringing base dependencies up to date... started > [email protected] install /home/user/webapps/nodebb/node_modules/benchpressjs > cd rust/benchpress-rs && npm install > [email protected] install /home/user/webapps/nodebb/node_modules/benchpressjs/rust/benchpress-rs > node scripts/install internal/modules/cjs/loader.js:638 throw err; ^ Error: Cannot find module '/home/user/webapps/nodebb/node_modules/benchpressjs/rust/benchpress-rs/scripts/install' at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15) at Function.Module._load (internal/modules/cjs/loader.js:562:25) at Function.Module.runMain (internal/modules/cjs/loader.js:831:12) at startup (internal/bootstrap/node.js:283:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! [email protected] install: `node scripts/install` np ```m ERR! Exit status 1 npm ERR! npm ERR! Failed at the [email protected] install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /home/user/.npm/_logs/2020-10-10T13_42_11_480Z-debug.log npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.1.2 (node_modules/chokidar/node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"}) npm WARN [email protected] requires a peer of eslint@^5.16.0 || ^6.8.0 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of canvas@^2.5.0 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of nodebb-plugin-emoji@^2.0.0 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of pg-native@>=2.0.0 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of textcomplete@^0.14.2 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of bufferutil@^4.0.1 but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of utf-8-validate@^5.0.2 but none is installed. You must install peer dependencies yourself. npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! [email protected] install: `cd rust/benchpress-rs && npm install` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the [email protected] install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /home/user/.npm/_logs/2020-10-10T13_42_12_963Z-debug.log Error installing dependencies! message: Command failed: npm install --production stdout: null stderr: null 2020-10-10T13:42:12.999Z [/home/user/webapps/nodebb1.sock,/home/user/webapps/nodebb2.sock,/home/user/webapps/nodebb3.sock/28413] - error: uncaughtException: Command failed: npm install --production Error: Command failed: npm install --production at checkExecSyncError (child_process.js:629:11) at Object.execSync (child_process.js:666:13) at Object.installAll (/home/user/webapps/nodebb/src/cli/package-install.js:63:9) at Object.handler (/home/user/webapps/nodebb/src/cli/upgrade.js:26:19) at /home/user/webapps/nodebb/src/cli/upgrade.js:59:22 at eachfn (/home/user/webapps/nodebb/node_modules/async/dist/async.js:2948:28) at replenish (/home/user/webapps/nodebb/node_modules/async/dist/async.js:440:21) at /home/user/webapps/nodebb/node_modules/async/dist/async.js:445:13 at eachOfLimit$1 (/home/user/webapps/nodebb/node_modules/async/dist/async.js:471:34) at awaitable (/home/user/webapps/nodebb/node_modules/async/dist/async.js:208:32) {"error":{"status":1,"signal":null,"output":[null,null,null],"pid":28421,"stdout":null,"stderr":null},"stack":"Error: Command failed: npm install --production\n at checkExecSyncError (child_process.js:629:11)\n at Object.execSync (child_process.js:666:13)\n at Object.installAll (/home/user/webapps/nodebb/src/cli/package-install.js:63:9)\n at Object.handler (/home/user/webapps/nodebb/src/cli/upgrade.js:26:19)\n at /home/user/webapps/nodebb/src/cli/upgrade.js:59:22\n at eachfn (/home/user/webapps/nodebb/node_modules/async/dist/async.js:2948:28)\n at replenish (/home/user/webapps/nodebb/node_modules/async/dist/async.js:440:21)\n at /home/user/webapps/nodebb/node_modules/async/dist/async.js:445:13\n at eachOfLimit$1 (/home/user/webapps/nodebb/node_modules/async/dist/async.js:471:34)\n at awaitable (/home/user/webapps/nodebb/node_modules/async/dist/async.js:208:32)","exception":true,"date":"Sat Oct 10 2020 15:42:12 GMT+0200 (Central European Summer Time)","process":{"pid":28413,"uid":1003,"gid":100,"cwd":"/home/user/webapps/nodebb","execPath":"/home/user/.nvm/versions/node/v10.22.1/bin/node","version":"v10.22.1","argv":["/home/user/.nvm/versions/node/v10.22.1/bin/node","/home/user/webapps/nodebb/nodebb","upgrade"],"memoryUsage":{"rss":63262720,"heapTotal":40153088,"heapUsed":23417904,"external":167911}},"os":{"loadavg":[0.23974609375,0.05908203125,0.01611328125],"uptime":13654},"trace":[{"column":11,"file":"child_process.js","function":"checkExecSyncError","line":629,"method":null,"native":false},{"column":13,"file":"child_process.js","function":"Object.execSync","line":666,"method":"execSync","native":false},{"column":9,"file":"/home/user/webapps/nodebb/src/cli/package-install.js","function":"Object.installAll","line":63,"method":"installAll","native":false},{"column":19,"file":"/home/user/webapps/nodebb/src/cli/upgrade.js","function":"Object.handler","line":26,"method":"handler","native":false},{"column":22,"file":"/home/user/webapps/nodebb/src/cli/upgrade.js","function":null,"line":59,"method":null,"native":false},{"column":28,"file":"/home/user/webapps/nodebb/node_modules/async/dist/async.js","function":"eachfn","line":2948,"method":null,"native":false},{"column":21,"file":"/home/user/webapps/nodebb/node_modules/async/dist/async.js","function":"replenish","line":440,"method":null,"native":false},{"column":13,"file":"/home/user/webapps/nodebb/node_modules/async/dist/async.js","function":null,"line":445,"method":null,"native":false},{"column":34,"file":"/home/user/webapps/nodebb/node_modules/async/dist/async.js","function":"eachOfLimit$1","line":471,"method":null,"native":false},{"column":32,"file":"/home/user/webapps/nodebb/node_modules/async/dist/async.js","function":"awaitable","line":208,"method":null,"native":false}]}
-
I just did copy benchpressjs from old NodeBB installation and there are no errors, but forum is broken (only NodeBB text and login and register links are visible rest of the page is blank).
Just used all my ideas, i will wait with reinstalling OS, because if i get this error in the future in production it will be pain to reinstall OS.
-
Hey I think I know what's causing this, and I'll fix it soon. For now, do
npm install [email protected]
to use an older version. -
I think i found another bug.
Just checked old NodeBB installations 5-10 days old and they had benchpressjs 2.0.4 version.
Right now there is new benchpressjs 2.0.6 version that is impossible for me to build/install NodeBB.
I could build/install NodeBB with benchpressjs 2.0.4, unfortunately forum behaves weirdly but Im still testing.
@PitaJ ok thanks, i had open replay box couldn't see your answer faster.
Yes its working before
./nodebb setup
i installednpm install [email protected]
i was wondering how to do it thx for the tip. -
This should be fixed in [email protected]