-
Notifications
You must be signed in to change notification settings - Fork 685
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[bug]: Cannot place order again after initial order was declined #3046
Comments
Hi @mikhaelbois. Thank you for your report. Please, add a comment to assign the issue:
|
@magento export issue to JIRA project PWA as Bug |
✅ Jira issue (https://jira.corp.magento.com/browse/PWA-1514) is successfully created for this issue. |
As a sidenote Braintree does not support (confirmed with their support) using different credit card numbers to illicit a different payment gateway response in their sandbox. As such it will not be possible to test the following
without navigating away (or some other action to update the cart total) between step 2 and 4 thereby altering state. ¯_(ツ)_/¯ |
Describe the bug
When placing an order, if the initial order is declined and cause a Checkout Error, we won't be able to try again without reloading the page.
To reproduce
Steps to reproduce the behavior:
In our case, we are using Braintree in sandbox mode and had an order between 2000.00 - 2999.99.
https://developers.braintreepayments.com/reference/general/testing/php#transaction-amounts
Expected behavior
We should be able to place a new order when our first try was declined.
Possible solutions
In useCheckoutPage.js we are listening to
placeOrderCalled
.Initially it is set to
false
.Then when we try to place an order, the value is set to
true
.However, in the case we get an error with the
placeOrderMutation
,placeOrderCalled
will still be set totrue
.So we won't be able to place a new order.
Refreshing the page will reset that value to
false
.Here's an opened issue that relates to this kind of behavior: <https://github.com/apollographql/apollo-feature-requests/issues/170]
Please let us know what packages this bug is in regards to:
venia-concept
venia-ui
pwa-buildpack
peregrine
pwa-devdocs
upward-js
upward-spec
create-pwa
Acceptance Criteria
Test Plan
In our case, we are using Braintree in sandbox mode and had an order between 2000.00 - 2999.99.
[https://developers.braintreepayments.com/reference/general/testing/php#transaction-amounts>
The text was updated successfully, but these errors were encountered: