Make WordPress Core

Opened 5 months ago

Closed 4 months ago

#53761 closed defect (bug) (worksforme)

Widgets Panel powered by Block Editor completely broken

Reported by: GDragoN Owned by:
Milestone: Priority: normal
Severity: critical Version: 5.8
Component: Widgets Keywords: reporter-feedback
Focuses: javascript, rest-api Cc:


So, I have a test website, upgraded to 5.8. No plugins are active, TwentyNineteen theme is active, the same thing happens with or without SCRIPTDEBUG enabled or disabled. JavaScript console quickly fills with errors, the Update button is not working (always disabled), and I try adding only real blocks (no Legacy Widgets - no plugins active). Completely unusable.

Attachments (1)

block-widgets-fully-broken.png (148.1 KB) - added by GDragoN 5 months ago.
Screenshot with Blocks Editor Widgets Panel and JS console errors.

Download all attachments as: .zip

Change History (13)

5 months ago

Screenshot with Blocks Editor Widgets Panel and JS console errors.

#1 @GDragoN
5 months ago

For reference, I am running PHP 7.4.20, with Apache 2.4.35, under Laragon. This is not happening on every website I have updated to 5.8, it does happen on a few of them. Also, I tried to reinstall WP 5.8, but nothing changes.

#2 @GDragoN
5 months ago

On websites where it is broken, it is broken with any theme, included 2020 or 2021.

#3 @zieladam
5 months ago

I haven't actually reproduced the issue or followed the minified stack trace, but this looks to a likely candidate:


#4 @azaozz
5 months ago

What is the very first error in the console? Are there any network errors on the sites it doesn't work?

Also did you try reloading the page few times while holding down Shift to refresh the caches (unlikely but not impossible)?

#5 @azaozz
5 months ago

  • Keywords reporter-feedback added

#6 follow-up: @GDragoN
5 months ago

I am not sure what was the first error. It took me few minutes to realize that widgets are not saving at all, and after opening the console, there were errors from my screenshot. Also, one of the errors repeats anytime I type, each keypress generates another error. And, I tried with and without browser cache, and with and without ScriptDebug and WP_Debug. I tested with the various themes, including all default Twenty*, it has no effect. Enabling plugins does nothing, it is broken with or without plugins.

So far, I have upgraded 15 of my development website (local), and 3 are broken in the same way. I really can't explain what could be the reason for some to be broken, and the rest are fine. And, the screenshot I posted is from the clean install (not upgrade), so it has happened to me with both upgrades and clean installs.

Last edited 5 months ago by GDragoN (previous) (diff)

This ticket was mentioned in Slack in #core-test by hellofromtonya. View the logs.

4 months ago

#8 @andraganescu
4 months ago

hi @GDragoN. Could you install theClassic Widgets plugin for debugging purposes on the local sites that are experiencing issues and inspect if there are any widgets in sidebars, unused or inactive? The logs in the screenshot appear tome me like some unexpected responsed from the API.

#9 @GDragoN
4 months ago

I already did that, and in the upgrade instance, there were widgets that were unused. I removed all, retested it, and it was still broken. And, as I said, this happened on the new install as well, where nothing was in the sidebars. I tried downgrading some sites to 5.7, cleanup the widgets, and upgrade again, the same. The website that was broken when the upgrade was first installed, or the website that was broken on a new install, remains broken no matter what. I did create more new installations, all were OK. To be honest, I have given up on this new Widgets panel, due to other issues (I opened another ticket), as it stands now, it is quite unusable anyway for most widgets.

#10 in reply to: ↑ 6 @hellofromTonya
4 months ago

Replying to GDragoN:

So far, I have upgraded 15 of my development website (local), and 3 are broken in the same way.

If I'm understanding correctly, the 3 broken sites are local on your machine and not live sites. Is this correct? Have you experienced the same problems with live sites?

I'm wondering if there's something isolated to your local setup maybe some a must-use script, browser add-on, etc.

#11 @GDragoN
4 months ago

I have updated few live websites, but I installed Classic Widgets on all of them, I do not really see the need to use the new Widgets Panel on live websites or to experiment on the live websites with something that is clearly not needed right now. I have development setups for this very reason.

I tested with no browser extensions, no must-use scripts that can affect this. On most websites, I updated it works, but on some that are broken, I see no way to fix it. Because this is so far a very specific issue that no one else reported or encountered, I am willing to accept that something very obscure is causing the problem, but I hope that there will be some changes in the code to validate the data before it gets used.

The errors I have seen point to the problem with invalid data, so nothing is validating the data before it is sent. If that is fixed, I am sure similar issue will be avoided in the future.

#12 @azaozz
4 months ago

  • Milestone Awaiting Review deleted
  • Resolution set to worksforme
  • Status changed from new to closed

a very specific issue that no one else reported or encountered

Yeah, looks that way. It would have been good to get to the bottom of it but at this point I'm out of ideas too.

Closing as worksforme for now. Feel free to reopen with more info or a way to consistently reproduce.

Note: See TracTickets for help on using tickets.