hyyan / woo-poly-integration

Looking for maintainers! - Wordpress WooCommerce Polylang Integration
https://wordpress.org/plugins-wp/woo-poly-integration/
MIT License
183 stars 66 forks source link

Cart.php: Difference betweeb Github code and last WP Repo version? #538

Closed sitoexpress closed 3 years ago

sitoexpress commented 3 years ago

Hi there,

I'm having some issues with some attributes on Cart.php on a website a manage. The attributes in question do have a translation.

The problem leads to php timeouts error and sometimes users are not able to add products in the cart (wp_ajax returns 500).

The error log reports:

[14-Feb-2021 06:28:28 UTC] PHP Fatal error:  Maximum execution time of 90 seconds exceeded in {my_path}/wp-includes/class-wp-post.php on line 265
[14-Feb-2021 09:17:35 UTC] PHP Fatal error:  Maximum execution time of 90 seconds exceeded in {my_path}/wp-includes/taxonomy.php on line 1588
[14-Feb-2021 10:08:11 UTC] PHP Fatal error:  Maximum execution time of 90 seconds exceeded in {my_path}/wp-content/plugins/woo-poly-integration/src/Hyyan/WPI/LocaleNumbers.php on line 117
[14-Feb-2021 16:22:52 UTC] PHP Fatal error:  Uncaught Exception: Store is a required field in {my_path}/wp-content/plugins/woo-poly-integration/src/Hyyan/WPI/Cart.php:370

Now I checked Cart.php on the server and Cart.php here, but it seems the file is different.

What I would like to know is if it's safe to use the current Github code or it's better to wait for a new release sometimes somehow (I see that there's been some development lately, after the last quiet years).

Please let me know.

Jon007 commented 3 years ago

Hi, the new version 1.5 has now been released on https://wordpress.org/plugins/woo-poly-integration/ There are no significant updates that I recall to cart.php, I logged #537 to review as I don't think the cart handling has had a good review for a while.

looking at your log, maybe your server is having a problem with the locale numbers, trying going to: wp-admin/options-general.php?page=hyyan-wpi and turning off the feature "Use locale number formats"

Another thing that can happen is other plugins cause issue, for example anything which hooks woocommerce_get_cart_contents gets called repeatedly at various points during the calculation and display of the mini-cart and cart page. This plugin doesn't hook that but some of the other hooks may get called more than strictly necessary.

Please any specific issues on cart, welcome to comment on: #537