Unable to use / rebuild / install sharp because of python from anaconda3
See original GitHub issueHere’s the logs
npm WARN rm not removing /Users/leoribeiro/Workspace/project/node_modules/.bin/jest as it wasn't installed by /Users/leoribeiro/Workspace/project/node_modules/jest
> fsevents@1.1.3 install /Users/leoribeiro/Workspace/project/node_modules/fsevents
> node install
[fsevents] Success: "/Users/leoribeiro/Workspace/project/node_modules/fsevents/lib/binding/Release/node-v59-darwin-x64/fse.node" is installed via remote
> sharp@0.20.1 install /Users/leoribeiro/Workspace/project/node_modules/sharp
> (node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)
info sharp Detected globally-installed libvips v8.6.3
info sharp Building from source via node-gyp
gyp ERR! configure error
gyp ERR! stack Error: Python executable "/usr/local/anaconda3/bin/python" is v3.6.4, 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:492:19)
gyp ERR! stack at PythonFinder.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:474:14)
gyp ERR! stack at ChildProcess.exithandler (child_process.js:265:7)
gyp ERR! stack at ChildProcess.emit (events.js:180:13)
gyp ERR! stack at maybeClose (internal/child_process.js:936:16)
gyp ERR! stack at Socket.stream.socket.on (internal/child_process.js:353:11)
gyp ERR! stack at Socket.emit (events.js:180:13)
gyp ERR! stack at Pipe._handle.close [as _onclose] (net.js:541:12)
gyp ERR! System Darwin 17.5.0
gyp ERR! command "/usr/local/Cellar/node/9.10.1/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/leoribeiro/Workspace/project/node_modules/sharp
gyp ERR! node -v v9.10.1
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN image_processing@1.0.0 No description
npm WARN image_processing@1.0.0 No repository field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sharp@0.20.1 install: `(node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the sharp@0.20.1 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! /Users/leoribeiro/.npm/_logs/2018-04-06T00_26_55_233Z-debug.log
Can someone give me a hand?
Thanks!
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
After `npm install` an error about a syntax error in python ...
Try this in cmd administrator (or Windows Powershell Administrator if cmd freezes). npm install --global windows-build-tools.
Read more >Troubleshooting — Anaconda documentation
Solution. Open the Anaconda or Miniconda installation folder and run the .exe file uninstaller from that location. Uninstallation will complete without ...
Read more >build failed: error: can't find python, please install ... - You.com
Try: Install all the required tools and configurations using Microsoft's windows-build-tools by running npm install -g windows-build-tools from an elevated ...
Read more >EMAN2/Install/BinaryInstallAnaconda/2.31 - EMAN Wiki
The first thing to check is whether you have PYTHONPATH, PYTHONHOME, LD_LIBRARY_PATH or DYLD_LIBRARY_PATH set in your shell. While used in ...
Read more >Managing Python — conda 22.11.1.post17+e3a05b6f5 ...
Installing a different version of Python · Create the new environment: · Activate the new environment. · Verify that the new environment is...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Sorry the delay. @lovell I’ve just removed the libvips and used the built-in
libvips
from sharp. It worked fine! Thanks for the help! You can close this issue.@codingleo where did you remove
libvips
from?