I am trying to: create or edit then save WooCommerce Product variations
Link to a page where the issue can be seen:
Editing any variable product
I expected to see:
The variation values saved and control returned to the editor.
Instead, I got:
The spinner keeps spinning forever and the editor never gets back control of the editing page. The data does appear to save behind the scenes but you have to refresh the page before you can do anything else.
Disabling Toolset Blocks solves the problem but breaks many other parts of the site that depend on Toolset.
Hello. Thank you for contacting the Toolset support.
Toolset forms have limited support for add/edit products, having said that you can create forms to add/edit "Simple Products" and "External/Affiliate" products.
You cannot create Toolset forms for Variable and Grouped products.
Maybe I wasn't clear. I am not using Toolset Forms. Toolset Blocks seems to be breaking the ability to save variations when editing with the normal WooCommerce product editing process.
I used the Check Conflicts plugin to reduce the number of active plugins to just the essentials and the only thing that made a difference was Toolset Blocks being on or off. I disabled everything except WooCommerce, WooCommerce PayPal Payments, Toolset Types, and Toolset Blocks.
Here is a sandbox site and you can auto-login to it using the following link:
- hidden link
Are you able to reproduce the issue with the above sandbox site? if yes:
- Can you please share exact steps I will require to follow that should help me to reproduce the issue.
I cannot reproduce it on your sandbox site. On our site, editing any aspect of a variation and trying to save it results in the endless spinner and the following error. Because the error mentions the toolset cache I tried clearing the custom fields cache with no change. Note that this site does not use Toolset WooCommerce Blocks. It uses Types and Blocks for other things but WooCommerce is not using Toolset.
[31-Mar-2025 13:42:45 UTC] PHP Fatal error: Uncaught TypeError: array_intersect(): Argument #1 ($array) must be of type array, string given in /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/application/controllers/cache/views/invalidator.php:274
Stack trace:
#0 /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/application/controllers/cache/views/invalidator.php(274): array_intersect()
#1 /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/application/controllers/cache/views/invalidator.php(217): OTGS\Toolset\Views\Controller\Cache\Views\Invalidator->invalidate_cache_per_domain()
#2 /home/thewebsite/public_html/wp-includes/class-wp-hook.php(324): OTGS\Toolset\Views\Controller\Cache\Views\Invalidator->should_invalidate_cache()
#3 /home/thewebsite/public_html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
#4 /home/thewebsite/public_html/wp-includes/plugin.php(517): WP_Hook->do_action()
#5 /home/thewebsite/public_html/wp-includes/load.php(1279): do_action()
#6 [internal function]: shutdown_action_hook()
#7 {main}
thrown in /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/application/controllers/cache/views/invalidator.php on line 274
[31-Mar-2025 13:42:46 UTC] PHP Deprecated: Creation of dynamic property Toolset_Theme_Integration_Settings_Post_Edit_Controller::$is_blocks_active is deprecated in /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/vendor/toolset/toolset-theme-settings/compatibility-modules/controllers/toolset-theme-integration-settings-abstract-controller.php on line 56
[31-Mar-2025 13:42:47 UTC] PHP Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /home/thewebsite/public_html/wp-content/plugins/types/vendor/toolset/types/embedded/admin.php on line 167
[31-Mar-2025 13:42:47 UTC] PHP Fatal error: Uncaught TypeError: array_intersect(): Argument #1 ($array) must be of type array, string given in /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/application/controllers/cache/views/invalidator.php:274
Stack trace:
#0 /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/application/controllers/cache/views/invalidator.php(274): array_intersect()
#1 /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/application/controllers/cache/views/invalidator.php(217): OTGS\Toolset\Views\Controller\Cache\Views\Invalidator->invalidate_cache_per_domain()
#2 /home/thewebsite/public_html/wp-includes/class-wp-hook.php(324): OTGS\Toolset\Views\Controller\Cache\Views\Invalidator->should_invalidate_cache()
#3 /home/thewebsite/public_html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
#4 /home/thewebsite/public_html/wp-includes/plugin.php(517): WP_Hook->do_action()
#5 /home/thewebsite/public_html/wp-includes/load.php(1279): do_action()
#6 [internal function]: shutdown_action_hook()
#7 {main}
thrown in /home/thewebsite/public_html/wp-content/plugins/toolset-blocks/application/controllers/cache/views/invalidator.php on line 274
Are you using view on that page? if yes, is it a block view or legacy view and what is the view ID or view name?
*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.
I have set the next reply to private which means only you and I have access to it.
I copied the site to a testing server and the problem does not happen on the testing server. One was PHP 8.1 and the other PHP 8.2 but I matched them and the problem still didn't happen on the testing server. I replaced all the core WordPress files on the live site with a fresh copy and the problem still happens on the live site.
I can't let you do extensive testing on the live site as it is actively used. I am going to do some more digging and ask the hosting provider for some help to see if I can find the problem. I will update this ticket when I know more.