• I have a client who has been importing new products to her website for a while using CSV files, and all has been well.

    However, since upgrading her WooCommerce to v4.3.0, her imports have started creating new top-level categories rather than assigning products to subcategories of the same name that already exist.

    I have been able to reproduce this behaviour precisely:

    I used the same CSV files as she did, and upgraded my plugin at the same point. Prior to upgrading the plugin, I was using v4.2.2, and I had a category called Children and a subcategory of this called Children’s Fiction. I was able to upload products with the category column containing “Children’s Fiction” and newly imported products were added to this subcategory.

    Then I upgraded my WooCommerce plugin to v4.3.1 (the client actually had v4.3.0, but by the time I got to this stage in my testing, v4.3.0 had been superseded by v4.3.1).

    I then imported the client’s latest import CSV file and, just as my client had experienced, my WooCommerce site added a top-level category of Children’s Fiction, rather than assigning the products to the pre-existing subcategory, Children/Children’s Fiction.

    Has anyone else experienced this change in behaviour between v4.3.0 and its predecessors?

    Thanks,
    Paul Cutcliffe

Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter PaulCutcliffe

    (@paulcutcliffe)

    Here is the system report for my test environment on which I’ve reproduced the client’s issue:

    
    ### WordPress Environment ###
    
    WordPress address (URL): https://bookseller.spicewebdesign.com
    Site address (URL): https://bookseller.spicewebdesign.com
    WC Version: 4.3.1
    REST API Version: ? 1.0.10
    WC Blocks Version: ? 2.7.2
    Action Scheduler Version: ? 3.1.6
    WC Admin Version: ? 1.3.1
    Log Directory Writable: ?
    WP Version: 5.4.2
    WP Multisite: –
    WP Memory Limit: 256 MB
    WP Debug Mode: –
    WP Cron: ?
    Language: en_GB
    External object cache: –
    
    ### Server Environment ###
    
    Server Info: Apache
    PHP Version: 7.3.3
    PHP Post Max Size: 100 MB
    PHP Time Limit: 60
    PHP Max Input Vars: 1000
    cURL Version: 7.61.0
    OpenSSL/1.0.2p
    
    SUHOSIN Installed: –
    MySQL Version: 5.5.5-10.2.22-MariaDB-log
    Max Upload Size: 100 MB
    Default Timezone is UTC: ?
    fsockopen/cURL: ?
    SoapClient: ?
    DOMDocument: ?
    GZip: ?
    Multibyte String: ?
    Remote Post: ?
    Remote Get: ?
    
    ### Database ###
    
    WC Database Version: 4.3.1
    WC Database Prefix: cfuy_
    Total Database Size: 17.98MB
    Database Data Size: 13.88MB
    Database Index Size: 4.10MB
    cfuy_woocommerce_sessions: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_woocommerce_api_keys: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_woocommerce_attribute_taxonomies: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_woocommerce_downloadable_product_permissions: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
    cfuy_woocommerce_order_items: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_woocommerce_order_itemmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_woocommerce_tax_rates: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
    cfuy_woocommerce_tax_rate_locations: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_woocommerce_shipping_zones: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
    cfuy_woocommerce_shipping_zone_locations: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_woocommerce_shipping_zone_methods: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
    cfuy_woocommerce_payment_tokens: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_woocommerce_payment_tokenmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_woocommerce_log: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_actionscheduler_actions: Data: 0.02MB + Index: 0.11MB + Engine InnoDB
    cfuy_actionscheduler_claims: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_actionscheduler_groups: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_actionscheduler_logs: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_commentmeta: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
    cfuy_comments: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
    cfuy_links: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
    cfuy_options: Data: 5.68MB + Index: 0.37MB + Engine MyISAM
    cfuy_postmeta: Data: 4.97MB + Index: 1.73MB + Engine MyISAM
    cfuy_posts: Data: 1.30MB + Index: 0.48MB + Engine MyISAM
    cfuy_termmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_terms: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
    cfuy_term_relationships: Data: 0.08MB + Index: 0.16MB + Engine MyISAM
    cfuy_term_taxonomy: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
    cfuy_usermeta: Data: 1.01MB + Index: 0.01MB + Engine MyISAM
    cfuy_users: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
    cfuy_wc_admin_notes: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
    cfuy_wc_admin_note_actions: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_wc_category_lookup: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
    cfuy_wc_customer_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_wc_download_log: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_wc_order_coupon_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_wc_order_product_lookup: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
    cfuy_wc_order_stats: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
    cfuy_wc_order_tax_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
    cfuy_wc_product_meta_lookup: Data: 0.22MB + Index: 0.44MB + Engine InnoDB
    cfuy_wc_reserved_stock: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
    cfuy_wc_tax_rate_classes: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    cfuy_wc_webhooks: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
    
    ### Post Type Counts ###
    
    attachment: 2082
    page: 8
    post: 2
    product: 2080
    revision: 13
    shop_order: 2
    
    ### Security ###
    
    Secure connection (HTTPS): ?
    					Your store is not using HTTPS. Learn more about HTTPS and SSL Certificates.
    Hide errors from visitors: ?
    
    ### Active Plugins (4) ###
    
    Jetpack by WordPress.com: by Automattic – 8.7.1
    Limit Login Attempts: by Johan Eenfeldt – 1.7.1
    WooCommerce Services: by Automattic – 1.23.2 – Installed version not tested with active version of WooCommerce 4.3.1
    WooCommerce: by Automattic – 4.3.1
    
    ### Inactive Plugins (2) ###
    
    Akismet Anti-Spam: by Automattic – 4.1.6
    Hello Dolly: by Matt Mullenweg – 1.7.2
    
    ### Settings ###
    
    API Enabled: –
    Force SSL: –
    Currency: GBP (£)
    Currency Position: left
    Thousand Separator: ,
    Decimal Separator: .
    Number of Decimals: 2
    Taxonomies: Product Types: external (external)
    grouped (grouped)
    simple (simple)
    variable (variable)
    
    Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog)
    exclude-from-search (exclude-from-search)
    featured (featured)
    outofstock (outofstock)
    rated-1 (rated-1)
    rated-2 (rated-2)
    rated-3 (rated-3)
    rated-4 (rated-4)
    rated-5 (rated-5)
    
    Connected to WooCommerce.com: –
    
    ### WC Pages ###
    
    Shop base: #6 - /shop/
    Basket: #7 - /basket/
    Checkout: #8 - /checkout/
    My account: #9 - /my-account/
    Terms and conditions: #33 - /terms-and-conditions/
    
    ### Theme ###
    
    Name: Storefront
    Version: 2.5.8
    Author URL: https://woocommerce.com/
    Child Theme: ? – If you are modifying WooCommerce on a parent theme that you did not build
    personally we recommend using a child theme. See: How to create a child theme
    
    WooCommerce Support: ?
    
    ### Templates ###
    
    Overrides: –
    
    ### Action Scheduler ###
    
    Complete: 4
    Oldest: 2020-07-14 18:26:35 +0000
    Newest: 2020-07-24 09:00:38 +0000
    
    
    Plugin Contributor Niels Lange

    (@nielslange)

    Hello @paulcutcliffe,

    This problem had been reported a few times before. Would you mind trying the approach as described in https://www.ads-software.com/support/topic/csv-import-category-issue/#post-10448484 to see if that solves the problem that you are currently facing?

    Thread Starter PaulCutcliffe

    (@paulcutcliffe)

    Hi @nielslange

    Thanks for your suggestion – I will read the other post and see if there’s anything useful we can apply to our situation.

    I’ll post my findings back here.

    Paul Cutcliffe

    • This reply was modified 4 years, 7 months ago by PaulCutcliffe.
    Plugin Contributor Niels Lange

    (@nielslange)

    That sounds like a great plan, @paulcutcliffe.

    Thread Starter PaulCutcliffe

    (@paulcutcliffe)

    Having now looked more carefully at the other issue you mentioned, I don’t think it’s quite the same as ours.

    The other issue was where the user was hoping that the importer would create a new, top-level category but it actually found and used a subcategory of the same name instead.

    Our situation is pretty much the exact opposite – we have a subcategory which we hope the importer will find and assign products to but it actually just creates a new top-level category instead.

    Remember, our situation is also slightly different because WooCommerce and its importer, at least prior to v4.3.0, did exactly what we wanted. Then, along came v4.3.0 and the behaviour changed. I wouldn’t mind betting that a fix applied in v4.3.0 has caused this change in behaviour:

    • Remove check for the existing term when parsing category via CSV & instead catch an existing term error when adding a new category to the database. #26720

    If the importer is now using a completely different method to identify existing terms in the category list, then it seems likely that this ‘fix’ has caused the change in behaviour.

    Does anyone know what should happen if my hypothesis is correct?

    Thread Starter PaulCutcliffe

    (@paulcutcliffe)

    Is there really nobody else who has experienced this issue? It seems to me to be really likely to be due to a bug in v4.3.0 relating to how categories and subcategories are handled during an import, as I have two installations that behaved perfectly before this update and no longer behave as expected following it.

    More importantly, how do we fix it?

    Thanks.

    I’m experiencing the same issues. Working with hundreads of categories, this seem to be a huge problem.

    Thread Starter PaulCutcliffe

    (@paulcutcliffe)

    Ah, that’s good. Well, sorry – it’s not good for you, of course! But I mean at least now it’s not just me!

    I’m shocked that this issue not more widely complained about, given the number of WooCommerce website out there.

    Hopefully, they’ll fix it soon – I keep seeing updates and hoping, but nothing yet… ??

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘WooCommerce Creates New Categories Rather Than Using Existing Ones Since v4.3.0’ is closed to new replies.