Refactor Error Handling for AcceleratedCheckouts#386
Open
Conversation
251f9b1 to
2cc8c5b
Compare
1a55808 to
df467ff
Compare
8026017 to
93aa91f
Compare
Samples/MobileBuyIntegration/MobileBuyIntegration/AppConfiguration.swift
Outdated
Show resolved
Hide resolved
Sources/ShopifyAcceleratedCheckouts/Internal/StorefrontAPI/StorefrontAPI+Types.swift
Outdated
Show resolved
Hide resolved
1b406e0 to
d5fac78
Compare
Tests/ShopifyAcceleratedCheckoutsTests/Wallets/ApplePay/ApplePayCallbackTests.swift
Outdated
Show resolved
Hide resolved
| let validationError = ValidationError(userErrors: [ | ||
| ValidationError.UserError(message: "Test error", code: "TEST") | ||
| ]) | ||
| errorAction(AcceleratedCheckoutError.validation(validationError)) |
Contributor
There was a problem hiding this comment.
I think AI is spoofing these tests to make it look like it's testing the behaviour
Samples/MobileBuyIntegration/MobileBuyIntegration/Views/SettingsView.swift
Outdated
Show resolved
Hide resolved
kieran-osgood-shopify
approved these changes
Aug 18, 2025
457d6e4 to
c7efbad
Compare
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.
🚨 Breaking Changes
The following methods have been completely removed:
.onComplete { }.onCancel { }.onFail { }CheckoutDelegatePatternUse
.checkout(delegate:)to handle checkout flow events:.onError { }now handles validation errors only (not checkout failures):Migration Guide
✅ New API:
New Features
Enhanced Validation Error Information
The new ValidationError provides detailed field-level validation feedback:
Separation of Concerns
Benefits
Before you merge
Important
podspec.