Skip to content
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

v2 migration guide #295

Merged
merged 16 commits into from
Nov 13, 2024
Merged

v2 migration guide #295

merged 16 commits into from
Nov 13, 2024

Conversation

KunJeongPark
Copy link
Collaborator

Summary of changes

  • Migration guide from delegation pattern to completion handler and async/await functions

Checklist

  • Added a changelog entry

Authors

List GitHub usernames for everyone who contributed to this pull request.

@KunJeongPark KunJeongPark requested a review from a team as a code owner November 6, 2024 00:45
v2_MIGRATION_GUIDE.md Outdated Show resolved Hide resolved
Copy link
Collaborator

@sshropshire sshropshire left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🔥

v2_MIGRATION_GUIDE.md Outdated Show resolved Hide resolved
v2_MIGRATION_GUIDE.md Outdated Show resolved Hide resolved

### Important Change: Cancellation Handling
In v2.0-beta, cancellations (e.g., 3DS cancellations, PayPal web flow cancellations) are now returned as errors rather than as separate delegate methods. There are new helper methods, static functions, to help you discern threeDSecure cancellation errors and PayPal web flow cancellation errors.
- `CardError.threeDSecureCanceled(Error)` will return true for user cancellation during 3DS verification during card payment or card vaulting flows.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- `CardError.threeDSecureCanceled(Error)` will return true for user cancellation during 3DS verification during card payment or card vaulting flows.
- `CardError.threeDSecureCanceled(Error)` will return true for 3DS cancellation errors received during card payment or card vaulting flows.

v2_MIGRATION_GUIDE.md Outdated Show resolved Hide resolved
Copy link
Collaborator

@sshropshire sshropshire left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some minor take-or-leave edits but overall LGTM.

@KunJeongPark KunJeongPark merged commit f3b8fc0 into v2_beta Nov 13, 2024
5 checks passed
@KunJeongPark KunJeongPark deleted the v2-migration-guide branch November 13, 2024 17:22
KunJeongPark added a commit that referenced this pull request Nov 19, 2024
* Remove MXO (#291)

* Remove MXO

* remove Package.resolved file containing incompatible pinstorage version

* CHANGELOG entry

* Jax feedback and docStrings correction

* Remove PatchOrder for MXO, unused files in demo app

* Remove more classes used exclusively for MXO

* Convert Delegation Pattern to Completion Handler (#293)

* PayPal remove delgation pattern for completion handler function for checkout

* lint error for paypal start

* completion and analytics into notify functions

* paypal vault completion, unit tests

* remove PayPal delegates, references

* Card vault to completion, unit tests

* Card approve to completion, unit tests

* docstrings for approve completion param

* wrap paypal functions in async await

* async await wrapper for CardClient functions

* remove CardDelegate and references

* fix error in notifyCheckoutFailure

* Make error names and messages payPal caps consistent

* changelog entires

* Steven PR feedback: typo in Chagelog

* Simplify Cancel Errors (#296)

* Simplify cancel errors

* CHANGELOG for the cancel errors

* Steven PR feedback: change back CardClientError.canceled to .threeDSecureCanceled

* CHANGELOG update

* Cancel error handling (#297)

* http performRequest returns NetworkingClientErrors

* CardClient helper function for threeDSCancel, demo app cancel, demo app minor fixes

* PayPalClient cancel helper functions and demo app changes

* Steven PR feedback: move static helper functions to error enums

* Rename CardClientError -> CardError, PayPalWebCheckoutError -> PayPalError

* Steven PR feedback: return CoreSDKError in merchant completion handler

* CHANGELOG and analytics typo and fix wrong code in graphql error

* v2 migration guide (#295)

* v2 migration guide

* just cocoapods or SPM

* fix typos

* minor spacing changes

* Update with simplified cancel errors

* Steven PR feedback - diff to render green/red

* include removal of delegate methods in delete block

* update with cardClient threeDSecureCanceled error

* change to threeDSecureCanceled in migration steps

* add comment highlighting cancellation errors

* typo fix

* clarify separating cancel cases in errors

* revert cancel handling instructions

* add changes for cancellation helper methods

* fix typo in PayPalError.isCheckoutCanceled

* Steven PR feedback

* Make PayPalError and CardError Code enum consistent (#298)

* Changelog: move additive changes from breaking section (#299)

* Changelog: move additive changes from breaking section

* remove duplicate line for PayPal cancel errors
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants