[Resolved] Product stock synchronization issue across translations
This thread is resolved. Here is a description of the problem and solution.
Problem: The client is experiencing an issue where the stock levels are not synchronizing correctly between the default language (Dutch) and the translated versions (English, German, French) of products on their WooCommerce site. Despite correct WPML settings for product synchronization, the stock shows as 0 in translated versions while being correct in the Dutch version.
Solution: We recommended the client to update to WPML 4.8 and check if the issue persists. If the problem continues, we advised disabling all plugins except for WooCommerce and WPML to see if the issue still occurs. We also suggested creating a staging site to safely test changes without affecting the live site. Additionally, we asked the client to ensure the server settings are adequate by increasing the
upload_max_filesize
,
post_max_size
, and
max_execution_time
. After updating the WooCommerce Multilingual & Multicurrency plugin, we instructed the client to synchronize stock for products and product variations through the WooCommerce Multilingual & Multicurrency status tab troubleshooting link.
If this solution does not resolve the issue or seems outdated, we highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If problems persist, please open a new support ticket at WPML support forum.
This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
Background of the issue:
I am trying to synchronize product stock between the default language (Dutch) and the translated versions (English, German, French) on my website. You can see the issue on this page: hidden link.
Symptoms:
In the Dutch version of the product, the stock quantity is correct. However, in the translated versions (English, German, French), the stock always shows as 0, even though the product has sufficient stock available. All WPML settings for product synchronization appear to be correct, but the stock is not being updated in the translations.
Questions:
Why is the stock not synchronizing correctly between the default language and the translated versions?
How can I ensure that the stock levels are updated correctly in all language versions?
In the screenshots attached you see some of the products who are having this problem.
1. Try to update to WPML 4.8 and see if the issue persists?
2. If so, can you try to disable all plugins except WooCommerce and WPML ones and see if you still have the issue?
Hello,
My name is Carlos, and I will continue working on this ticket
1.- Please share the URL of a product where the issue can be seen, and that we can use as a reference.
2.- Share the access credentials to the site in your next message, which I have set private. That will allow us to reproduce the issue and check the configuration.
Confirm you have created a full site backup that you can restore if necessary.
Hi Ottelien,
Thank you very much for sharing the credentials requested.
It seems to be a conflict between Woocommerce Multilingual & Multicurrency and a third-party functionality, because every time I try to access Woocommerce Multilingual & Multicurrency -> Status tab, I get a 504 error.
Can you create a staging site with a copy of the live site where we can run further tests without affecting the production site?
Note: You can use the WP Staging plugin for free to create the staging site.
Thank you very much for creating the staging site.
Before we continue, I need to ask you to contact your hosting providers and ask them to increase these values:
upload_max_filesize = 64M
post_max_size = 64M
max_execution_time = 300
That way, we can check if the 'Maximum execution time' error disappears, and if we can upload and overwrite the WCML plugin folder.
If you visit hidden link you will see that the error with the max_execution_time persists.
Also, if you try manually uploading the WooCommerce Multilingual & Multicurrency plugin, you will run into the upload_max_filesize error.
Can you ask your hosting providers to check the logs on the server side? Perhaps there is information (an error, maybe) that helps us identify the issue.
Hi Carlos,
Is it helpful l if i will send the hosting company the WooCommerce Multilingual & Multicurrency plugin of which version they have to upload on the test environment?
If so, which version do they have to install on the website?
Yes, that will be helpful, and you can download the latest Woocommerce Multilingual & Multicurrency plugin from https://wpml.org/account/downloads/ -> Click on 'Download WPML Manually' link -> 'WPML components for compatibility with popular plugins' section.
Those steps will update the WCML plugin; however, it won't solve the problem with the upload_max_filesize error.
Now that WCML has been updated, I kindly ask you to follow these steps:
- Create a database backup
- Go to Woocommerce -> Woocommerce Multilingual & Multicurrency -> Status tab -> Troubleshooting link (bottom right) -> Select 'Synchronize stock for products and product variations' and click on 'Run the selected tools' button
- Wait for the process to finish and double-check if the issue disappeared
Hi Carlos,
We did the steps of what you said.
But still the problem is not solved, you can see it in the screenshot that is attached.
It is a bit urgent because the live webshop has now also a other problem with the languages.