We’ve been trying to work out why our stock keeps getting out of sync (dissapearing) so we installed product change log addon which identified the Stripe checkout as the issue.
When a customer checks out with Stripe 3 emails are sent to us and 3 emails to the customer. Sometimes all 3 trigger stock deduction correctly (example stock from 2 to 1) and sometimes it will deduct the stock multiple times.
Both inventory and emails are triggered based on the change in order status so you need to look into seeing why the order status is changing frequently.
No the order status is not changing, this appears to be Stripe sending multiple confirmations. Stripe do this for reliability I assume, but clearly state that payment processing software should handle it.
I suspect the reason it only changes occasionally the stock multiple times is as it needs the database to update and the requests are sent fast.
This is a bug, and it’s not a user error from my part using their software.
The return webhook runs each time a confirmation is sent and sends a new email, re-sets the status, and sets the new stock numbers based on what is currently in the database.
After the first 1 or 2 requests the database has updated and the 2nd / 3rd requests will see lower stock and as a result deduct stock again.
What the stripe webhook should do is only take action on the first payment confirmation and ignore the subsequent ones.
It’s definitly a bug? It doesn’t happen with PayPal or other payment methods.
I don’t think so this issue with Stripe has been going on for some time over many updates. I’ve only just been annoyed enough as the product range grows to see if it can be resolved.
Big CS-Cart Update is Here
Experience the New Admin Panel with Dark Theme