Make WordPress Core

Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#45483 closed defect (bug) (fixed)

Post edit and Add New Plugin pages have PHP notices in 7.3.

Reported by: desrosj's profile desrosj Owned by: desrosj's profile desrosj
Milestone: 5.0.2 Priority: normal
Severity: normal Version:
Component: Administration Keywords: has-patch php73 fixed-5.0
Focuses: Cc:

Description

The post edit pages (wp-admin/edit.php) and Add New Plugin pages have PHP notices in PHP 7.3.

These are caused by missing variables when compact() is called in wp_edit_posts_query() and install_plugin_install_status().

Related: #44416.

Attachments (1)

45483.diff (1.3 KB) - added by desrosj 6 years ago.

Download all attachments as: .zip

Change History (12)

@desrosj
6 years ago

#1 @DrewAPicture
6 years ago

Seems like this should ship with 5.0 considering PHP 7.3 compat is a headline feature. @pento thoughts?

Last edited 6 years ago by DrewAPicture (previous) (diff)

#3 @ocean90
6 years ago

#45523 was marked as a duplicate.

#4 @ocean90
6 years ago

#45587 was marked as a duplicate.

#6 @pento
6 years ago

  • Milestone changed from 5.0.1 to 5.0.2

#7 @desrosj
6 years ago

  • Owner set to desrosj
  • Resolution set to fixed
  • Status changed from new to closed

In 44185:

PHP 7.3 Compatibility: Fix compact related notices.

In PHP 7.3, the compact() function has been changed to issue an E_NOTICE level error if a passed string refers to an unset variable. In previous versions of PHP, this notice was silently skipped. This fixes a few more instances of unset variables in the WordPress admin.

The full RFC can be viewed here: https://wiki.php.net/rfc/compact.

See #44416.
Fixes #45483.

#8 @desrosj
6 years ago

  • Keywords fixed-5.0 added
  • Resolution fixed deleted
  • Status changed from closed to reopened

Reopening for merge into trunk.

#9 @desrosj
6 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In 44297:

PHP 7.3 Compatibility: Fix compact related notices.

In PHP 7.3, the compact() function has been changed to issue an E_NOTICE level error if a passed string refers to an unset variable. In previous versions of PHP, this notice was silently skipped. This fixes a few more instances of unset variables in the WordPress admin.

The full RFC can be viewed here: https://wiki.php.net/rfc/compact.

See #44416.

Merges [44185] into trunk.

Fixes #45483.

#10 @pcarvalho
6 years ago

this won't be merged to 4.9.x?

don't really understand the info here:
https://core.trac.wordpress.org/changeset/44297

Property svn:mergeinfo changed
/branches/5.0	merged: 44185	

should this have something like?

/branches/3.1	merged	eligible
/branches/3.3	merged	eligible
/branches/3.4	merged	eligible
/branches/4.9	merged	eligible
/branches/5.0	merged	eligible

This ticket was mentioned in Slack in #core by pcarvalho. View the logs.


6 years ago

Note: See TracTickets for help on using tickets.