Open danyim opened 1 year ago
This issue appears to be similar to #38465, which does not have a resolution
Same error. It seems like an issue with gatsby-source-wordpress since it disappeared after I downgraded it to version 6.25.4
@gustavo-a Thanks for the tip! That worked!
To anyone else who needs to be unblocked, I was able to get my site building with the following deps:
System:
OS: macOS 12.6.3
CPU: (8) x64 Intel(R) Core(TM) i7-6920HQ CPU @ 2.90GHz
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 18.15.0 - ~/.nvm/versions/node/v18.15.0/bin/node
Yarn: 1.22.5 - ~/.yarn/bin/yarn
npm: 9.5.0 - ~/.nvm/versions/node/v18.15.0/bin/npm
Browsers:
Chrome: 116.0.5845.96
Firefox: 116.0.2
Safari: 15.6.1
npmPackages:
gatsby: ^5.11.0 => 5.11.0
gatsby-core-utils: ^4.11.0 => 4.11.0
gatsby-image: ^3.1.0 => 3.11.0
gatsby-plugin-fontawesome-css: ^1.2.0 => 1.2.0
gatsby-plugin-gtag: ^1.0.13 => 1.0.13
gatsby-plugin-image: ^3.11.0 => 3.11.0
gatsby-plugin-offline: ^6.11.0 => 6.11.0
gatsby-plugin-postcss: ^6.11.0 => 6.11.0
gatsby-plugin-react-helmet: ^6.11.0 => 6.11.0
gatsby-plugin-react-svg: ^3.3.0 => 3.3.0
gatsby-plugin-sharp: ^5.11.0 => 5.11.0
gatsby-plugin-sitemap: ^6.11.0 => 6.11.0
gatsby-plugin-styled-components: ^6.11.0 => 6.11.0
gatsby-plugin-typescript: ^5.11.0 => 5.11.0
gatsby-plugin-web-font-loader: ^1.0.4 => 1.0.4
gatsby-source-filesystem: ^5.11.0 => 5.11.0
gatsby-source-wordpress: ^6.25.4 => 6.25.5
gatsby-transformer-sharp: ^5.11.0 => 5.11.0
npmGlobalPackages:
gatsby-core-utils: 4.8.0
gatsby: 5.8.0
I am also getting this error
It was working fine earlier, i started implementing
Using node 18.15.0
"gatsby-source-wordpress": "^7.6.0"
Still, the problem is the same, reverted the slice work, but no luck.
6.25.4
Tried with "gatsby-source-wordpress": "7.11.0"
, still same issue.
I am also getting this error
It was working fine earlier, i started implementing , and development works fine but the build fails.
- I deleted the node_module folder
- Deleted package-lock.json
- Using node 18.15.0
"gatsby-source-wordpress": "^7.6.0"
Still, the problem is the same, reverted the slice work, but no luck.
After deleting the package-lock.json and reinstalling the modules, now i am getting this error as well, DB source is same, nod modification done in CMS.
I am also getting this error
It was working fine earlier, i started implementing , and development works fine but the build fails.
- I deleted the node_module folder
- Deleted package-lock.json
- Using node 18.15.0
"gatsby-source-wordpress": "^7.6.0"
Still, the problem is the same, reverted the slice work, but no luck.
In my case after investing days, I found the at getServerData
which i am using in pages
folder causing the issue. When I removed this method, a build was created. Now i am trying to debug the issue with this method as same method working on other 4 projects, which i created.
export async function getServerData() {
try {
// const res = await fetchFavorite();
return {
status: 200,
props: {
data: "Server data",
},
}
} catch (error) {
return {
status: 500,
headers: {},
props: {},
}
}
}```
In the case of my error https://github.com/gatsbyjs/gatsby/issues/38465 the error seems very closely linked to the reasons I explain in my reply.
@insaurabh Interesting how you've come across this error on SSR, thanks for pointing that out. I've noticed the same happening on another of my websites.
@insaurabh @danyim @gustavo-a
I've rolled back to 7.9.0 and this seems to fix both the current issue and also the https://github.com/gatsbyjs/gatsby/issues/38465
@insaurabh @danyim @gustavo-a
I've rolled back to 7.9.0 and this seems to fix both the current issue and also the #38465
Hi @CloudBop
7.9.0 worked for me as well. I rolled back to this version and tested my site, every thing seems fine. I tried the latest version as well but it was not working, same error was thrown.
Thank you.
Hi !
I have the same issue while upgrading from 4 to 5. Gatsby develop works, build throws the same error. I downgraded "gatsby-source-wordpress" to 6.25.5 and it works. 7.9.0 did not work for me. I had to override some peer dependencies like that :
"overrides": {
"gatsby-source-wordpress": {
"gatsby": "^5.13.3",
"gatsby-plugin-image": "^3.13.1",
"gatsby-plugin-sharp": "^5.13.1",
"gatsby-transformer-sharp": "^5.13.1"
}
},
Thanks
@insaurabh @danyim @gustavo-a I've rolled back to 7.9.0 and this seems to fix both the current issue and also the #38465
Hi @CloudBop
7.9.0 worked for me as well. I rolled back to this version and tested my site, every thing seems fine. I tried the latest version as well but it was not working, same error was thrown.
Thank you.
Hey @insaurabh, did you end up getting builds working when using getServerData() ? that seems to be the catalyst for me and I'm pretty desperate for a solution as I need this for Wordpress preview pages.
When flipping the silent bool on the validateEngines function inside Gatsby's validate-engines util to false, the build fail log outputs:
Error: [Immer] minified error nr: 18 'MapSet'. Find the full error at: https://bit.ly/3cXEKWf
Encountered a critical error when running the checkIfSchemaHasChanged build step
I am getting this error now usnig 7.9.0 with node 18.15.0
@insaurabh @danyim @gustavo-a I've rolled back to 7.9.0 and this seems to fix both the current issue and also the #38465
Hi @CloudBop 7.9.0 worked for me as well. I rolled back to this version and tested my site, every thing seems fine. I tried the latest version as well but it was not working, same error was thrown. Thank you.
Hey @insaurabh, did you end up getting builds working when using getServerData() ? that seems to be the catalyst for me and I'm pretty desperate for a solution as I need this for Wordpress preview pages.
For that project getServerData() working when rolled back.
It's so weirdly inconsistent. Sometimes if I remove my node_modules folder and .lock, start a fresh install, it complains with the validation engine error, so i uninstall gatsby-source-wordpress, reinstall to 7.10.1 it works (sometimes). When investigating the validation error more closely (by going into node_modules > gatsby > dist > utils > validate-engines > index.js and setting silent to false ) it looked like the errors were stemming from immer, more precisely @rematch/immer.
Because some other plugins i have like react-redux, were using different versions of immer i had to set some overrides for gatsby-source-wordpress in my package.json
"overrides": {
"gatsby-source-wordpress": {
"@rematch/immer": "1.2.0",
"immer": "9.0.21"
}
}
This fixed it for me but i still can't add certain options in the gatsby-config for gatsby-source-wordpress like presets etc.... such a headache.
I am getting this error now usnig 7.9.0 with node 18.15.0
@vipinamethi try my approach above:
rm -rf node_modules rm -rf package-lock.json
add "gatsby-source-wordpress": "^7.10.1" to your dependencies
then add
"overrides": {
"gatsby-source-wordpress": {
"@rematch/immer": "1.2.0",
"immer": "9.0.21"
}
}
to your package.json, then npm install.
Hello I have the same issue :
bringing my Gatsby v2 site up to v5
gatsby develop is fine
ERROR #98001 ENGINE.VALIDATION
__nccwpck_require__ is not define /opt/soft/io-gatsby5/.cache/query-engine/index.js
apparently it's a problem with wepack
Preliminary Checks
Description
Hello,
I am in the process of bringing my Gatsby v3 site up to v5, and unfortunately I am running into some issues when executing
gatsby build
. After agatsby clean
andgatsby build --verbose
, I receive the following nondescript error:My repo works without issue when running
gatsby develop
.Reproduction Link
(In progress)
Steps to Reproduce
gatsby build --verbose
Expected Result
I expected a successful build
Actual Result
Build fails with
ERROR #98001 ENGINE.VALIDATION
Environment
Config Flags
None