#wise_fox_58361

1 messages · Page 1 of 1 (latest)

narrow pilotBOT
formal adder
#

Can you share the code you're calling which throws that error?

vapid prism
formal adder
#

Which lines specifically?

vapid prism
#
const _collectPaymentMethod = async (paymentIntentId) => {
        // console.log('_collectPaymentMethod', paymentIntentId)
        const { paymentIntent, error } = await collectPaymentMethod({
            paymentIntentId: paymentIntentId,
            skipTipping: true,
        });

        if (error) {
            // console.log('error', error)
            dispatch(clearClientSecret())
            dispatch(donationInitiationFailed(error))
            let isUserCancelledError = error?.code === 'USER_ERROR.CANCELED' || error?.code === 'Canceled';
            if (!isUserCancelledError) {
                navigation.navigate('ModalStack', { screen: 'DonationErrorModal', params: { error: 'DONATION_FAILED', message: error.code } });
            }
        } else if (paymentIntent) {
            await _processPayment(paymentIntentId);
        }

    };

#

In the commented out console.log I can see an the paymentIntentId is being passed but then I get sent into the error part of the if else statement

#

but I dont think this is the issue

#

As mentioned it was working before I upgraded the packange numbers

formal adder
#

Which have you upgraded?

vapid prism
#
  • "@stripe/stripe-terminal-react-native": "^0.0.1-beta.13" -> "@stripe/stripe-terminal-react-native": "^0.0.1-beta.14",

  • compileSdkVersion = 31 -> 34

  • targetSdkVersion = 31 -> 34

implementation "com.stripe:stripeterminal-localmobile:2.3.1" -> implementation "com.stripe:stripeterminal-core:3.2.1"
implementation "com.stripe:stripeterminal-core:2.3.1" -> implementation "com.stripe:stripeterminal-localmobile:3.2.1"

peak basin
#

stripeterminal-core:3.2.1 was only released yesterday which is meant to be compatible with version 34. Could it however be incompatible with the Stripe terminal RN version?
Why are you importing stripeterminal-core explicitly in your Android project ?

#

You need to have:

compileSdkVersion = 33
targetSdkVersion = 31
vapid prism
#

Yes I thought this could be unnecessary looking at your documentation but I was not the person who implemented it.

#

Let me remove it and give the following changes a go.