VipsJpeg: Not a JPEG file: starts with 0xff 0xd9


I have some build issues on my project, the stack is:

  • Contentful
  • Gatsby
  • Netlify

I tried different scenarios running this until it works locally.

gatsby clean
gatsby build

My isses are when I want to deploy on Netlify

VipsJpeg: Not a JPEG file: starts with 0xff 0xd9

I deleted / upload to contentful the jpeg files but I still have the error.

Do you have an idea on how I can fix it?

hmm, i did a google for “Not a JPEG file: starts with 0xff 0xd9” and it does seem like this an uncommon but not unheard of error.

I am going to guess you don’t have this issue locally as we take some extra steps when deploying that don’t apply to a local build.

As this seems to be primarily a Gatsby issue, you might reach out to the gatsby community and see if they have some ideas for you?

Thanks @perry
You are right, It’s working locally.
That’s why I wrote the issue here because it’s related to the build on Netlify, :sweat_smile:

I found this as a non-blocking solution
remove GatsbyContentfulFluid_tracedSVG and use GatsbyContentfulFluid

1 Like