Image downloading but not accessible — also bug depending on url. #11
Description
Having some difficulty with images and this plugin — there are two main issues I am facing.
Context:
I am using CraftCMS and the ElementAPI to generate a JSON API to use with this plugin.
First bug/issue:
url passed to createRemoteFileNode is either missing or not a proper web uri:
Even though my uri's being passed from craft are like so: /assets/images/L1000642ACR.jpg
— it fails to detect/download the image, this appears to match what is in the docs.
To test some things out I appended the site URL to the API so it gave the full URL of the image — this allowed 2 out of 3 test images to download but the third still failed, I can only assume it's something to do with the filename of the image which is quite long and has differing characters within it:
url passed to createRemoteFileNode is either missing or not a proper web uri: http://livvy-cms.test/assets/images/home/Different-Interruptions-of-Dust-41x28cm-photogravure-print-etchin
g-paper-gold-ink-2016-of-the-1979-eruption-of-the-Soufrière-Volcano.jpg
Image downloaded: Post-Card-Image.jpg
Image downloaded: Different-Interruptions.jpg
This isn't ideal for production as the client could upload any image with any filename.
Edit: This is definitely because of the french character è in the filename, not sure how to resolve as of yet.
Second bug/issue
Taking the partial success of the two images that did download — I went into Graphql to see if it had worked. The images downloaded to Gatsby's cache which I assume is correct, but in GraphQL I have no access to:
childImageSharp {
fluid(maxWidth: 2000) {
...GatsbyImageSharpFluid_withWebp
}
}
on the local node — any ideas/suggestions would be great.