Replies: 2 comments 4 replies
-
Try deleting your lock file and reinstalling if you havent already.
…On Thu, Mar 25, 2021, 11:40 AM Ryan Spolnik ***@***.***> wrote:
I have followed all the documentation on migrating from Gatsby 2 to 3, but
no matter what I do, I keep getting this error message on build. This is
mentioned in the documentation, but the fix they suggest still is not
working. The only way to get it working is to manually add Webpack which
causes other issues.
Here is the error:
` ERROR
(node:71417) [DEP_WEBPACK_MAIN_TEMPLATE_OUTPUT_OPTIONS]
DeprecationWarning: MainTemplate.outputOptions is deprecated (use
Compilation.outputOptions instead)
(Use node --trace-deprecation ... to show where the warning was created)
ERROR
(node:71417) [DEP_WEBPACK_MAIN_TEMPLATE_REQUIRE] DeprecationWarning:
MainTemplate.hooks.require is deprecated (use
JavascriptModulesPlugin.getCompilationHooks().renderRequire instead)
ERROR
(node:71417) [DEP_WEBPACK_COMPILATION_NORMAL_MODULE_LOADER_HOOK]
DeprecationWarning: Compilation.hooks.normalModuleLoader was moved to
NormalModule.getCompilationHooks(compilation).loader
⠋ Building development bundle
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/yoga-layout-prebuilt/yoga-layout/build/Release/nbind.js:53
throw ex;
^
Error: NormalModuleFactory.afterResolve (ReactRefreshPlugin) is no longer
a waterfall hook, but a bailing hook instead. Do not return the passed
object, but modify it instead. Returning false will ignore the request and
results in no module created.
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:291:14
at Hook.eval [as callAsync] (eval at create
(/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/tapable/lib/HookCodeFactory.js:33:10),
:16:1)
at Hook.CALL_ASYNC_DELEGATE [as _callAsync]
(/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/tapable/lib/Hook.js:18:14)
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:287:30
at eval (eval at create
(/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/tapable/lib/HookCodeFactory.js:33:10),
:15:1)
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:532:7
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:117:11
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:564:8
at NormalModuleFactory.resolveRequestArray
(/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:915:34)
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:556:11
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:117:11
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:636:8
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:786:5
at finishResolved
(/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/enhanced-resolve/lib/Resolver.js:278:11)
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/enhanced-resolve/lib/Resolver.js:342:25
at
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/enhanced-resolve/lib/Resolver.js:409:24`
Here is my package.json:
"dependencies": {
***@***.***/theme-get": "^5.1.2",
"focus-trap-react": "^8.4.2",
"framer-motion": "^4.0.3",
"gatsby": "^3.0.4",
"gatsby-plugin-canonical-urls": "^3.1.0",
"gatsby-plugin-contentful-optional-fields": "^2.2.0",
"gatsby-plugin-eslint": "^3.0.0",
"gatsby-plugin-exclude": "^1.0.2",
"gatsby-plugin-force-trailing-slashes": "^1.0.5",
"gatsby-plugin-google-tagmanager": "^3.0.0",
"gatsby-plugin-image": "^1.1.0",
"gatsby-plugin-intl": "^0.3.3",
"gatsby-plugin-lunr": "^1.5.2",
"gatsby-plugin-manifest": "^3.0.0",
"gatsby-plugin-module-resolver": "^1.0.3",
"gatsby-plugin-offline": "^4.1.0",
"gatsby-plugin-portal": "^1.0.7",
"gatsby-plugin-react-helmet": "^4.0.0",
"gatsby-plugin-remote-images": "^2.4.0",
"gatsby-plugin-sass": "^4.0.2",
"gatsby-plugin-sharp": "^3.0.1",
"gatsby-plugin-sitemap": "^3.0.0",
"gatsby-plugin-styled-components": "^4.0.0",
"gatsby-plugin-typography": "^3.0.0",
"gatsby-plugin-use-query-params": "^1.0.1",
"gatsby-query-params": "^1.2.1",
"gatsby-source-contentful": "^5.0.3",
"gatsby-source-filesystem": "^3.0.0",
"gatsby-transformer-remark": "^3.0.0",
"gatsby-transformer-sharp": "^3.0.0",
"html-to-react": "^1.4.5",
"prop-types": "^15.7.2",
"query-string": "^7.0.0",
"react": "^17.0.1",
"react-accessible-accordion": "^3.3.4",
"react-dom": "^17.0.1",
"react-focus-lock": "^2.5.0",
"react-helmet": "^6.1.0",
"react-html-parser": "^2.0.2",
"react-scroll-up-button": "^1.6.4",
"react-show-more-text": "^1.4.6",
"react-stickynode": "^3.0.5",
"react-typography": "^0.16.19",
"rxjs": "^6.6.3",
"sass": "^1.32.8",
"sass-loader": "^7.2.0",
"scroll": "^3.0.1",
"styled-components": "^5.2.1",
"styled-system": "^5.1.5",
"typography": "^0.16.19",
"uuid": "^8.3.2",
"whatwg-fetch": "^3.6.0"
},
"devDependencies": {
***@***.***/core": "^7.13.10",
***@***.***/rich-text-plain-text-renderer": "^14.1.2",
***@***.***/rich-text-react-renderer": "^14.1.2",
***@***.***/rich-text-types": "^14.1.2",
***@***.***/addon-a11y": "^6.1.21",
***@***.***/addon-actions": "^6.1.21",
***@***.***/addon-backgrounds": "^6.1.21",
***@***.***/addon-docs": "^6.1.21",
***@***.***/addon-graphql": "^6.1.21",
***@***.***/addon-knobs": "^6.1.21",
***@***.***/addon-links": "^6.1.21",
***@***.***/addon-storysource": "^6.1.21",
***@***.***/addon-viewport": "^6.1.21",
***@***.***/addons": "^6.1.21",
***@***.***/react": "^6.1.21",
***@***.***/storybook-deployer": "^2.8.7",
***@***.***/theming": "^6.1.21",
"babel-eslint": "^10.1.0",
"babel-loader": "^8.2.2",
"babel-plugin-styled-components": "^1.12.0",
"concurrently": "^6.0.0",
"dotenv": "^8.2.0",
"eslint": "^7.22.0",
"eslint-config-airbnb": "^18.2.1",
"eslint-config-prettier": "^8.1.0",
"eslint-plugin-prettier": "^3.3.1",
"prettier": "^2.2.1",
"prettier-eslint": "^12.0.0"
},
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#30467>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAARLB7GPR7EOXHLRTX2SW3TFN7QNANCNFSM4ZZ5C3HQ>
.
|
Beta Was this translation helpful? Give feedback.
0 replies
-
@KyleAMathews Thank you and yes I had tried that over a million times. Literally just figured out it was my NPM... it was at 7.7.3. Once I removed and set back to 6.14.11 everything works perfectly. Thanks again for the help! |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have followed all the documentation on migrating from Gatsby 2 to 3, but no matter what I do, I keep getting this error message on build. This is mentioned in the documentation, but the fix they suggest still is not working. The only way to get it working is to manually add Webpack which causes other issues.
Here is the error:
` ERROR
(node:71417) [DEP_WEBPACK_MAIN_TEMPLATE_OUTPUT_OPTIONS] DeprecationWarning: MainTemplate.outputOptions is deprecated (use Compilation.outputOptions instead)
(Use
node --trace-deprecation ...
to show where the warning was created)ERROR
(node:71417) [DEP_WEBPACK_MAIN_TEMPLATE_REQUIRE] DeprecationWarning: MainTemplate.hooks.require is deprecated (use
JavascriptModulesPlugin.getCompilationHooks().renderRequire instead)
ERROR
(node:71417) [DEP_WEBPACK_COMPILATION_NORMAL_MODULE_LOADER_HOOK] DeprecationWarning: Compilation.hooks.normalModuleLoader was moved to
NormalModule.getCompilationHooks(compilation).loader
⠋ Building development bundle
/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/yoga-layout-prebuilt/yoga-layout/build/Release/nbind.js:53
throw ex;
^
Error: NormalModuleFactory.afterResolve (ReactRefreshPlugin) is no longer a waterfall hook, but a bailing hook instead. Do not return the passed object, but modify it instead. Returning false will ignore the request and results in no module created.
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:291:14
at Hook.eval [as callAsync] (eval at create (/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/tapable/lib/HookCodeFactory.js:33:10), :16:1)
at Hook.CALL_ASYNC_DELEGATE [as _callAsync] (/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/tapable/lib/Hook.js:18:14)
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:287:30
at eval (eval at create (/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/tapable/lib/HookCodeFactory.js:33:10), :15:1)
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:532:7
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:117:11
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:564:8
at NormalModuleFactory.resolveRequestArray (/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:915:34)
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:556:11
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:117:11
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:636:8
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/webpack/lib/NormalModuleFactory.js:786:5
at finishResolved (/Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/enhanced-resolve/lib/Resolver.js:278:11)
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/enhanced-resolve/lib/Resolver.js:342:25
at /Users/ryanspolnik/Documents/development/pc/pcf-goc-publicsite/node_modules/gatsby/node_modules/enhanced-resolve/lib/Resolver.js:409:24`
Here is my package.json:
"dependencies": {
"@styled-system/theme-get": "^5.1.2",
"focus-trap-react": "^8.4.2",
"framer-motion": "^4.0.3",
"gatsby": "^3.0.4",
"gatsby-plugin-canonical-urls": "^3.1.0",
"gatsby-plugin-contentful-optional-fields": "^2.2.0",
"gatsby-plugin-eslint": "^3.0.0",
"gatsby-plugin-exclude": "^1.0.2",
"gatsby-plugin-force-trailing-slashes": "^1.0.5",
"gatsby-plugin-google-tagmanager": "^3.0.0",
"gatsby-plugin-image": "^1.1.0",
"gatsby-plugin-intl": "^0.3.3",
"gatsby-plugin-lunr": "^1.5.2",
"gatsby-plugin-manifest": "^3.0.0",
"gatsby-plugin-module-resolver": "^1.0.3",
"gatsby-plugin-offline": "^4.1.0",
"gatsby-plugin-portal": "^1.0.7",
"gatsby-plugin-react-helmet": "^4.0.0",
"gatsby-plugin-remote-images": "^2.4.0",
"gatsby-plugin-sass": "^4.0.2",
"gatsby-plugin-sharp": "^3.0.1",
"gatsby-plugin-sitemap": "^3.0.0",
"gatsby-plugin-styled-components": "^4.0.0",
"gatsby-plugin-typography": "^3.0.0",
"gatsby-plugin-use-query-params": "^1.0.1",
"gatsby-query-params": "^1.2.1",
"gatsby-source-contentful": "^5.0.3",
"gatsby-source-filesystem": "^3.0.0",
"gatsby-transformer-remark": "^3.0.0",
"gatsby-transformer-sharp": "^3.0.0",
"html-to-react": "^1.4.5",
"prop-types": "^15.7.2",
"query-string": "^7.0.0",
"react": "^17.0.1",
"react-accessible-accordion": "^3.3.4",
"react-dom": "^17.0.1",
"react-focus-lock": "^2.5.0",
"react-helmet": "^6.1.0",
"react-html-parser": "^2.0.2",
"react-scroll-up-button": "^1.6.4",
"react-show-more-text": "^1.4.6",
"react-stickynode": "^3.0.5",
"react-typography": "^0.16.19",
"rxjs": "^6.6.3",
"sass": "^1.32.8",
"sass-loader": "^7.2.0",
"scroll": "^3.0.1",
"styled-components": "^5.2.1",
"styled-system": "^5.1.5",
"typography": "^0.16.19",
"uuid": "^8.3.2",
"whatwg-fetch": "^3.6.0"
},
"devDependencies": {
"@babel/core": "^7.13.10",
"@contentful/rich-text-plain-text-renderer": "^14.1.2",
"@contentful/rich-text-react-renderer": "^14.1.2",
"@contentful/rich-text-types": "^14.1.2",
"@storybook/addon-a11y": "^6.1.21",
"@storybook/addon-actions": "^6.1.21",
"@storybook/addon-backgrounds": "^6.1.21",
"@storybook/addon-docs": "^6.1.21",
"@storybook/addon-graphql": "^6.1.21",
"@storybook/addon-knobs": "^6.1.21",
"@storybook/addon-links": "^6.1.21",
"@storybook/addon-storysource": "^6.1.21",
"@storybook/addon-viewport": "^6.1.21",
"@storybook/addons": "^6.1.21",
"@storybook/react": "^6.1.21",
"@storybook/storybook-deployer": "^2.8.7",
"@storybook/theming": "^6.1.21",
"babel-eslint": "^10.1.0",
"babel-loader": "^8.2.2",
"babel-plugin-styled-components": "^1.12.0",
"concurrently": "^6.0.0",
"dotenv": "^8.2.0",
"eslint": "^7.22.0",
"eslint-config-airbnb": "^18.2.1",
"eslint-config-prettier": "^8.1.0",
"eslint-plugin-prettier": "^3.3.1",
"prettier": "^2.2.1",
"prettier-eslint": "^12.0.0"
},
Beta Was this translation helpful? Give feedback.
All reactions