[wp-trac] [WordPress Trac] #51913: Potential `unsupported operand types` dashboard fatal on PHP8 + multisite + upload space check

WordPress Trac noreply at wordpress.org
Thu Dec 3 17:37:59 UTC 2020


#51913: Potential `unsupported operand types` dashboard fatal on PHP8 + multisite +
upload space check
-------------------------------------+-------------------------------------
 Reporter:  iandunn                  |       Owner:  iandunn
     Type:  defect (bug)             |      Status:  accepted
 Priority:  highest omg bbq          |   Milestone:  5.6
Component:  Administration           |     Version:  trunk
 Severity:  blocker                  |  Resolution:
 Keywords:  php8 has-patch needs-    |     Focuses:  administration,
  testing                            |  multisite
-------------------------------------+-------------------------------------
Changes (by iandunn):

 * keywords:  php8 has-patch => php8 has-patch needs-testing
 * version:   => trunk


Comment:

 I think the PR is settled and ready for testing.

 Reproducing is a bit of work, since there are some specific preconditions:

 * PHP 8
 * multisite
 * custom `WP_CONTENT_DIR` that's not a child of WP's `ABSPATH` folder
 (e.g., like [https://roots.io/bedrock/ Bedrock])
 * `upload_space_check_disabled` option = `0`

 Steps:

 * install latest 5.5
 * delete the `dirsize_cache` transient
 * visit `wp-admin/index.php`. it should work fine, and the transient
 should be populated.
 * upgrade to 5.6-RC2. if you now visit `wp-admin/index.php` you should see
 a fatal error inside the At A Glance widget
 * if you then apply https://github.com/WordPress/wordpress-
 develop/pull/783.diff and refresh, the fatal should go away, and you
 should see the correct size calculation in that widget.

 testing the PR under PHP 7 + single site is helpful too, to make sure it
 doesn't have any unintended side-effects

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/51913#comment:17>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list