Some orders not getting updated after successful payment
-
Hello,
I started this thread in the core WC forums and was asked to move this discussion here.
We are facing an issue where some order statuses do not get updated to “Processing” when payment is successful, using the Stripe payment gateway. It happens rarely, with approximately 10 to 15 orders in 2 years, but it leads to unpleasant moments with customers.
Logs are enabled and show that, in these cases, payment intent is sent to Stripe on order fulfilled, and Stripe apparently sents back the payment confirmation but WC does not update the order status.
Here are the logs of a customer placing 2 orders one after the other. The first one’s statuts did not get updated, the second one did:
First order:
Logs:
2024-09-15T15:17:32+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
customers request: Array
(
[email] => XXXXXXXXXXXXXXXX
[description] => Nom : XXXXX, Invité
[name] => XXXXXXXXXXXXXXX
[metadata] => Array
(
)
[preferred_locales] => Array
(
[0] => fr-FR
)
[address] => Array
(
[line1] => XXXXXXXXXXXXXXXXXX
[line2] => XXXXXXXXXXXXXXXXX
[postal_code] => XXXXXXXX
[city] => XXXXXXXXX
[state] =>
[country] => FR
)
)
====End Log====
2024-09-15T15:17:32+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
customers response with stripe-version: 2019-09-09
====End Log====
2024-09-15T15:17:32+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
payment_methods/pm_1PzKCcJkzxWNQpT2e286x0bH
====End Log====
2024-09-15T15:17:33+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
payment_intents request: Array
(
[capture_method] => automatic
[payment_method] => pm_1PzKCcJkzxWNQpT2e286x0bH
[shipping] => Array
(
[name] => XXXXXXXXXXXXXXXXXXX
[address] => Array
(
[line1] => XXXXXXXXXXXXXXXXX
[line2] => XXXXXXXXXXXXXXXXX
[city] => XXXXXXXXXXXXXXXXX
[country] => FR
[postal_code] => XXXXXXXXXXXXXXXXX
[state] =>
)
)
[mandate_data] => Array
(
[customer_acceptance] => Array
(
[type] => online
[online] => Array
(
[ip_address] => 2a01:e0a:ddb:c0f0:bad6:a0b7:b204:43b5
[user_agent] => WooCommerce Stripe Gateway8.2.0; https://ratatamkids.com
)
)
)
[amount] => 7500
[confirm] => true
[currency] => eur
[customer] => cus_Qr2HPhjdBBqlF7
[description] => Ratatam Site Officiel - Commande 35289
[metadata] => Array
(
[customer_name] => XXXXXXXXXXXXXXXXX
[customer_email] => XXXXXXXXXXXXXXXXX
[site_url] => https://ratatamkids.com
[order_id] => 35289
[order_key] => wc_order_FhdczDoqAWBfO
[payment_type] => single
)
[payment_method_types] => Array
(
[0] => card
[1] => link
)
)Notes:
Second order:
Logs:
2024-09-15T15:28:16+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
customers request: Array
(
[email] => XXXXXXXXXXXXXXXXX
[description] => Nom : XXXXXXXXXXXXXXXXX, Invité
[name] => XXXXXXXXXXXXXXXXX
[metadata] => Array
(
)
[preferred_locales] => Array
(
[0] => fr-FR
)
[address] => Array
(
[line1] => XXXXXXXXXXXXXXXXX
[line2] => XXXXXXXXXXXXXXXXX
[postal_code] => XXXXXXXXXXXXXXXXX
[city] => XXXXXXXXXXXXXXXXX
[state] =>
[country] => FR
)
)
====End Log====
2024-09-15T15:28:16+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
customers response with stripe-version: 2019-09-09
====End Log====
2024-09-15T15:28:16+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
payment_methods/pm_1PzKN0JkzxWNQpT2ch0enbNi
====End Log====
2024-09-15T15:28:16+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
payment_intents request: Array
(
[capture_method] => automatic
[payment_method] => pm_1PzKN0JkzxWNQpT2ch0enbNi
[shipping] => Array
(
[name] => Erika Mollet
[address] => Array
(
[line1] => XXXXXXXXXXXXXXXXX
[line2] => XXXXXXXXXXXXXXXXX
[city] => XXXXXXXXXXXXXXXXX
[country] => FR
[postal_code] => XXXXXXXXXXXXXXXXX
[state] =>
)
)
[mandate_data] => Array
(
[customer_acceptance] => Array
(
[type] => online
[online] => Array
(
[ip_address] => 2a01:e0a:ddb:c0f0:bad6:a0b7:b204:43b5
[user_agent] => WooCommerce Stripe Gateway8.2.0; https://ratatamkids.com
)
)
)
[amount] => 8900
[confirm] => true
[currency] => eur
[customer] => cus_Qr2RqFro1JNdzD
[description] => Ratatam Site Officiel - Commande 35290
[metadata] => Array
(
[customer_name] => XXXXXXXXXXXXXXXXX
[customer_email] => XXXXXXXXXXXXXXXXX
[site_url] => https://ratatamkids.com
[order_id] => 35290
[order_key] => wc_order_mOZJVAQvSAccD
[payment_type] => single
)
[payment_method_types] => Array
(
[0] => card
[1] => link
)
)
====End Log====
2024-09-15T15:28:17+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
payment_intents response with stripe-version: 2019-09-09
====End Log====
2024-09-15T15:29:54+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
payment_intents/pi_3PzKN2JkzxWNQpT20wCp14l2?expand[]=payment_method
====End Log====
2024-09-15T15:29:55+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
Processing response: stdClass Object
(
[id] => ch_3PzKN2JkzxWNQpT20WM3bAZS
[object] => charge
[amount] => 8900
[amount_captured] => 8900
[amount_refunded] => 0
[application] =>
[application_fee] =>
[application_fee_amount] =>
[balance_transaction] => txn_3PzKN2JkzxWNQpT20nG75XHG
[billing_details] => stdClass Object
(
[address] => stdClass Object
(
[city] => XXXXXXXXXXXXXXXXX
[country] => FR
[line1] => XXXXXXXXXXXXXXXXX
[line2] => XXXXXXXXXXXXXXXXX
[postal_code] => XXXXXXXXXXXXXXXXX
[state] =>
)
[email] => XXXXXXXXXXXXXXXXX
[name] => XXXXXXXXXXXXXXXXX
[phone] => XXXXXXXXXXXXXXXXX
)
[calculated_statement_descriptor] => RATATAM
[captured] => 1
[created] => 1726414131
[currency] => eur
[customer] => cus_Qr2RqFro1JNdzD
[description] => Ratatam Site Officiel - Commande 35290
[destination] =>
[dispute] =>
[disputed] =>
[failure_balance_transaction] =>
[failure_code] =>
[failure_message] =>
[fraud_details] => stdClass Object
(
)
[invoice] =>
[livemode] => 1
[metadata] => stdClass Object
(
[customer_email] => XXXXXXXXXXXXXXXXX
[customer_name] => XXXXXXXXXXXXXXXXX
[order_id] => 35290
[order_key] => wc_order_mOZJVAQvSAccD
[payment_type] => single
[site_url] => https://ratatamkids.com
)
[on_behalf_of] =>
[order] =>
[outcome] => stdClass Object
(
[network_status] => approved_by_network
[reason] =>
[risk_level] => normal
[seller_message] => Payment complete.
[type] => authorized
)
[paid] => 1
[payment_intent] => pi_3PzKN2JkzxWNQpT20wCp14l2
[payment_method] => pm_1PzKN0JkzxWNQpT2ch0enbNi
[payment_method_details] => stdClass Object
(
[card] => stdClass Object
(
[amount_authorized] => 8900
[authorization_code] => 352288
[brand] => visa
[checks] => stdClass Object
(
[address_line1_check] => unavailable
[address_postal_code_check] => unavailable
[cvc_check] => pass
)
[country] => FR
[exp_month] => 2
[exp_year] => 2025
[extended_authorization] => stdClass Object
(
[status] => disabled
)
[fingerprint] => A1nVF1jBAy2U5e9B
[funding] => debit
[incremental_authorization] => stdClass Object
(
[status] => unavailable
)
[installments] =>
[last4] => 4571
[mandate] =>
[multicapture] => stdClass Object
(
[status] => unavailable
)
[network] => cartes_bancaires
[network_token] => stdClass Object
(
[used] =>
)
[overcapture] => stdClass Object
(
[maximum_amount_capturable] => 8900
[status] => unavailable
)
[three_d_secure] => stdClass Object
(
[authenticated] => 1
[authentication_flow] => challenge
[electronic_commerce_indicator] => 05
[exemption_indicator] =>
[result] => authenticated
[result_reason] =>
[succeeded] => 1
[transaction_id] => c23e9a1a-f35b-4e78-9871-3135f8667d2a
[version] => 2.2.0
)
[wallet] =>
)
[type] => card
)
[receipt_email] =>
[receipt_number] =>
[receipt_url] => https://pay.stripe.com/receipts/payment/CAcQARoXChVhY2N0XzFGaWlLMEprenhXTlFwVDIo8_qbtwYyBnnRxASs1zosFlLlkyFaz7oHGHi9CYZg8-MJVoLq4TlOU5Gj8tH3W8hRpwMJLtiTdLnML94
[refunded] =>
[refunds] => stdClass Object
(
[object] => list
[data] => Array
(
)
[has_more] =>
[total_count] => 0
[url] => /v1/charges/ch_3PzKN2JkzxWNQpT20WM3bAZS/refunds
)
[review] =>
[shipping] => stdClass Object
(
[address] => stdClass Object
(
[city] => XXXXXXXXXXXXXXXXX
[country] => FR
[line1] => XXXXXXXXXXXXXXXXX
[line2] => XXXXXXXXXXXXXXXXX
[postal_code] => XXXXXXXXXXXXXXXXX
[state] =>
)
[carrier] =>
[name] => XXXXXXXXXXXXXXXXX
[phone] =>
[tracking_number] =>
)
[source] =>
[source_transfer] =>
[statement_descriptor] =>
[statement_descriptor_suffix] =>
[status] => succeeded
[transfer_data] =>
[transfer_group] =>
)
====End Log====
2024-09-15T15:29:55+00:00 Débogage
====Stripe Version: 8.2.0====
====Stripe Plugin API Version: 2019-09-09====
====Start Log====
balance/history/txn_3PzKN2JkzxWNQpT20nG75XHG
====End Log====Notes:
What could possibly be wrong? Issues with the server at the time of the confirmation? What would you recommend?
Let me know if you need more information.
Thanks for the help,
Julien
- You must be logged in to reply to this topic.