Gatsby: 'gatsby build' getting stuck with some odd warnings...

Created on 6 Nov 2018  Β·  17Comments  Β·  Source: gatsbyjs/gatsby

Trying to run Gatsby Build and I'm getting this in the terminal:

(sharp:3683): GLib-GObject-WARNING **: 11:45:16.559: cannot register existing type 'VipsObject'

(sharp:3683): GLib-CRITICAL **: 11:45:16.559: g_once_init_leave: assertion 'result != 0' failed

(sharp:3683): GLib-GObject-WARNING **: 11:45:16.559: invalid class cast from 'VipsForeignLoadCsv' to '<invalid>'

β ‚ run graphql queries β€” 8/13 91.84 queries/second

it's getting stuck running queries and won't stop running them, and nothing is building, and it worked fine last night. It just seems stuck this morning.

Any thoughts on what might be happening?

stale? needs reproduction

Most helpful comment

I can see this issue causing some consternation to others, so here's the simple summary

npm up
npm ls sharp

check you don't have any version mismatches with sharp.
does that look like the fix?

All 17 comments

@rchrdnsh can you provide environment info by running gatsby info --clipboard?

here you go :-)

System:
  OS: macOS High Sierra 10.13.6
  CPU: x64 Intel(R) Core(TM) i9-8950HK CPU @ 2.90GHz
  Shell: 3.2.57 - /bin/bash
Binaries:
  Node: 10.12.0 - /usr/local/bin/node
  Yarn: 1.10.1 - /usr/local/bin/yarn
  npm: 6.4.1 - /usr/local/bin/npm
Browsers:
  Chrome: 70.0.3538.77
  Firefox: 63.0
  Safari: 12.0.1
npmPackages:
  gatsby: ^2.0.33 => 2.0.38
  gatsby-cli: ^2.4.4 => 2.4.4
  gatsby-image: ^2.0.19 => 2.0.19
  gatsby-plugin-layout: ^1.0.6 => 1.0.6
  gatsby-plugin-manifest: ^2.0.7 => 2.0.7
  gatsby-plugin-offline: ^2.0.11 => 2.0.11
  gatsby-plugin-react-helmet: ^3.0.1 => 3.0.1
  gatsby-plugin-sharp: ^2.0.11 => 2.0.11
  gatsby-plugin-styled-components: ^3.0.1 => 3.0.1
  gatsby-plugin-transition-link: ^1.0.4 => 1.0.4
  gatsby-source-filesystem: ^2.0.7 => 2.0.7
  gatsby-transformer-remark: ^2.1.11 => 2.1.11
  gatsby-transformer-sharp: ^2.1.7 => 2.1.7
npmGlobalPackages:
  gatsby-cli: 2.4.3

it might be an issue with gatsby-plugin-layout, as it started happening after I added that to my project, but not immediately. It worked at first, but when I came back to it the next day it wasn't working...I' m trying to isolate what makes it happen myself as well.

yeah, I think it's probably an issue with gatsby-plugin-layout...before adding that to my project it builds fine. Then when I add gatsby-plugin-layout it seems to work fine for a few hours, then these errors appear and the queries won't build and the site won't run.

ran an npm audit with these issues:

 === npm audit security report ===

# Run  npm install [email protected]  to resolve 4 vulnerabilities
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Moderate      β”‚ Memory Exposure                                              β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Package       β”‚ tunnel-agent                                                 β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Dependency of β”‚ gatsby-plugin-sharp                                          β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Path          β”‚ gatsby-plugin-sharp > imagemin-mozjpeg > mozjpeg > bin-build β”‚
β”‚               β”‚ > download > caw > tunnel-agent                              β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ More info     β”‚ https://nodesecurity.io/advisories/598                       β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜


β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Moderate      β”‚ Memory Exposure                                              β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Package       β”‚ tunnel-agent                                                 β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Dependency of β”‚ gatsby-plugin-sharp                                          β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Path          β”‚ gatsby-plugin-sharp > imagemin-mozjpeg > mozjpeg >           β”‚
β”‚               β”‚ bin-wrapper > download > caw > tunnel-agent                  β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ More info     β”‚ https://nodesecurity.io/advisories/598                       β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜


β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Moderate      β”‚ Memory Exposure                                              β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Package       β”‚ tunnel-agent                                                 β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Dependency of β”‚ gatsby-plugin-sharp                                          β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Path          β”‚ gatsby-plugin-sharp > imagemin-webp > cwebp-bin > bin-build  β”‚
β”‚               β”‚ > download > caw > tunnel-agent                              β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ More info     β”‚ https://nodesecurity.io/advisories/598                       β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜


β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Moderate      β”‚ Memory Exposure                                              β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Package       β”‚ tunnel-agent                                                 β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Dependency of β”‚ gatsby-plugin-sharp                                          β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Path          β”‚ gatsby-plugin-sharp > imagemin-webp > cwebp-bin >            β”‚
β”‚               β”‚ bin-wrapper > download > caw > tunnel-agent                  β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ More info     β”‚ https://nodesecurity.io/advisories/598                       β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

so I ran npm install [email protected] and then npm audit fix and got these errors both times:

npm WARN deprecated [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
npm ERR! path /Users/rchrdnsh/Dropbox/Code/Gatsby/alma-v5/node_modules/gatsby-plugin-sharp/node_modules/.bin/prebuild-install
npm ERR! code EEXIST
npm ERR! Refusing to delete /Users/rchrdnsh/Dropbox/Code/Gatsby/alma-v5/node_modules/gatsby-plugin-sharp/node_modules/.bin/prebuild-install: is outside /Users/rchrdnsh/Dropbox/Code/Gatsby/alma-v5/node_modules/gatsby-plugin-sharp/node_modules/prebuild-install and not a link
npm ERR! File exists: /Users/rchrdnsh/Dropbox/Code/Gatsby/alma-v5/node_modules/gatsby-plugin-sharp/node_modules/.bin/prebuild-install
npm ERR! Move it away, and try again.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/rchrdnsh/.npm/_logs/2018-11-07T17_29_07_506Z-debug.log

I don't know what's happening here but it seems like there might be an issue with the sharp plugins and packages maybe...and that might be conflicting with gatsby-plugin-layout somehow?

I dunno, but I'm pretty dead in the water at this point :-(

hmmmmm...so I had a crazy idea and I just deleted the entire node_modules folder and then I ran npm install to re-download everything, and now it seems to be working again...I don't know why this would work to fix issues, tho.

Is this something that people do ever?

@rchrdnsh The npm audit issues are unrelated and now fixed

Not sure why you saw this issue. Have you been able to reproduce this again?

Hiya!

This issue has gone quiet. Spooky quiet. πŸ‘»

We get a lot of issues, so we currently close issues after 30 days of inactivity. It’s been at least 20 days since the last update here.

If we missed this issue or if you want to keep it open, please reply here. You can also add the label "not stale" to keep this issue open!

Thanks for being a part of the Gatsby community! πŸ’ͺπŸ’œ

Hey again!

It’s been 30 days since anything happened on this issue, so our friendly neighborhood robot (that’s me!) is going to close it.

Please keep in mind that I’m only a robot, so if I’ve closed this issue in error, I’m HUMAN_EMOTION_SORRY. Please feel free to reopen this issue or create a new one if you need anything else.

Thanks again for being part of the Gatsby community!

well this issue is a pariah on the gatsby system. It happens on and off again for me. It seems like each time I add a separate plugin, it's 50:50 if this issue will re-appear.

On top of that, it's a really hard system crash, bringing down the terminal.
reminds me of nightmare days with RoR and finnicky imagemagick always crashing production servers (shudder)

  System:
    OS: macOS 10.14.6
    CPU: (4) x64 Intel(R) Core(TM) i5-6267U CPU @ 2.90GHz
    Shell: 5.3 - /bin/zsh
  Binaries:
    Node: 10.13.0 - /usr/local/bin/node
    Yarn: 1.17.3 - /usr/local/bin/yarn
    npm: 6.11.2 - /usr/local/bin/npm
  Languages:
    Python: 2.7.10 - /usr/bin/python
  Browsers:
    Chrome: 76.0.3809.132
    Safari: 13.0
  npmPackages:
    gatsby: ^2.8.5 => 2.8.5
    gatsby-image: ^2.2.19 => 2.2.19
    gatsby-plugin-emotion: ^4.0.7 => 4.0.7
    gatsby-plugin-manifest: ^2.1.1 => 2.1.1
    gatsby-plugin-material-ui: ^2.1.6 => 2.1.6
    gatsby-plugin-mdx: ^1.0.43 => 1.0.43
    gatsby-plugin-netlify: ^2.1.2 => 2.1.2
    gatsby-plugin-offline: ^2.1.1 => 2.1.1
    gatsby-plugin-react-helmet: ^3.0.12 => 3.0.12
    gatsby-plugin-sharp: ^2.2.24 => 2.2.24
    gatsby-remark-copy-linked-files: ^2.1.19 => 2.1.19
    gatsby-remark-images: ^3.1.22 => 3.1.22
    gatsby-remark-prismjs: ^3.2.10 => 3.2.10
    gatsby-remark-reading-time: ^1.0.1 => 1.0.1
    gatsby-remark-relative-images: ^0.2.3 => 0.2.3
    gatsby-source-filesystem: ^2.1.22 => 2.1.22
    gatsby-transformer-json: ^2.2.8 => 2.2.8
    gatsby-transformer-remark: ^2.3.12 => 2.3.12
    gatsby-transformer-sharp: ^2.2.15 => 2.2.15
  npmGlobalPackages:
    gatsby-cli: 2.7.47

npm rebuild

npm rebuild to recompile all doesn't seem to fix it but I do notice some conflicting reports:

> [email protected] install /Users/dc/dev/jobby/about/dc.rik.ai/node_modules/sharp
> (node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)

info sharp Using existing vendored libvips v8.7.4

> [email protected] install /Users/dc/dev/jobby/about/dc.rik.ai/node_modules/gatsby-plugin-sharp/node_modules/sharp
> (node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)

info sharp Using existing vendored libvips v8.8.1

> [email protected] install /Users/dc/dev/jobby/about/dc.rik.ai/node_modules/gatsby-transformer-sharp/node_modules/sharp
> (node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)

info sharp Using existing vendored libvips v8.8.1

so it seems my (pretty basic) app is somehow using two versions of sharp?

➜  dc.rik.ai git:(master) βœ— yarn why sharp
yarn why v1.17.3
[1/4] πŸ€”  Why do we have the module "sharp"...?
[2/4] 🚚  Initialising dependency graph...
[3/4] πŸ”  Finding dependency...
[4/4] 🚑  Calculating file sizes...
=> Found "[email protected]"
info Reasons this module exists
   - "gatsby-plugin-sharp" depends on it
   - Hoisted from "gatsby-plugin-sharp#sharp"
   - Hoisted from "gatsby-plugin-manifest#sharp"
   - Hoisted from "gatsby-transformer-sharp#sharp"
info Disk size without dependencies: "34.77MB"
info Disk size with unique dependencies: "35.88MB"
info Disk size with transitive dependencies: "38.1MB"
info Number of shared dependencies: 42
✨  Done in 3.70s.

➜  dc.rik.ai git:(master) βœ— npm ls | grep sharp
npm ERR! missing: [email protected], required by [email protected]
npm ERR! peer dep missing: gatsby@next, required by [email protected]
npm ERR! peer dep missing: react@^16.9.0, required by @mdx-js/[email protected]
npm ERR! extraneous: [email protected] /Users/dc/dev/jobby/about/dc.rik.ai/node_modules/Socket.io
β”‚ └─┬ [email protected]
β”œβ”€β”¬ [email protected]
β”‚ β”œβ”€β”¬ [email protected]
β”œβ”€β”¬ [email protected]
β”‚ └─┬ [email protected]

β”œβ”€β”¬ [email protected]
β”‚ β”œβ”€β”¬ @babel/[email protected]
β”‚ β”‚ └── [email protected] deduped
β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”œβ”€β”¬ [email protected]
β”‚ β”‚ β”œβ”€β”€ [email protected]
β”‚ β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”‚ └── [email protected] deduped
β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”œβ”€β”€ [email protected]
β”‚ └─┬ [email protected]
β”‚   β”œβ”€β”€ [email protected] deduped
β”‚   β”œβ”€β”€ [email protected] deduped
β”‚   β”œβ”€β”€ [email protected] deduped
β”‚   β”œβ”€β”€ [email protected] deduped
β”‚   β”œβ”€β”€ [email protected] deduped
β”‚   β”œβ”€β”€ [email protected]
β”‚   β”œβ”€β”€ [email protected] deduped
β”‚   β”œβ”€β”€ [email protected] deduped
β”‚   └── [email protected] deduped

β”‚ β”œβ”€β”¬ [email protected]
β”‚ β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”‚ β”œβ”€β”€ [email protected]
β”‚ β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ β”‚ └── [email protected] deduped

β”œβ”€β”¬ [email protected]
β”‚ β”œβ”€β”¬ @babel/[email protected]
β”‚ β”‚ └── [email protected] deduped
β”‚ β”œβ”€β”¬ [email protected]


β”œβ”€β”¬ [email protected]
β”‚ β”œβ”€β”€ @babel/[email protected] deduped
β”‚ β”œβ”€β”€ [email protected] deduped
β”‚ └─┬ [email protected]
β”‚   β”œβ”€β”¬ [email protected]
β”‚   β”‚ β”œβ”€β”€ [email protected] deduped
β”‚   β”‚ └─┬ [email protected]
β”‚   β”‚   β”œβ”€β”€ [email protected] deduped


so it seems these various plugins are using different versions of sharp which causes the whole build system to hang.

after doing npm up it seems things are more aligned

➜  dc.rik.ai git:(master) βœ— npm ls sharp
[email protected] /Users/dc/dev/jobby/about/dc.rik.ai
β”œβ”€β”¬ [email protected]
β”‚ └── [email protected]
β”œβ”€β”¬ [email protected]
β”‚ └── [email protected]  deduped
└─┬ [email protected]
  └── [email protected]  deduped

I can see this issue causing some consternation to others, so here's the simple summary

npm up
npm ls sharp

check you don't have any version mismatches with sharp.
does that look like the fix?

@dcsan Thank you very much this fixed it for me.

@dcsan this did it. Thanks man.

this helped me: update this dependency used sharp
npm i [email protected]

Was this page helpful?
0 / 5 - 0 ratings

Related issues

dustinhorton picture dustinhorton  Β·  3Comments

signalwerk picture signalwerk  Β·  3Comments

brandonmp picture brandonmp  Β·  3Comments

3CordGuy picture 3CordGuy  Β·  3Comments

Oppenheimer1 picture Oppenheimer1  Β·  3Comments