• Hi,

    Loading Sendcloud Shipping 1.0.29 causes a site-wide fatal error on WordPress 7.0. The plugin’s 1.0.29 database migration calls get_user_by() while it runs, and on WP 7.0 that function isn’t available yet at that stage of the load process, so PHP throws an uncaught error. Because it happens during plugin bootstrap (before admin is loaded), it takes down both the front-end and wp-admin and triggers WordPress recovery mode. Deactivating the plugin restores the site immediately.

    Environment

    • WordPress: 7.0
    • WooCommerce: 10.9.1
    • Sendcloud Shipping: 1.0.29
    • PHP: 8.3.31
    • Web server: OpenLiteSpeed (LSPHP 8.3)

    Error and stack trace:

    Uncaught Error: Call to undefined function get_user_by() in
    .../plugins/sendcloud-connected-shipping/database/Migrations/migration.v.1.0.29.php:46
    
    #0 migration.v.1.0.29.php(21): ...\Migration_1_0_29->fix_sendcloud_user_email()
    #1 class-migrator.php(47): ...\Migration_1_0_29->execute()
    #2 includes/Utility/class-database.php(94): ...\SCCSP_Migrator->execute()
    #3 includes/Utility/class-database.php(34): ...\SCCSP_Database->do_update()
    #4 includes/class-sendcloud.php(166): ...\SCCSP_Database->update()
    #5 includes/class-sendcloud.php(130): ...\SCCSP_Sendcloud->initialize()
    #6 sendcloud-connected-shipping.php(42): ...\SCCSP_Sendcloud::init()
    #7 wp-settings.php(589): include_once('.../sendcloud-connected-shipping.php')

    Possible cause:

    The migration (fix_sendcloud_user_email()) runs synchronously during plugin load — SCCSP_Sendcloud::init() is called directly from the main plugin file (line 42), which executes the migrator while the plugin file is still being include_once‘d in wp-settings.php. At that point on WP 7.0, get_user_by() isn’t loaded yet.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)

You must be logged in to reply to this topic.