[wp-trac] [WordPress Trac] #51158: With ACF Blocks in 5.5, "enqueue_assets" causes fatal error
WordPress Trac
noreply at wordpress.org
Thu Aug 27 15:20:27 UTC 2020
#51158: With ACF Blocks in 5.5, "enqueue_assets" causes fatal error
---------------------------+-------------------------------------
Reporter: bronsonoquinn | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Editor | Version: 5.5
Severity: blocker | Keywords: 2nd-opinion needs-patch
Focuses: |
---------------------------+-------------------------------------
This is related to ACF Pro, but didn't happen until the upgrade to WP 5.5.
I downgraded to 5.4.2 to make sure and I can verify it's a WordPress
issue, likely related to REACT or the Rest API. I don't know enough about
the Gutenberg editor to know if it's specific to that, so I'm posting here
with "second-opinion" Workflow Keyword.
I have several custom blocks created using ACF Pro. One of them requires
multiple javascript files and uses the "enqueue_assets" attribute to
enqueue them.
When I try to edit any post, I get a popup error that covers the entire
screen saying "The editor has encountered an unexpected error." and has 3
buttons: "Attempt Recovery", "Copy Post Text", "Copy Error". None of the
buttons work.
In the console, I get these errors:
}}}
react-dom.min.js?ver=16.9.0:103
TypeError: First argument must be a String, HTMLElement, HTMLCollection,
or NodeList
at t.exports (compose.min.js?ver=c4775e2aa9288586791e26a980eff851:9)
at e.value (compose.min.js?ver=c4775e2aa9288586791e26a980eff851:9)
at new e (compose.min.js?ver=c4775e2aa9288586791e26a980eff851:9)
at compose.min.js?ver=c4775e2aa9288586791e26a980eff851:9
at Vb (react-dom.min.js?ver=16.9.0:104)
at Xi (react-dom.min.js?ver=16.9.0:151)
at unstable_runWithPriority (react.min.js?ver=16.9.0:26)
at Ma (react-dom.min.js?ver=16.9.0:52)
at Yb (react-dom.min.js?ver=16.9.0:150)
at O (react-dom.min.js?ver=16.9.0:120)
components-1480.js:24
Uncaught TypeError: Cannot read property 'clientHeight' of null
at G.hasOverflowedContent (components-1480.js:24)
at G.fitTitle (components-1480.js:24)
at components-1480.js:24
}}}
After the second error, the first error repeats and keeps getting hit
every few milliseconds, telling me it has thousands of times within a
minute.
I'll post this with ACF Pro, too, but wanted to mention here in case it's
a WordPress bug. I don't know how many people use ACF blocks in the Block
Editor, but it completely prevents people from editing posts if they have
some.
Thanks!
--
Ticket URL: <https://core.trac.wordpress.org/ticket/51158>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list