stripe / stripe-react-native

React Native library for Stripe.
https://stripe.dev/stripe-react-native
MIT License
1.29k stars 263 forks source link

[BUG] iOS: authenticationPresentingViewController error when confirming payment sheet with 3DS #1749

Open jetaix opened 1 month ago

jetaix commented 1 month ago

Describe the bug When attempting to confirmPaymentSheetPayment, I encounter the following error on iOS with a 3DS payment and on a modal presentation view

To Reproduce

  1. Open a modal presentation view
    • init payment
    • attempt to confirm the payment with confirmPaymentSheetPayment
    • -> the 3DS screen is not displayed and i get the following error:

authenticationPresentingViewController is already presenting. You should probably dismiss the presented view controller in prepareAuthenticationContextForPresentation

Expected behavior The 3DS screen should be displayed on top of the stack.

Smartphone:

Additional context

The 3DS screen opening normaly in a modal view seems conflict with my current modal view

Did you note some issues with a "modal" presentation view and 3DS screen?

angelica-snowit commented 6 days ago

I opened a bug on react native because the Modal behaviour changed a lot and was not addressed in changelog. I think that Stripe problem with 3d secure depend on this: https://github.com/facebook/react-native/issues/47694 I also opened a bug here to fix this: https://github.com/stripe/stripe-react-native/issues/1772