sharp: Command failed
See original GitHub issueDescription
env
- win7 64
- node@10.15.x
- npm@6.4.1
- yarn@1.15.1
- python@3.7.x
Steps to reproduce
- gridsome create my-gridsome-site. error report:
Error: Failed to install dependencies with yarn Please enter my-gridsome-site directory and install dependencies with yarn or npm manually.
Exit code 1
at ChildProcess.child.on.code...
...
- cd my-gridsome-site
- yarn install. error report:
error E:\my-gridsome-site\node_modules\sharp: Command failed.
Command: (node install/libvips && node install/dll-copy && prebuild-install) ||
(node-gyp rebuild && node install/dll-copy)
...
why?
Issue Analytics
- State:
- Created 4 years ago
- Reactions:14
- Comments:63 (5 by maintainers)
Top Results From Across the Web
Fail to install gatsby starter because of sharp - Stack Overflow
16.0 solved the problem for me) using nvm(to manage different node versions). commands for nvm are: a) "nvm install 10.16.0" (to install node ......
Read more >Sharp error mac m1 - nvh95 Handbook
When running command yarn to install dependencies for a Gatsby project on Mac M1, I encounter this error with sharp:
Read more >sharp - npm
High performance Node.js image processing, the fastest module to resize JPEG, PNG, WebP, GIF, AVIF and TIFF images. Latest version: 0.31.3, ...
Read more >Build error: Can't build node_modules/sharp - Support
12:54:39 PM: npm ERR! path /opt/build/repo/node_modules/sharp 12:54:39 PM: npm ERR! command failed 12:54:39 PM: npm ERR! command sh -c node-gyp rebuild
Read more >一站式解决Node项目中遇到的诸如sharp Command failed.或 ...
error /mnt/e/One life projects/OneLifeAdmin/node_modules/favicons/node_modules/sharp: Command failed. Exit code: 1 Command: (node install/ ...
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
So after some digging/searching and trying these steps solved it for me:
rm -rf /Users/{username}/.npm/_libvips
brew install vips
// If this command throws some error about could not download cfitsio, just ignore.rm -rf node_modules
npm install
Summary of mentions as above (it doesn’t work for me at all)
$ rm -rf /Users/{username}/.npm/_libvips
$ brew install vips
You should try downgrade node to stable version
https://www.hostingadvice.com/how-to/update-node-js-latest-version/