[wp-trac] [WordPress Trac] #61114: PHP 8+ Fatal Error in WP_Upgrader due to TypeError in array_keys() Call
WordPress Trac
noreply at wordpress.org
Thu Oct 10 18:33:03 UTC 2024
#61114: PHP 8+ Fatal Error in WP_Upgrader due to TypeError in array_keys() Call
-----------------------------+------------------------------
Reporter: verygoode | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Upgrade/Install | Version: 2.8
Severity: normal | Resolution:
Keywords: needs-patch | Focuses:
-----------------------------+------------------------------
Comment (by lifelightweb):
I believe all of my servers have started having issues that are related to
this bug report. My servers are all on PHP8.1 and WordPress 6.6.2. When
there is more than 1 plugin that needs an update, the problems arise.
The log file shows this:
------------
[10-Oct-2024 17:36:58 UTC] PHP Warning:
file_get_contents(/.../public_html/wp-content/plugins/wps-hide-login/wps-
hide-login.php): Failed to open stream: No such file or directory in
/.../public_html/wp-includes/functions.php on line 6864
[10-Oct-2024 17:36:58 UTC] PHP Fatal error: Uncaught TypeError:
array_keys(): Argument #1 ($array) must be of type array, bool given in
/.../public_html/wp-admin/includes/class-wp-upgrader.php:607
Stack trace:
#0 /.../public_html/wp-admin/includes/class-wp-upgrader.php(607):
array_keys(false)
#1 /.../public_html/wp-admin/includes/class-wp-upgrader.php(887):
WP_Upgrader->install_package(Array)
#2 /.../public_html/wp-admin/includes/class-plugin-upgrader.php(237):
WP_Upgrader->run(Array)
#3 /.../public_html/wp-admin/update.php(74): Plugin_Upgrader->upgrade
('wps-hide-login/...')
#4 {main}
thrown in /.../public_html/wp-admin/includes/class-wp-upgrader.php on
line 607
[10-Oct-2024 17:36:59 UTC] PHP Warning: Trying to access array offset on
value of type bool in /.../public_html/wp-admin/includes/ajax-actions.php
on line 4681
Is there a work-around I can employ to get past this?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/61114#comment:10>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list