Repository navigation
[Swift] Report Apple Pay sheet presentation failures through onFail - #930
Merged
Merged
Conversation
Bundle Size Budgets
Bundle and package sizeWeb bundle sizes cover shipped runtime JavaScript. Package sizes cover the full published archive, including any source maps, declarations, and documentation it contains.
How sizes are measuredMeasured from the PR base SHA and PR head SHA. Web bundle rows sum shipped |
When PKPaymentAuthorizationController.present() returned false, startPaymentRequest() reset the state machine to idle without raising an error, so ApplePayViewController.onPress() never called onCheckoutFail and host apps that show a loading state on tap stayed stuck. Reset to idle as before, then throw ShopifyAcceleratedCheckouts.Error.invariant(expected: "payment sheet"), matching the v3 fix (Shopify/checkout-sheet-kit-swift#609). The existing onPress() catch forwards it to onCheckoutFail as an sdkError. Reported in Shopify/checkout-sheet-kit-swift#599 (shop/issues-checkout#14687).
kyle-schellen
force-pushed
the
ks-apple-pay-present-failure
branch
from
October 7, 2026 22:29
d5add8f to
83d97fa
Compare
kyle-schellen
marked this pull request as ready for review
October 7, 2026 23:15
Bitrise buildsInstall this buildOpen Tophat, select your target device, then click Install. Links open on the Mac running Tophat.
Checkout Kit E2E results
|
kieran-osgood-shopify
approved these changes
Oct 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes are you making?
When
PKPaymentAuthorizationController.present()returnsfalse,startPaymentRequest()reset to.idlewithout throwing. As a result,onFailnever fired, and apps that show a loading state on tap stayed stuck. It now throws.invariant(expected: "payment sheet")after the reset, andonPress()forwards it toonFailas.sdkError. This is the same fix as v3's Shopify/checkout-sheet-kit-swift#609.Reported in Shopify/checkout-sheet-kit-swift#599 (shop/issues-checkout#14687).
How to test
dev swift test ApplePayAuthorizationDelegateTestssupportedNetworks, sopresent()returnsfalse.Before you merge
Important
platforms/swift/README.mdand/orplatforms/android/README.md)