My tests suggest that this only affects the new checkout experience.
When reproducing this issue, the events occur
The error prevents the customer from being directed to the order received page.
The order is successful.
Payment is charged.
Order emails are sent out.
The product is not removed from the cart.
Since the customer sees an error, they may attempt to place the order multiple times. Additional attempts to place the order result in duplicate orders and payments.
To Reproduce
Steps to reproduce the behavior:
Ensure the legacy checkout experience is disabled.
Enable the Enable payments via saved cards option.
Add a product to your cart.
Navigate to the checkout page.
Add a card number.
Select the Save payment information to my account for future purchases. option.
Select Place order.
Note the error.
Note the network response.
Navigate to WooCommerce > Orders.
Note a new order has been created.
Navigate to your Stripe dashboard.
Note that payment has been authorized (and captured if configured) successfully.
Expected behavior
The token information is saved correctly when saving card details at checkout.
An error that prevents the user from being directed to the order received page will also prevent payment from being authorized/captured.
Screenshots
Environment (please complete the following information):
Describe the bug When saving a payment method on checkout (shortcode or Blocks), an error is displayed after placing the order:
If the shortcode checkout is used, the
?wc-ajax=checkout
response is200
, but it includes the following:If the Blocks checkout is used, the
checkout?_locale=user
response is400
, and it includes the following:My tests suggest that this only affects the new checkout experience.
When reproducing this issue, the events occur
To Reproduce Steps to reproduce the behavior:
Place order
.Expected behavior
Screenshots
Environment (please complete the following information):
Additional context Discovered while investigating another issue in p1718493178460639-slack-C3NCP7ZJ6
This may be
priority: critical
.