gatsby: Unexpected Rendering Engines validation failure (Gatsby v4)
Preliminary Checks
- This issue is not a duplicate. Before opening a new issue, please search existing issues: https://github.com/gatsbyjs/gatsby/issues
- This issue is not a question, feature request, RFC, or anything other than a bug report directly related to Gatsby. Please post those things in GitHub Discussions: https://github.com/gatsbyjs/gatsby/discussions
Description
After migrating to Gatsby v4, build fails with:
failed Validating Rendering Engines - 0.641s
ERROR #98001 WEBPACK
Built Rendering Engines failed validation failed validation.
Please open an issue with a reproduction at https://github.com/gatsbyjs/gatsby/issues/new for more help
Error: Generated engines use disallowed import "babel-runtime/helpers/asyncToGenerator". Only allowed imports are to Node.js builtin modules or engines internals.
I don’t know Gatsby’s internals but it looks like that import is intentional and coming from Gatsby itself: https://github.com/gatsbyjs/gatsby/pull/33030/files#diff-53a98e8932749e1788143dca477bd89b34e3f53d2db77569afac21ddede8f8a4R36
Is that an indication of a bug in Gatsby?
Reproduction Link
https://github.com/gkossakowski/gkossakowski.github.io/tree/gatsby-v4
Steps to Reproduce
- Checkout the repo
- Run
gatsby build
Expected Result
Builds successfully.
Actual Result
Error: Generated engines use disallowed import “babel-runtime/helpers/asyncToGenerator”. Only allowed imports are to Node.js builtin modules or engines internals.
Environment
System:
OS: macOS 12.1
CPU: (10) arm64 Apple M1 Pro
Shell: 5.8 - /bin/zsh
Binaries:
Node: 17.2.0 - /opt/homebrew/bin/node
Yarn: 3.1.1 - /opt/homebrew/bin/yarn
npm: 8.1.4 - /opt/homebrew/bin/npm
Languages:
Python: 3.7.6 - /Users/grek/opt/miniconda3/bin/python
Browsers:
Chrome: 96.0.4664.110
Safari: 15.2
npmPackages:
gatsby: ^4.4.0 => 4.4.0
gatsby-cli: ^4.4.0 => 4.4.0
gatsby-link: ^4.4.0 => 4.4.0
gatsby-plugin-catch-links: ^4.4.0 => 4.4.0
gatsby-plugin-feed: ^4.4.0 => 4.4.0
gatsby-plugin-flow: ^3.4.0 => 3.4.0
gatsby-plugin-google-gtag: ^4.4.0 => 4.4.0
gatsby-plugin-manifest: ^4.4.0 => 4.4.0
gatsby-plugin-netlify: next => 4.0.0-next.0
gatsby-plugin-netlify-cms: ^6.4.0 => 6.4.0
gatsby-plugin-netlify-cms-paths: ^1.3.0 => 1.3.0
gatsby-plugin-offline: ^5.4.0 => 5.4.0
gatsby-plugin-optimize-svgs: ^1.0.5 => 1.0.5
gatsby-plugin-react-helmet: ^5.4.0 => 5.4.0
gatsby-plugin-sass: ^5.4.0 => 5.4.0
gatsby-plugin-sharp: ^4.4.0 => 4.4.0
gatsby-plugin-sitemap: ^5.4.0 => 5.4.0
gatsby-remark-autolink-headers: ^5.4.0 => 5.4.0
gatsby-remark-copy-linked-files: ^5.4.0 => 5.4.0
gatsby-remark-external-links: 0.0.4 => 0.0.4
gatsby-remark-images: ^6.4.0 => 6.4.0
gatsby-remark-katex: ^6.4.0 => 6.4.0
gatsby-remark-prismjs: ^6.4.0 => 6.4.0
gatsby-remark-relative-images: ^2.0.2 => 2.0.2
gatsby-remark-responsive-iframe: ^5.4.0 => 5.4.0
gatsby-remark-smartypants: ^5.4.0 => 5.4.0
gatsby-source-filesystem: ^4.4.0 => 4.4.0
gatsby-transformer-remark: ^5.4.0 => 5.4.0
gatsby-transformer-sharp: ^4.4.0 => 4.4.0
Config Flags
No response
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 15 (5 by maintainers)
I’m trying to use the Deferred Static Generation (DSG) on some templates, but as soon as I add
defer: trueoncreatePage, I get a very similar error. Node16.13.0Not exactly sure what’s going on or if it’s somehow related to the original issue. Happy to provide more context!