Order status not updating after payment fails
-
Hello,
The issue I am experiencing is that orders where payment has failed do not update their order status properly. I am testing with WooCommerce version 3.3.1 and WooCommerce Stripe Gateway 4.0.5.
In my testing I will begin the checkout process (it doesn’t seem to matter if I am already logged in or if I am checking out as a new user), enter valid billing details, and use a Stripe test card to generate a payment error (for example 4000000000000002 or 4000000000000069).
The checkout page will correctly display an error message, and the WooCommerce order page will show a failed payment note from Stripe (“The card was declined.”), and I will receive a failed order email, but the order status will remain “Pending Payment”.
I don’t have any plugins besides WooCommerce and Stripe gateway installed, I am using the default WordPress TwentySeventeen theme, I have Webhooks setup, and Stripe is showing Webhooks are being sent successfully.
After checking logs I see the following error messages:
02-16-2018 @ 19:12:27 – ====Start Log====
sources/src_1BwEdBEQafauzX9qFD1pwDX4
====End Log====02-16-2018 @ 19:12:27 – ====Start Log====
Info: Begin processing payment for order 15 for the amount of 10.00
====End Log====02-16-2018 @ 19:12:27 – ====Start Log====
charges request: Array
(
[currency] => usd
[amount] => 1000
[description] => WordPress [Dev] – Order 15
[capture] => true
[expand[]] => balance_transaction
[metadata] => Array
(
[customer_name] => J Doe
[customer_email] => [email removed]
[order_id] => 15
)[source] => src_1BwEdBEQafauzX9qFD1pwDX4
)====End Log====
02-16-2018 @ 19:12:28 – ====Start Log====
Error: stdClass Object
(
[error] => stdClass Object
(
[message] => Your card was declined.
[type] => card_error
[code] => card_declined
[decline_code] => generic_decline
[charge] => ch_1BwEdEEQafauzX9qTheZ1FDR
))
====End Log====
02-16-2018 @ 19:12:31 - ====Start Log====
Could not find order via charge ID: ch_1BwEdEEQafauzX9qTheZ1FDR
====End Log====
- The topic ‘Order status not updating after payment fails’ is closed to new replies.