• Paul

    (@headwall)


    Hi

    Version 1.8.12 breaks WP CLI cron (PHP 8.5), so that wp cron run --due-now returns the following:

    PHP Fatal error:  Uncaught TypeError: array_filter(): Argument #1 ($array) must be of type array, null given in /web/wp-content/plugins/eas-eu-compliance/EAScompliance.php:1209
    Stack trace:
    #0 /web/wp-content/plugins/eas-eu-compliance/EAScompliance.php(1209): array_filter()
    #1 /web/wp-content/plugins/eas-eu-compliance/EAScompliance.php(452): eascompliance_log()
    #2 /web/wp-includes/class-wp-hook.php(353): eascompliance_plugin_upgrade()
    #3 /web/wp-includes/class-wp-hook.php(377): WP_Hook->apply_filters()
    #4 /web/wp-includes/plugin.php(523): WP_Hook->do_action()
    #5 /web/wp-settings.php(630): do_action()
    #6 phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(1374): require('...')
    #7 phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(1293): WP_CLI\Runner->load_wordpress()
    #8 phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/LaunchRunner.php(28): WP_CLI\Runner->start()
    #9 phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/bootstrap.php(84): WP_CLI\Bootstrap\LaunchRunner->process()
    #10 phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/wp-cli.php(35): WP_CLI\bootstrap()
    #11 phar:///usr/local/bin/wp/php/boot-phar.php(20): include('...')
    #12 /usr/local/bin/wp(4): include('...')
    #13 {main}

    The problem on line 1209 in EAScompliance.php is that $eascompliance_blackbox is fed into array_filter() even when it’s null. Either $eascompliance_blackbox needs to be properly initialised, or there needs to be an is_array() wrapped around the code that clears records older than 1 hour.

    For now, we’ve rolled-back the site to 1.8.10 so the site can function again (cron).

    Paul

You must be logged in to reply to this topic.