I’m using meteor 2.15
with node 14.21.3
and npm 6.14.18
and I’m getting an error if I run the npm run start
(which is meteor --exclude-archs web.browser.legacy,web.cordova --settings settings.json --port 3000)
/.meteor/packages/meteor-tool/.3.0.3.18tkqmf.vte9++os.osx.arm64+web.browser+web.browser.legacy+web.cordova/mt-os.osx.arm64/tools/cli/main.js:458
throw Error("missing tool for " + archinfo.host() + " in " + toolsPkg + "@" + toolsVersion);
^
Error: missing tool for os.osx.x86_64 in meteor-tool@2.15.0
at springboard (/tools/cli/main.js:498:11)
at /tools/cli/main.js:1161:7
Node.js v20.17.0
You can see npm command is running node v20 instead of node v14. The problem started after the npm update. I reverted everything. Uninstalled nvm and installed node 14.21.3
and npm 6.14.18
manually. Now only running node 14.21.3
and npm 6.14.18
and v20 is not installed.
While running meteor --exclude-archs web.browser.legacy,web.cordova --settings settings.json --port 3000
directly (the command in npm run start) from CLI, everything works as expected.
The same npm
command is working fine on Meteor.js version 3.
I think it’s not directly related to Meteor.js but I couldn’t find a solution. Is there anyone who encountered similar problem.
Debug log is:
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli '/Users/<username>/.nvm/versions/node/v14.21.3/bin/node',
1 verbose cli '/Users/<username>/.nvm/versions/node/v14.21.3/bin/npm',
1 verbose cli 'run',
1 verbose cli 'start'
1 verbose cli ]
2 info using npm@6.14.18
3 info using node@v14.21.3
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle <projectname>@~prestart: <projectname>@
6 info lifecycle <projectname>@~start: <projectname>@
7 verbose lifecycle <projectname>@~start: unsafe-perm in lifecycle true
8 verbose lifecycle <projectname>@~start: PATH: /Users/<username>/.nvm/versions/node/v14.21.3/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/<username>/Dev/<projectname>/node_modules/.bin:/Users/<username>/$
9 verbose lifecycle <projectname>@~start: CWD: /Users/<username>/Dev/<projectname>
10 silly lifecycle <projectname>@~start: Args: [
10 silly lifecycle '-c',
10 silly lifecycle 'meteor --settings settings.json --port 3000'
10 silly lifecycle ]
11 silly lifecycle <projectname>@~start: Returned: code: 1 signal: null
12 info lifecycle <projectname>@~start: Failed to exec start script
13 verbose stack Error: <projectname>@ start: `meteor --settings settings.json --port 3000`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (/Users/<username>/.nvm/versions/node/v14.21.3/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
13 verbose stack at EventEmitter.emit (events.js:400:28)
13 verbose stack at ChildProcess.<anonymous> (/Users/<username>/.nvm/versions/node/v14.21.3/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:400:28)
13 verbose stack at maybeClose (internal/child_process.js:1088:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:296:5)
14 verbose pkgid <projectname>@
15 verbose cwd /Users/<username>/Dev/<projectname>
16 verbose Darwin 23.5.0
17 verbose argv "/Users/<username>/.nvm/versions/node/v14.21.3/bin/node" "/Users/<username>/.nvm/versions/node/v14.21.3/bin/npm" "run" "start"
18 verbose node v14.21.3
19 verbose npm v6.14.18
20 error code ELIFECYCLE
21 error errno 1
22 error <projectname>@ start: `meteor --settings settings.json --port 3000`
22 error Exit status 1
23 error Failed at the <projectname>@ start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]