Open MartinSchere opened 3 years ago
Downgrading from "gatsby-plugin-netlify-cms": "^5.4.0"
to "gatsby-plugin-netlify-cms": "5.3.0"
can be used as a temporary fix.
I believe https://github.com/gatsbyjs/gatsby/pull/30526 broke this by using a different version of mini-css-extract-plugin
in the plugin from the one used in Gatsby.
I think https://github.com/gatsbyjs/gatsby/pull/31110 should fix it.
Per https://github.com/gatsbyjs/gatsby/commit/c0b6dd9aa57d7764af0472ddc88e8ebe760ed1a1 it should be released in gatsby@3.5.0
and gatsby-plugin-netlify-cms@5.5.0
@MartinSchere is this still an issue with the latest Gatsby version?
@martinjagodic The issue seem to still exist with Gatsby 5.11.0. This only occurred when upgrading webpack to 5.88.2
My setup:
gatsby-plugin-netlify-cms
version: 7.11.0Error message:
ERROR UNKNOWN
ObjectMiddleware.register: serializer for mini-css-extract-plugin/dist/CssModule/null is already registered
Error: ObjectMiddleware.register: serializer for mini-css-extract-plugin/dist/CssModule/null is already reg
istered
- ObjectMiddleware.js:211 Object.register
[webpack-npm-5.88.1-b68c09f1a7-726e7e05ab.zip]/[webpack]/lib/serialization/ObjectMiddleware.js:211:10
- index.js:182 Function.getCssModule
[mini-css-extract-plugin-npm-1.6.2-f19d00566e-c2c1f3d7e5.zip]/[mini-css-extract-plugin]/dist/index.js:182
:34
- index.js:389 MiniCssExtractPlugin.apply
[mini-css-extract-plugin-npm-1.6.2-f19d00566e-c2c1f3d7e5.zip]/[mini-css-extract-plugin]/dist/index.js:389
:44
- webpack.js:76 createCompiler
[webpack-npm-5.88.1-b68c09f1a7-726e7e05ab.zip]/[webpack]/lib/webpack.js:76:12
- webpack.js:143 create
[webpack-npm-5.88.1-b68c09f1a7-726e7e05ab.zip]/[webpack]/lib/webpack.js:143:16
- webpack.js:167 webpack
[webpack-npm-5.88.1-b68c09f1a7-726e7e05ab.zip]/[webpack]/lib/webpack.js:167:32
- index.js:72 f
[webpack-npm-5.88.1-b68c09f1a7-726e7e05ab.zip]/[webpack]/lib/index.js:72:16
- start-server.ts:153 startServer
[gatsby-virtual-0cacda6fe7]/[gatsby]/src/utils/start-server.ts:153:27
- start-webpack-server.ts:38 startWebpackServer
[gatsby-virtual-0cacda6fe7]/[gatsby]/src/services/start-webpack-server.ts:38:5
not finished Building development bundle - 3.978s
@megascrapper I hava same issue on gatsby-plugin-netlify-cms version: 7.11.0 When I upgraded gatsby-plugin-netlify-cms to version 7.12.0, the errors disappeared.
My setup is below:
Netlify CMS version: 2.15.72 React version: 18.2.0 Gatsby version: 5.11.0 gatsby-plugin-netlify-cms version: 7.12.0
works fine.
@glassonion1 This only works when I keep the webpack version at 5.88.1. Once I upgraded webpack to any newer version I got the error.
React 17 is causing the gatsby plugin to throw dependency erros (See #5111). A suggested workaround is:
This causes the issue above:
ERROR
ObjectMiddleware.register: serializer for mini-css-extract-plugin/dist/CssModule/null is already registered
Describe the bug
To Reproduce
Package.json:
This is most likely due to a dependency conflict I guess