• The new Gutenberg widgets block editor that was included with Gutenberg 9.0.0 had lots of problems which have now gotten worse since the update to 9.1.0.

    1. My theme has 13 registered widget areas (side bars). The new widget block editor only shows the first 9 of them.

    2. I use a plugin (Widget CSS Classes) which adds a custom class field to all widgets. The custom class field is not displayed by the new block widget rendering.

    3. I have an unused HTML widget parked in Inactive Widgets. In Gutenberg 9.0.0 this caused the following errors:

    PHP Notice: Undefined index: before_widget in \wp-includes\widgets\class-wp-widget-custom-html.php on line 168
    PHP Notice: Undefined index: before_title in \wp-includes\widgets\class-wp-widget-custom-html.php on line 172
    PHP Notice: Undefined index: after_title in \wp-includes\widgets\class-wp-widget-custom-html.php on line 172
    PHP Notice: Undefined index: after_widget in \wp-includes\widgets\class-wp-widget-custom-html.php on line 177

    The Inactive Widget Block Area is obviously not defining these entries, yet the WP_Widget_Custom_HTML class’ widget method is expecting them in its $args parameter.

    4. The following php warning is being generated multiple times when the widget block editor is loaded:

    PHP Warning: call_user_func() expects parameter 1 to be a valid callback, cannot access private method WP_REST_Widget_Utils_Controller::is_valid_widget() in \wp-includes\rest-api\class-wp-rest-request.php on line 898

    5. In 9.1.0 when I try Preview a widget, instead of the seeing the rendered widget, I see this:

    PHP Fatal error: Uncaught Error: Call to a member function render() on null in \wp-content\plugins\gutenberg\lib\widget-preview-template.php:37

    When is the development team going to do some proper testing before they inflict this badly coded plugin on users?

    Seems to be still experimental, so I’m pulling the plug on the new Gutenberg widget blocks until I see some real progress towards fixing it.

Viewing 15 replies - 1 through 15 (of 24 total)
  • @drtonyb Thanks so much for sharing this feedback although I’m bummed it’s caused so many issues on your site. I’m not sure if you saw this post below but we’re actively looking for reports of these kinds of problems as we work to improve the current experience of the Widgets Screen:

    Call for Testing the Widgets Screen in Gutenberg 9.1

    This was part of the goal in moving the screen out of experimental when it was stable enough! By chance, would you be open to sharing more information in the form of a GitHub issue about your site? You can do so here:

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

    If you can provide information about the theme you are using along with any additional plugins for example, that would be a great help! If you happen to be in the www.remarpro.com slack installation, you’re welcome to ping me there too if you’d like to chat about this. My username is annezazu.

    Thread Starter drtonyb

    (@drtonyb)

    I activated the Twenty Nineteen theme, added an HTML widget to the Inactive widgets area on the /wp-admin/widgets.php page. Every thing else was standard Twenty Nineteen.

    Displaying the new wdgets page /wp-admin/themes.php?page=gutenberg-widgets produces the same result as my own theme. My development system is in debug mode so that I can catch these problems and this is the php error log on loading the new Gutenberg widgets page:

    [03-Oct-2020 02:34:58 UTC] PHP Notice: Undefined index: before_widget in C:\Server\public_html\wordpress\wp-includes\widgets\class-wp-widget-custom-html.php on line 168
    [03-Oct-2020 02:34:58 UTC] PHP Notice: Undefined index: before_title in C:\Server\public_html\wordpress\wp-includes\widgets\class-wp-widget-custom-html.php on line 172
    [03-Oct-2020 02:34:58 UTC] PHP Notice: Undefined index: after_title in C:\Server\public_html\wordpress\wp-includes\widgets\class-wp-widget-custom-html.php on line 172
    [03-Oct-2020 02:34:58 UTC] PHP Notice: Undefined index: after_widget in C:\Server\public_html\wordpress\wp-includes\widgets\class-wp-widget-custom-html.php on line 177
    [03-Oct-2020 02:35:00 UTC] PHP Warning: call_user_func() expects parameter 1 to be a valid callback, cannot access private method WP_REST_Widget_Utils_Controller::is_valid_widget() in C:\Server\public_html\wordpress\wp-includes\rest-api\class-wp-rest-request.php on line 898
    [03-Oct-2020 02:35:00 UTC] PHP Fatal error: Uncaught Error: Call to a member function render() on null in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php:37
    Stack trace:
    #0 C:\Server\public_html\wordpress\wp-includes\template-loader.php(106): include()
    #1 C:\Server\public_html\wordpress\wp-blog-header.php(19): require_once(‘C:\\Server\\publi…’)
    #2 C:\Server\public_html\wordpress\index.php(17): require(‘C:\\Server\\publi…’)
    #3 {main}
    thrown in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php on line 37
    [03-Oct-2020 02:35:00 UTC] PHP Fatal error: Uncaught Error: Call to a member function render() on null in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php:37
    Stack trace:
    #0 C:\Server\public_html\wordpress\wp-includes\template-loader.php(106): include()
    #1 C:\Server\public_html\wordpress\wp-blog-header.php(19): require_once(‘C:\\Server\\publi…’)
    #2 C:\Server\public_html\wordpress\index.php(17): require(‘C:\\Server\\publi…’)
    #3 {main}
    thrown in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php on line 37
    [03-Oct-2020 02:35:00 UTC] PHP Fatal error: Uncaught Error: Call to a member function render() on null in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php:37
    Stack trace:
    #0 C:\Server\public_html\wordpress\wp-includes\template-loader.php(106): include()
    #1 C:\Server\public_html\wordpress\wp-blog-header.php(19): require_once(‘C:\\Server\\publi…’)
    #2 C:\Server\public_html\wordpress\index.php(17): require(‘C:\\Server\\publi…’)
    #3 {main}
    thrown in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php on line 37
    [03-Oct-2020 02:35:01 UTC] PHP Warning: call_user_func() expects parameter 1 to be a valid callback, cannot access private method WP_REST_Widget_Utils_Controller::is_valid_widget() in C:\Server\public_html\wordpress\wp-includes\rest-api\class-wp-rest-request.php on line 898
    [03-Oct-2020 02:35:01 UTC] PHP Warning: call_user_func() expects parameter 1 to be a valid callback, cannot access private method WP_REST_Widget_Utils_Controller::is_valid_widget() in C:\Server\public_html\wordpress\wp-includes\rest-api\class-wp-rest-request.php on line 898
    [03-Oct-2020 02:35:01 UTC] PHP Warning: call_user_func() expects parameter 1 to be a valid callback, cannot access private method WP_REST_Widget_Utils_Controller::is_valid_widget() in C:\Server\public_html\wordpress\wp-includes\rest-api\class-wp-rest-request.php on line 898
    [03-Oct-2020 02:35:01 UTC] PHP Warning: call_user_func() expects parameter 1 to be a valid callback, cannot access private method WP_REST_Widget_Utils_Controller::is_valid_widget() in C:\Server\public_html\wordpress\wp-includes\rest-api\class-wp-rest-request.php on line 898
    [03-Oct-2020 02:35:01 UTC] PHP Fatal error: Uncaught Error: Call to a member function render() on null in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php:37
    Stack trace:
    #0 C:\Server\public_html\wordpress\wp-includes\template-loader.php(106): include()
    #1 C:\Server\public_html\wordpress\wp-blog-header.php(19): require_once(‘C:\\Server\\publi…’)
    #2 C:\Server\public_html\wordpress\index.php(17): require(‘C:\\Server\\publi…’)
    #3 {main}
    thrown in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php on line 37
    [03-Oct-2020 02:35:02 UTC] PHP Fatal error: Uncaught Error: Call to a member function render() on null in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php:37
    Stack trace:
    #0 C:\Server\public_html\wordpress\wp-includes\template-loader.php(106): include()
    #1 C:\Server\public_html\wordpress\wp-blog-header.php(19): require_once(‘C:\\Server\\publi…’)
    #2 C:\Server\public_html\wordpress\index.php(17): require(‘C:\\Server\\publi…’)
    #3 {main}
    thrown in C:\Server\public_html\wordpress\wp-content\plugins\gutenberg\lib\widget-preview-template.php on line 37

    I will create a child for the Twenty Nineteen theme and add more widget areas to check if it can display more than nine, but I doubt that it will.

    @drtonyb Thanks for clarifying what theme you’re using as well as sharing the errors you’re seeing. I dug into GitHub to see what might need to be reported and found one of the errors you were running into has already been:

    https://github.com/WordPress/gutenberg/issues/25789

    For the error around the unused HTML widget in Inactive Widgets, do you still see this error when using Gutenberg 9.1.0? I ask because I tried to replicate this error using the Twenty Nineteen theme and HTML widgets in the Inactive Widget section but was unable to do so.

    Finally, when you were previewing the widget, was the widget in question a legacy one? If so, it seems this reported bug likely applies:

    https://github.com/WordPress/gutenberg/issues/25749

    As for only 9/13 of the registered sidebars showing up and the Widget CSS Classes plugin problem, I’ll dig into those tomorrow and report back!

    Hi @drtonyb! I am back with more information for you. I was able to replicate both the sidebar visibility issue and the Widget CSS Classes problem. I reported the sidebars seemingly maxing out here:

    https://github.com/WordPress/gutenberg/issues/25932

    I also contacted the plugin author for the Widget CSS Classes plugin to let them know about the call for testing for this new screen and to ask them to file an issue in GitHub for what they need to get this working properly. I know this doesn’t solve your issue directly but know that I’ve reached out and am very appreciative that you’ve flagged this for us.

    Thread Starter drtonyb

    (@drtonyb)

    Hi @annezazu,

    I’m glad that you have been able to reproduce the problems I’ve had with the new widget blocks page.

    The previewing widgets problem is for legacy widgets.

    Now with Gutenberg 9.1.1 there is a new problem with legacy widgets. When preview is activated, the filter ‘dynamic_sidebar_params’ receives one argument, an array $params, which now has -1 as the value of $params[0][‘widget_id’] instead of its correct ID. The Widget CSS Classes plugin is using this filter and because I’m using the plugin, it generates this error when I now try previewing a legacy widget.

    PHP Notice: Undefined offset: -1 in \wp-content\plugins\widget-css-classes\includes\widget-css-classes.class.php on line 467

    I’m also seeing a change in the Inactive Widget area. I placed a Custom HTML widget with some HTML content in the Inactive Widget area using the old widget editor, then went to the new block widget editor page. The content initially showed blank. Clicking in the content section activated the widget and showed the content, but the lines of HTML are now being overlayed by line numbers.

    For completeness, 9.1.0 and 9.1.1 I tried the out-of-the-box Twenty Twenty theme and got the same results.

    Hi All,

    I’m also receiving error messages and can’t edit the Gutenberg widget blocks any longer. This is what each block says: “This block has encountered an error and can’t be previewed”.This is my latest updates WordPress 5.5.1 running Refined Theme. Using Genesis 3.3.3. Can you tell me why I’m experiencing errors or is there something I’m doing wrong?

    Plugin Support Paal Joachim Romdahl

    (@paaljoachim)

    Hi

    We have released a Gutenberg version 9.1.1 that should take care of the preview and a few other bugs as well.

    @drtonyb
    If you could take a look through the issues here: https://github.com/WordPress/gutenberg/issues?q=is%3Aissue+is%3Aopen+label%3A%22%5BFeature%5D+Widgets+Screen%22
    and see if any covers the problems you are seeing that would be helpful. Then open a new issue if needed. Thank you!

    @wball1
    Are you using the latest Gutenberg version 9.1.1?

    Yes I have the latest version 9.1.1 and its still showing error messages when I try to edit a block. I don’t show a preview button as well. I look at other issues and nothing seems to help me.

    Plugin Support Paal Joachim Romdahl

    (@paaljoachim)

    Hi @wball1

    Could you please create an issue here?
    https://github.com/WordPress/gutenberg/issues/new?template=Bug_report.md
    Filling out the report would really help us narrow down what is going on.

    Thanks!

    Hello,

    So glad to have found this thread. I’ve been experiencing a LOT of issues with the block editor – WITH pages BUILT with the block editor. Just yesterday I went to edit a page for the company that I work for – a very simple page with the “media block” and the block asks me to try to resolve it – “attempt block recovery”, and then it doesn’t resolve.

    I understand this was built in order to provide a ‘simpler interface” for those that do not have backend experience but I find it counterintuitive. In order for me to ‘fix’ a page with errors I would have to learn the syntax the builder is using.. it’s maddening.

    Honestly, I try to avoid using it for these reasons. It doesn’t seem ready to have been set out into the wild when it is so buggy.

    Screenshot: https://tabledesigns.com/images/ERRORS%20-%20BLOCK%20EDITOR!.jpg

    Plugin Support Paal Joachim Romdahl

    (@paaljoachim)

    Hi @tabledesigns

    Please fill out a bugs/error report here so that we can understand what is going on. https://github.com/WordPress/gutenberg/issues/new/choose

    Thanks.

    Thank you Paal,

    I filled it out – may seem short but it’s the best I can do.

    Plugin Support Paal Joachim Romdahl

    (@paaljoachim)

    Great! I also replied tabledesigns!
    The important part is letting us know the steps you took to get to a certain place. I replied in the issue.

    I will also close this issue.

    I don’t understand why you would close it if it isn’t resolved.

    I responded to your email but just as an FYI, whenever one comes to support with an issue – there are always too many threads where you FIND your issue, but it is closed without being resolved. (shrug) THAT seems counterproductive doesn’t it?? THEN you have to open a new post with the same issue. WHY?

    • This reply was modified 3 years, 9 months ago by tabledesigns.
    Plugin Support Paal Joachim Romdahl

    (@paaljoachim)

    I have reopened this thread.

    Going through.
    Has the issue been solved for you @drtonyb ? Through the issues Anne linked to on Github.

    @tabledesigns We need to separate the threads. Keeping one issue in one thread. The issue you have is instead moved to Github. Where it will be followed up there.
    (As long as we can replicate the issue you had then it can be fixed. Which means we need to understand the steps you took to the end result.)

Viewing 15 replies - 1 through 15 (of 24 total)
  • The topic ‘Gutenberg widgets block editor is a mess of errors’ is closed to new replies.