Prevent attributes from being overwritten during Product Set updates
If you are importing taxonomy-based attributes such as color or size or gender during your Product Set imports and do not want those values overwritten when your Product Set updates the products in its set, you'll need to add a little extra code.
This is useful if you edit product attribute information after a product has been imported by the Product Set.
What is a taxonomy-based attribute?
Taxonomy-based attributes are WooCommerce attributes that you have added here: WordPress Admin Area > Products > Attributes
Here's how to prevent your attributes from being overwritten during Product Set updates.
Create a custom plugin
If you haven't done so already, create a custom plugin.
Add custom code
Add the following custom code to your custom plugin:
Add your attribute slugs
In our example code above, we are preventing the attributes color and size from being overwritten. You can add to, remove from or modify this list of attributes. You can find your attribute slugs here: WordPress Admin Area > Products > Attributes
Save your custom plugin file.
Now the next time your Product Set updates, those products which already have the color and size attributes will not have their attribute values changed.