Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WordPress 5.8: Fatal erroring on new Admin > Widgets page #227

Closed
JJJ opened this issue Jul 22, 2021 · 4 comments
Closed

WordPress 5.8: Fatal erroring on new Admin > Widgets page #227

JJJ opened this issue Jul 22, 2021 · 4 comments
Assignees
Labels
component-admin Admin-area code component-widgets Widgets code scope-back-compat General backwards compatibility code type-bug
Milestone

Comments

@JJJ
Copy link
Contributor

JJJ commented Jul 22, 2021

Because it got rammed through in the last minute, as is tradition, the WordPress 5.8 widgets screen is causing a fatal error due to the way Sugar Calendar registers (and now tries to preview) its widgets.

Details TBD.

jjj-on-2021-07-21-at-19-39-26@2x

@JJJ JJJ self-assigned this Jul 22, 2021
@JJJ JJJ added this to the 2.2.3 milestone Jul 22, 2021
@JJJ JJJ added component-admin Admin-area code component-widgets Widgets code scope-back-compat General backwards compatibility code type-bug labels Jul 22, 2021
@JJJ
Copy link
Contributor Author

JJJ commented Jul 22, 2021

jjj-on-2021-07-21-at-19-49-06@2x

😡

@spencerfinnell
Copy link
Contributor

Maybe related: WordPress/gutenberg#33443

@JJJ
Copy link
Contributor Author

JJJ commented Jul 22, 2021

Thanks @spencerfinnell for the research there. Much appreciated.

Sugar Calendar is affected by this because it uses an is_admin() check to avoid including a few Legacy PHP files that have functions in them that were never intended to be called inside of WordPress Admin.

On the new Widgets page, it's partially live-previewing widget areas but with WP_ADMIN set and WP_USE_THEMES null, so the theme-side output functions in Sugar Calendar aren't available.

The easiest fix on our end is to always include everything. Gonna put together a PR with that for 2.2.3, and test with older WordPress versions to be safe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component-admin Admin-area code component-widgets Widgets code scope-back-compat General backwards compatibility code type-bug
Projects
None yet
Development

No branches or pull requests

2 participants