[wp-trac] [WordPress Trac] #53821: Validation Error for Block that Isn't in Use - Multisite Env

WordPress Trac noreply at wordpress.org
Thu Jul 29 00:22:38 UTC 2021


#53821: Validation Error for Block that Isn't in Use - Multisite Env
--------------------------+-----------------------------
 Reporter:  tinamar       |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Autosave      |    Version:  5.8
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 I work with a pretty big multisite environment (45 sites) hosted with WP
 Engine. I work on a local environment, then push to staging (WPE Engine),
 then push to production. Currently, local and staging use WordPress 5.8,
 but I haven't updated production yet. On staging and local, the browser
 console shows the error below. Production does not show the error. The
 error shows in the page editor -- always. When I am adding a new page and
 haven't entered a title or added a block; when I open a page that doesn't
 have the block mentioned in the error; and when I'm working on a page that
 does use the block. The pages work fine. The block seems to work fine. But
 I'm kind of anal when it comes to errors and warnings in the console.

 The error says that is was generated by the "Save" function. I believe it
 must be the autosave function as the error appears as soon as a new or
 existing page is loaded into the editor. No active "save" action as to
 take place.

 This is the error/message from the console:

 *** BEGIN MESSAGE ***
 Block validation: Block validation failed for `core/quote` ({name:
 "core/quote", icon: {…}, keywords: Array(2), attributes: {…},
 providesContext: {…}, …}).

 Content generated by `save` function:

 <blockquote class="viewport-display has-text-align-center wp-block-quote
 is-style-large"><p>"Contributing makes me feel like I'm being useful to
 the planet."</p><cite>— Anna Wong, <em>Volunteer</em></cite></blockquote>

 Content retrieved from post body:

 <blockquote class="wp-block-quote has-text-align-center is-style-
 large"><p>"Contributing makes me feel like I'm being useful to the
 planet."</p><cite>— Anna Wong, <em>Volunteer</em></cite></blockquote>
 *** END MESSAGE ***

 As you can see from the error/message, there is reference to some
 placeholder version of the quote block. But when I look in the template
 and block libraries, I see no such placeholder text. Neither the core
 quote block nor the core pullquote block (as seen in the block library)
 contains a placeholder quote by Anna Wong.

 I searched the database. The main site (site #1) contains a couple of
 records in the _sitemeta table with this meta key:
 _site_transient_wp_remote_block_patterns_...

 Those records contain the placeholder quote that appears in the error
 message.

 The function generating the message gets printed to the file's output
 source:

 function() {
         window._wpLoadBlockEditor = new Promise( function( resolve ) {
                 wp.domReady( function() {
                         resolve( wp.editPost.initializeEditor(...

 That function seems to be generated by wp-admin/edit-form-blocks.php

 Since this error is only occurring on local and staging (which use v 5.8)
 and not on production (5.7.2) I'm reluctant to upgrade production right
 now.

 Sorry for the long read...  Anyone else experiencing this or know what to
 do about it?

 Thanks!

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/53821>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list