I am trying to update the particle-cli to version 1.35.1, as I have been instructed (by the cli). However, using the command npm install -g particle-cli
, the update fails due using the wrong python version…? The trace is:
prebuild-install WARN install No prebuilt binaries found (target=10.8.0 runtime=node arch=x64 platform=darwin)
gyp ERR! configure error
gyp ERR! stack Error: Python executable "/Users/davidhagan/.pyenv/shims/python" is v3.6.5, which is not supported by gyp.
gyp ERR! stack You can pass the --python switch to point to Python >= v2.5.0 & < 3.0.0.
gyp ERR! stack at PythonFinder.failPythonVersion (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:501:19)
gyp ERR! stack at PythonFinder.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:483:14)
gyp ERR! stack at ChildProcess.exithandler (child_process.js:279:7)
gyp ERR! stack at ChildProcess.emit (events.js:182:13)
gyp ERR! stack at maybeClose (internal/child_process.js:962:16)
gyp ERR! stack at Socket.stream.socket.on (internal/child_process.js:381:11)
gyp ERR! stack at Socket.emit (events.js:182:13)
gyp ERR! stack at Pipe._handle.close (net.js:599:12)
gyp ERR! System Darwin 17.7.0
gyp ERR! command "/usr/local/Cellar/node/10.8.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/particle-cli/node_modules/serialport
gyp ERR! node -v v10.8.0
gyp ERR! node-gyp -v v3.7.0
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! serialport@6.2.0 install: `prebuild-install || node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the serialport@6.2.0 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Currently have installed:
- node v10.8.0
- npm v6.3.0
- python v3.6.5
Are there any restrictions on which versions can be used to build the CLI? I didn’t see any listed in the “known issues” section of the readme…