Gutenberg: The editor has encountered an unexpected error (Invariant Violation: Minified React error #130)

Created on 14 Sep 2018  路  9Comments  路  Source: WordPress/gutenberg

After I updated the Gutenberg to latest version (3.8.0), i am not able to edit any existing post or add any new post using Gutenberg Editor. The Error message is below.

Invariant Violation: Minified React error #130; visit https://reactjs.org/docs/error-decoder.html?invariant=130&args[]=undefined&args[]= for the full message or use the non-minified dev environment for full errors and additional helpful warnings. 
    at Sg (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:7:14080)
    at m (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:1:388)
    at ed (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:4:11859)
    at https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:4:23269
    at rd (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:5:1021)
    at O (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:5:956)
    at yh (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:5:7721)
    at lg (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:7:2629)
    at mg (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:7:2927)
    at gc (https://www.pyarb.com/wp-content/plugins/gutenberg/vendor/react-dom.min.82e21c65.js:7:6310)

Expected behavior
The new update should not behave like it is newly installed. First it make me to skip or view the feature guide. Which was already clicked skipped. Then the Post in draft open and when I clicked in the body section for editing, it goes unresponsive with below screen and now even for the new post it is showing same screen.

Screenshots
image

Desktop (please complete the following information):

  • OS: [Windows 10 Pro 1803]
  • Browser [Version 71.0.3551.3 (Official Build) canary (64-bit)]
  • Version [71.0.3551.3]

Additional context

  • Please add the version of Gutenberg you are using in the description.
  • To report a security issue, please visit the WordPress HackerOne program: https://hackerone.com/wordpress.

With the continuous compatibility issues with other plugins and themes, and frequent issues, it is very hard to replace the classic editor. Please fix this asap.

Needs Testing [Status] Needs More Info

Most helpful comment

I'd appreciate if Gutenberg can spit out "detailed & specific" error instead of generic error text

All 9 comments

Thanks for reporting this. I'm adding the Needs Testing label and also noting the more specific error message referenced in your post:

Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined.

Source: https://reactjs.org/docs/error-decoder.html?invariant=130&args[]=undefined&args[]=

The editor has encountered an unexpected error.

Source: the screenshot.

Got the same error on updating Gurenberg. Running dev environment using WAMP with latest WordPress.

I'd appreciate if Gutenberg can spit out "detailed & specific" error instead of generic error text

Same error

Additional info: React's site for the error says

In the minified production build of React, we avoid sending down full error messages in order to reduce the number of bytes sent over the wire.

We highly recommend using the development build locally when debugging your app since it tracks additional debug info and provides helpful warnings about potential problems in your apps, but if you encounter an exception while using the production build, this page will reassemble the original text of the error.

And the js console says

or use the non-minified dev environment for full errors and additional helpful warnings. 

Any way to tell my WP development site to use the non-minified version?

Any way to tell my WP development site to use the non-minified version?

It can be done including a SCRIPT_DEBUG constant in your site's wp-config.php file:

https://codex.wordpress.org/Debugging_in_WordPress#SCRIPT_DEBUG

To the issue at hand: The non-minified error would provide more helpful debugging information. In the meantime, I've often seen that clearing your browser's localStorage can resolve some of these issues. This can be done either in your browser's "Clear History", or by entering the command localStorage.clear() in the browser's console.

It can be done including a SCRIPT_DEBUG constant in your site's wp-config.php file

That worked for me, thanks!

It's worth nothing that there's currently a bug which makes it difficult to leave enabled:

https://github.com/WordPress/gutenberg/issues/7897 / https://github.com/WordPress/gutenberg/issues/11360

This issue is not actionable in its current form.

It would need to include one or other of:

  • Reliable steps to reproduce
  • A detailed error log from the unminified script

Is this still an issue for those reporting to have been affected? The screenshot symptom can be attributed to any number of possible error reasons. I'm particularly curious about this specific error message which traces back to :

Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined.

Closing as non-actionable. The issue can be reopened if additional information is provided.

Was this page helpful?
0 / 5 - 0 ratings