Troubleshooting

Error: Connection timed out after 120000 milliseconds

When opening module configuration page, you might bet a red warning with Wise2Sync API Error... "Connection timed out after 120000 milliseconds". This means, that when your website tried to validate the API Access Token, but did not get a reply from the app.wise2sync.com server after 12 seconds. Usually this happens when:

  • You do not have CURL extension installed on your server
  • Your hosting provider is blocking API calls to app.wise2sync.com
  • Our servers are blocking your IP address

Possible solution: contact your hosting provide to make sure that your server can access https://app.wise2sync.com. For example, this URL https://app.wise2sync.com/api/users/check-status should return:

{"error":"access_denied","error_description":"OAuth2 authentication required"}
Slow import with big amount of products

Wise2Sync Connector module uses product reference to determine which product is which. If you have a large database of products (f.e. 50000+ products), adding Index on "reference" column could speed up import/update. This would speed up batch imports.

You can add index to "reference" column by running this SQL:

ALTER TABLE `ps_product` ADD INDEX(`reference`);
ALTER TABLE `ps_Wise2Sync_queue` ADD INDEX(`id_task`);

Please note that "ps_product" and "ps_Wise2Sync_queue" tables can be named differently in your DB.

Task is stuck at certain % and no products are being updated / imported

There could be various reasons for this. First place to look would be task actions log or your server logs. Most common problems:

  • Allowed memory issue. Solution: add -d memory_limit=2048M  parameter to your CRON command (2048M can be smaller or higher)
  • Server ran out of disk space
  • Other technical problems
Error: Allowed memory size

Your Heartbeat command returns similar error:

PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in ....

Most of the time this happens when Heartbeat tries to create a product and it runs out of memory. Chances are higher to get this error when not you are importing products with variations and your supplier provides high resolution images.

A solution for this would be to add extra parameter for your Heartbeat CRON command, so it would look like:

php -d memory_limit=2048M bin/console Wise2Sync:heartbeat --no-debug

Note the parameter -d memory_limit=2048M.

HTTP Type Heartbeat (CRON) not working

If you are using HTTP type CRON, there could be multiple reasons. We first recommend checking the output but putting the CRON URL into your browser (use incognito window).

Look for the URL in your Wise2Sync module configuration page in PrestaShop. It will look similar to this:

https://domain.com/index.php?fc=module&module=Wise2Sync&controller=heartbeat&hash=XXXXXXXXXXX

This way you will "trigger" heartbeat manually. If your heartbeat was logged, then it must be the server settings. You can consult your hosting provider how to correctly set up CRON on your server.

Tip: if you have maintenance mode enabled in your PrestaShop - make sure you exclude your server IP address in Shop Parameters → General → Maintenance → Maintenance IP

Getting "500 Internal server error" (or similar) when clicking "Schedule Now" in PrestaShop import profile

Most often the cause of this error is that PHP runs out of available memory on your server. Your server error logs would show more information. But in general - the server your PrestaShop store is running should be able to process large files.

This error occurs usually when you are syncing a large number of products (for example import file is >10Mb). You might also encounter similar problems if you are using HTTP Type Heartbeat.

Possible solution #1
Use the Command Line to run profiles. Here is an example command to run the profile with included memory_limit parameter. We highly recommend using the Command Line interface as it is quicker and more informative when setting up imports and testing things.

php -d memory_limit=512M bin/console Wise2Sync:run --id_profile=PROFILE_ID --no-debug

Possible solution #2
If the "500 error" is really caused because of memory limits, you can try increasing the memory_limit of PHP. You might need to contact your hosting / server provider to do so. For example:

memory_limit = 512MB

Possible solution #3
Reduce the amount of products you are exporting in app.wise2sync.com by adding more filters. Start with small catalog and then increase the size.