Upgraded gatsby-source-contentful from 2.3.56 to 3.1.0. Previously worked, now fails with the following output:
gatsby develop:
success open and validate gatsby-configs - 0.044s
success load plugins - 1.459s
success onPreInit - 0.040s
success initialize cache - 0.005s
success copy gatsby files - 0.044s
success onPreBootstrap - 0.017s
success createSchemaCustomization - 0.004s
error Accessing your Contentful space failed.
Try setting GATSBY_CONTENTFUL_OFFLINE=true to see if we can serve from cache.
Used options:
spaceId: "*********agp"
accessToken: "***************************************K0Cw"
downloadLocal: false
host: "cdn.contentful.com"
environment: "master"
localeFilter: true
forceFullSync: false
pageLimit: 100
assetDownloadWorkers: 50
useNameForId: true
richText: {}
not finished source and transform nodes - 0.239s
not finished Contentful: Fetch data (n1x5yig4pagp-master) - 0.138s
gatsby build (at Netlify):
3:26:44 PM: error Accessing your Contentful space failed.
3:26:44 PM: Try setting GATSBY_CONTENTFUL_OFFLINE=true to see if we can serve from cache.
3:26:44 PM: Used options:
3:26:44 PM: spaceId: "*********agp"
3:26:44 PM: accessToken: "***************************************K0Cw"
3:26:44 PM: downloadLocal: true
3:26:44 PM: host: "cdn.contentful.com"
3:26:44 PM: environment: "master"
3:26:44 PM: localeFilter: true
3:26:44 PM: forceFullSync: false
3:26:44 PM: pageLimit: 100
3:26:44 PM: assetDownloadWorkers: 50
3:26:44 PM: useNameForId: true
3:26:44 PM: richText: {}
3:26:44 PM: not finished source and transform nodes - 0.344s
3:26:44 PM: not finished Contentful: Fetch data (n1x5yig4pagp-master) - 0.145s
I've had a look at the release notes for 3.x.x and there doesn't seem to be anything out of the ordinary.
I also saw https://github.com/gatsbyjs/gatsby/issues/27484 which looks similar, but since my previous working version of gatsby-source-contentful was higher than the one mentioned in that issue, I figured I'd open a new issue.
System:
OS: macOS 10.15.7
CPU: (8) x64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz
Shell: 5.8 - /usr/local/bin/zsh
Binaries:
Node: 14.15.0 - ~/.nvm/versions/node/v14.15.0/bin/node
npm: 6.14.8 - ~/.nvm/versions/node/v14.15.0/bin/npm
Languages:
Python: 2.7.16 - /usr/bin/python
Browsers:
Chrome: 86.0.4240.111
Firefox: 81.0.2
Safari: 14.0
npmPackages:
gatsby: 2.25.0 => 2.25.0
gatsby-image: 2.4.21 => 2.4.21
gatsby-plugin-google-analytics: 2.4.0 => 2.4.0
gatsby-plugin-manifest: 2.5.0 => 2.5.0
gatsby-plugin-offline: 3.3.0 => 3.3.0
gatsby-plugin-react-helmet: 3.3.14 => 3.3.14
gatsby-plugin-robots-txt: 1.5.3 => 1.5.3
gatsby-plugin-sharp: 2.7.0 => 2.7.0
gatsby-plugin-sitemap: 2.5.0 => 2.5.0
gatsby-plugin-styled-components: 3.3.14 => 3.3.14
gatsby-plugin-svgr: 2.0.2 => 2.0.2
gatsby-plugin-webpack-bundle-analyzer: 1.0.5 => 1.0.5
gatsby-source-contentful: 3.1.0 => 3.1.0
gatsby-source-filesystem: 2.4.0 => 2.4.0
gatsby-transformer-sharp: 2.5.21 => 2.5.21
I got the same problem, trying to find what causing it but haven't found anything yet.
Please try reverting to 3.0.0 and let us know if the problem persists.
Does it work with npm install gatsby-source-contentful@~3.0.0 ?
Same over here....
Please try reverting to
3.0.0and let us know if the problem persists.
Does it work with
npm install gatsby-source-contentful@~3.0.0?
Yes - just tried. Both gatsby develop and gatsby build seem fine on v3.0.0.
Thanks for the quick response, I can pin the dependency for now!
It would help tremendously if you could quickly bisect to find the last version to which this worked. Sice v3.1.0 failed, and v3.0.0 works, there are 7 releases in between (v3.0.1 ~ v3.0.7). Can you please do a quick check what the last version was where this still worked? Thanks!
(you can explicitly install a version by npm install [email protected] or yarn add [email protected], repeat for all. No further changes necessary.)
It worked on 3.0.7 so the changes in 3.1.0 is the reason for breaking.
It worked on
3.0.7so the changes in3.1.0is the reason for breaking.
Yep, same for me. Thanks for picking this up!
Thanks for figuring it out! :D
This fix was published in [email protected]
Please skip 3.1.0 :)
Most helpful comment
This fix was published in [email protected]
Please skip 3.1.0 :)