Here'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
> [email protected] 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
> [email protected] 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 [email protected] No description
npm WARN [email protected] No repository field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] 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 [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! /Users/leoribeiro/.npm/_logs/2018-04-06T00_26_55_233Z-debug.log
Can someone give me a hand?
Thanks!
Hello, the salient part of this relatively descriptive message is:
info sharp Detected globally-installed libvips v8.6.3
info sharp Building from source via node-gyp
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.
Because a globally-installed version of libvips was found, sharp will compile itself from source to correctly link against that global version. The prerequisites to do this are listed at http://sharp.pixelplumbing.com/en/stable/install/#prerequisites and include node-gyp and therefore Python 2.7.
lovell, I am also bumping into the same issues when trying to install this module.
I've been trying to install it for several days on and off....
Getting the following error output:
`
gyp ERR! build error
gyp ERR! stack Error: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Users\user\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node_modules\node-gyp\lib\build.js:258:23)
gyp ERR! stack at ChildProcess.emit (events.js:160:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:12)
gyp ERR! System Windows_NT 10.0.16299
gyp ERR! command "C:\dev\nodejs\node.exe" "C:\Users\user\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node_modules\node-gyp\bin\node-gyp.js" "rebuild"
gyp ERR! cwd C:dev\byond\image-resizer\node_modules\sharp
gyp ERR! node -v v9.4.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN rollback Rolling back [email protected] failed (this is probably harmless): EPERM: operation not permitted, rmdir 'C:dev\byond\image-resizer\node_modules\fsevents\node_modules'
npm WARN rollback Rolling back [email protected] failed (this is probably harmless): EPERM: operation not permitted, rmdir 'C:dev\byond\image-resizer\node_modules\fsevents\node_modules'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: node-gyp rebuild
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! C:\Users\user\AppData\Roaming\npm-cache_logs\2018-04-15T12_02_17_605Z-debug.log`
I would be very grateful for your guidance as I am very interested in this module.
@byondrnd This issue is about Python 3 but your problem does not relate to it. Your problem does however mention sharp v0.11.4, which is almost three years old. Please try with the latest v0.20.1 and create a new issue if there are still problems.
@leodsgn Were you able to make any progress with this?
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?
Most helpful comment
Sorry the delay. @lovell I've just removed the libvips and used the built-in
libvipsfrom sharp. It worked fine! Thanks for the help! You can close this issue.