gutenberg icon indicating copy to clipboard operation
gutenberg copied to clipboard

Text Block: "This block has encountered an error and cannot be previewed." after update to 6.5

Open MR444 opened this issue 9 months ago • 1 comments

Description

Not sure if it's a problem with the block editor or WP 6.5.x. After I updated to WP 6.5, I cannot see my text blocks anymore in the block editor. Everywhere I get the message "This block has encountered an error and cannot be previewed."

First I thought it a problem with my old website but it also appears on me new website which I created when 6.5 came out.

When I downgrade to 6.4.3, everything works fine again.

Step-by-step reproduction instructions

See gif animation. block

Screenshots, screen recording, code snippet

In the console of my web browser, I get the following errors on boths websites (new and old). I don't know if it has something to do with this problem:

WebExtension context not found! 3 [ExtensionParent.sys.mjs:1278:13](https://gre/modules/ExtensionParent.sys.mjs)

    getContextById resource://gre/modules/ExtensionParent.sys.mjs:1278

    recvRemoveListener resource://gre/modules/ExtensionParent.sys.mjs:1257

    _recv resource://gre/modules/ConduitsChild.sys.mjs:77

    receiveMessage resource://gre/modules/ConduitsParent.sys.mjs:469

AbortError: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved [ConduitsParent.sys.mjs:378](https://gre/modules/ConduitsParent.sys.mjs)

    _raceResponses resource://gre/modules/ConduitsParent.sys.mjs:378
this.window.gBrowserInit is undefined [ext-browser.js:1114:9](https://browser/content/parent/ext-browser.js)

    get activeTab chrome://browser/content/parent/ext-browser.js:1114

    candidates chrome://extensions/content/parent/ext-tabs-base.js:2105

    next self-hosted:1386

    query chrome://extensions/content/parent/ext-tabs-base.js:2127

    next self-hosted:1386

    from self-hosted:579

    query chrome://browser/content/parent/ext-tabs.js:1006

    result resource://gre/modules/ExtensionParent.sys.mjs:1137

    withCallContextData resource://gre/modules/ExtensionParent.sys.mjs:611

    result resource://gre/modules/ExtensionParent.sys.mjs:1136

    withPendingBrowser resource://gre/modules/ExtensionParent.sys.mjs:621

    result resource://gre/modules/ExtensionParent.sys.mjs:1135

    callAndLog resource://gre/modules/ExtensionParent.sys.mjs:1086

    recvAPICall resource://gre/modules/ExtensionParent.sys.mjs:1134

    AsyncFunctionNext self-hosted:852
```

### Environment info

Wordpress 6.5, 6.5.3
Theme: Twenty-Twenty-Three
Plugins: Deactivated and activated (no difference)
Worked until Wordpress 6.4.3

### Please confirm that you have searched existing issues in the repo.

Yes

### Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

MR444 avatar May 13 '24 19:05 MR444

@MR444 When you say text block, do you mean paragraph block? Or do you have a third party text block installed?

The error looks like it's coming from a browser extension, so it might be worth deactivating browser extensions, and seeing if any of them are causing an issue.

talldan avatar May 14 '24 01:05 talldan

Interesting, this is really true! I just tried Chrome browser instead of Firefox 125.0.3 and there it works. The problem in Firefox was caused by the addon NoScript. I could solve the problem with NoScript deactivated and reproduce it with NoScript activated. Didn't expect that an browser extension can cause this problem. And the strange thing is that it works without problems with Wordpress 6.4.3, even with NoScript activated.

Thank you very much! :)

MR444 avatar May 14 '24 02:05 MR444