• Resolved ibazzano

    (@ibazzano)


    Updating woocommerce to 10.0.2 breaks the site due to lack of compatibility with this plugin, here’s the PHP logs for reference:

    FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught Error: Call to undefined method WooCommerce::get_attribute_taxonomies() in /var/www/vhosts/SITE.com/httpdocs/wp-content/plugins/woocommerce-colororimage-variation-select/classes/class_attribute_global_values.php:32

    Stack trace:

    #0 /var/www/vhosts/SITE.com/httpdocs/wp-includes/class-wp-hook.php(324): wcva_global_values_per_attribute->wcva_setup_texonomy_based_fields()

    #1 /var/www/vhosts/SITE.com/httpdocs/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()

    #2 /var/www/vhosts/SITE.com/httpdocs/wp-includes/plugin.php(517): WP_Hook->do_action()

    #3 /var/www/vhosts/SITE.com/httpdocs/wp-admin/admin.php(176): do_action()

    #4 /var/www/vhosts/SITE.com/httpdocs/wp-admin/index.php(10): require_once('...')

    #5 {main}

    thrown in /var/www/vhosts/SITE.com/httpdocs/wp-content/plugins/woocommerce-colororimage-variation-select/classes/class_attribute_global_values.php on line 32" while reading response header from upstream

Viewing 3 replies - 1 through 3 (of 3 total)
  • That’s for another plugin WooSwatches – Woocommerce Color or Image Variation Swatches, but it looks like that plugin is not available anymore. I guess we have to replace it..

    Noah Hearle

    (@designextreme)

    I fixed this error, just removing the old WooCommerce check and replacing it with a direct call. The version check is flawed should be removed.

    Around line 32, for this file in the plugins directory: /woocommerce-colororimage-variation-select/includes/class_attribute_global_values.php, perform the edit:

    Before:

                if ($woo_version <2.1) {
    $createdattributes = $woocommerce->get_attribute_taxonomies();
    } else {
    $createdattributes=wc_get_attribute_taxonomies();
    }

    After:

             $createdattributes=wc_get_attribute_taxonomies();

    I hope this is patched, otherwise this plugin will need to be removed from the directory.

    Thread Starter ibazzano

    (@ibazzano)

    Yes! That worked perfectly, one minor note, the file to be edited is in this path (not includes, but classes):

    /wp-content/plugins/woocommerce-colororimage-variation-select/classes/class_attribute_global_values.php

    With this minor update the site successfully updated to 10.0.4

    Do you know if there a GIT repo for the plugin where we can add this change and make a compatible release, so it doesn’t deprecate for everyone?

    Thanks for the help Noah!

Viewing 3 replies - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.