• Resolved titsmaker

    (@titsmaker)


    Hi and thank you for your hard work.
    As PHP 8.0 asctive support will be stopped in less than half a year maybe it’s time to improve your plugin PHP 8.1 compatibility.
    There are no major issues but some deprecation notices are thrown. Here they are:

    PHP Deprecated:  version_compare(): Passing null to parameter #1 ($version1) of type string is deprecated in \wp-content\plugins\disable-dashboard-for-woocommerce\includes\functions\disable-bloat-functions_free.php on line 101
    PHP Deprecated:  Return type of FS_Key_Value_Storage::offsetExists($k) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in \wp-content\plugins\disable-dashboard-for-woocommerce\includes\freemius\includes\managers\class-fs-key-value-storage.php on line 309
    PHP Deprecated:  Return type of FS_Key_Value_Storage::offsetGet($k) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in \wp-content\plugins\disable-dashboard-for-woocommerce\includes\freemius\includes\managers\class-fs-key-value-storage.php on line 317
    PHP Deprecated:  Return type of FS_Key_Value_Storage::offsetSet($k, $v) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in \wp-content\plugins\disable-dashboard-for-woocommerce\includes\freemius\includes\managers\class-fs-key-value-storage.php on line 301

    And many more notices all related to the same file (class-fs-key-value-storage.php)

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Author Disable Bloat

    (@disablebloat)

    Hello @titsmaker

    Thank you for reporting this. You are right, the plugin may still give some deprecation notices (which are not errors) on some PHP 8.X versions.

    Please give me a couple of days to prepare a fix. It is going to be fixed in the upcoming release. Stay tuned!

    Plugin Author Disable Bloat

    (@disablebloat)

    Dear @titsmaker

    This has been fixed in 3.0.3. Please update the plugin to the latest version.

    Please let me know if this fix resolves the issue.

    @disablebloat in version 3.0.3, I am still seeing the following 8.1 notice:

    >PHP Deprecated: version_compare(): Passing null to parameter #1 ($version1) of type string is deprecated in /app/wp-content/plugins/disable-dashboard-for-woocommerce/includes/functions/disable-bloat-functions_free.php on line 102

    Plugin Author Disable Bloat

    (@disablebloat)

    Hello @helgatheviking

    Could you please generate WooCommerce System Report and paste it into this thread?
    https://woocommerce.com/document/understanding-the-woocommerce-system-status-report/

    We will try to replicate this issue and prepare a fix in the upcoming release.

    Truncated SSR since only the PHP version is relevant. Notice is displayed when visiting the wp-admin. Its a developmental site so I don’t care, but wanted to relay this.

    ### Server Environment ###
    
    Server Info: nginx/1.17.10
    PHP Version: 8.1.6
    PHP Post Max Size: 100 MB
    PHP Time Limit: 90
    PHP Max Input Vars: 10000
    cURL Version: 7.74.0
    OpenSSL/1.1.1n
    
    SUHOSIN Installed: –
    MySQL Version: 10.3.27-MariaDB
    Max Upload Size: 100 MB
    Default Timezone is UTC: ?
    fsockopen/cURL: ?
    SoapClient: ?
    DOMDocument: ?
    GZip: ?
    Multibyte String: ?
    Remote Post: ?
    Remote Get: ?

    Can reproduce with only WooCommerce (dev repo) and Disable bloat active.
    Disable Bloat for WordPress & WooCommerce: by Disable Bloat – 3.0.3

    Plugin Author Disable Bloat

    (@disablebloat)

    @helgatheviking

    Thank you for posting the system report. I will let you know as soon as the update is ready for download.

    Plugin Author Disable Bloat

    (@disablebloat)

    Dear @helgatheviking

    Could you please paste your System Report including the WooCommerce version?
    I think that the way Woo team writes version number to the dev package might be the case here.

    pretty sure i’ve updated Woo since posting… pulled latest from their github the other day.

    
    ### WordPress Environment ###
    
    WordPress address (URL): https://sandbox.lndo.site
    Site address (URL): https://sandbox.lndo.site
    WC Version: 6.6.0
    REST API Version: ? 6.6.0
    WC Blocks Version: ? 7.6.0
    Action Scheduler Version: ? 3.4.0
    Log Directory Writable: ?
    WP Version: 6.0.1
    WP Multisite: –
    WP Memory Limit: 1 GB
    WP Debug Mode: ?
    WP Cron: ?
    Language: en_US
    External object cache: –
    
    ### Server Environment ###
    
    Server Info: nginx/1.17.10
    PHP Version: 8.1.6
    PHP Post Max Size: 100 MB
    PHP Time Limit: 90
    PHP Max Input Vars: 10000
    cURL Version: 7.74.0
    OpenSSL/1.1.1n
    
    SUHOSIN Installed: –
    MySQL Version: 10.3.27-MariaDB
    Max Upload Size: 100 MB
    Default Timezone is UTC: ?
    fsockopen/cURL: ?
    SoapClient: ?
    DOMDocument: ?
    GZip: ?
    Multibyte String: ?
    Remote Post: ?
    Remote Get: ?
    
    
    Plugin Author Disable Bloat

    (@disablebloat)

    @helgatheviking

    Now I think I know what might be causing this issue. It’s an edge case that only shows up if you are using dev versions of WooCommerce. It will be fixed in the upcoming update. Please stay tuned!

    Ankit

    (@androasingh)

    Getting Deprecated code Error still in version 3.0.3

    version_compare(): Passing null to parameter #1 ($version1) of type string is deprecated.

    wp-content/plugins/disable-dashboard-for-woocommerce/includes/functions/disable-bloat-functions_free.php:102
    version_compare()
    wp-content/plugins/disable-dashboard-for-woocommerce/includes/functions/disable-bloat-functions_free.php:102
    Disable_WC_Bloat->includes()
    wp-content/plugins/disable-dashboard-for-woocommerce/disable-dashboard-for-woocommerce.php:125
    Disable_WC_Bloat->__construct()
    wp-content/plugins/disable-dashboard-for-woocommerce/disable-dashboard-for-woocommerce.php:115
    Disable_WC_Bloat::instance()
    wp-content/plugins/disable-dashboard-for-woocommerce/disable-dashboard-for-woocommerce.php:194
    disable_woocommerce_bloat()
    wp-content/plugins/disable-dashboard-for-woocommerce/disable-dashboard-for-woocommerce.php:198
    Thread Starter titsmaker

    (@titsmaker)

    Hi and thank you for maintaining plugin’s code. I am still getting following message and I am not using devversion of WC:
    Deprecated: version_compare(): Passing null to parameter #1 ($version1) of type string is deprecated in?\wp-content\plugins\disable-dashboard-for-woocommerce\includes\functions\disable-bloat-functions_free.php?on line?102

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Deprecation notices on PHP 8.1’ is closed to new replies.