#itay-GooglePay

1 messages · Page 1 of 1 (latest)

bronze violet
#

Hi, is this React native?

shrewd moth
#

flutter

#

?

bronze violet
#

Sorry, do you happen to know what version you are running on?

shrewd moth
#

2.5.0

#

This is the same sdk?

bronze violet
#

No this is React Native

shrewd moth
#

Did you fixed it also on flutter sdk?

#

Also this fix is for return an error why should I get not available?

bronze violet
#

Um that's the latest one

shrewd moth
#

sorry what?

bronze violet
#

So there is a similar issue which is fixed from 2.0.0. But yours are 2.5.0, right?...

shrewd moth
#

yes

bronze violet
#

No error outputed?

#

Can you share your full code in file?

shrewd moth
#

no error no crash

#

and not getting to next line code

bronze violet
#

Could you share full file code?

shrewd moth
#

final isGooglePaySupported = await Stripe.instance.isGooglePaySupported(
IsGooglePaySupportedParams(
testEnv: !FlavorManager.isProduction,
),
);
await Stripe.instance.initGooglePay(
const GooglePayInitParams(
merchantName: 'Faye',
countryCode: 'US',
testEnv: true,
isEmailRequired: false,
existingPaymentMethodRequired: false,
billingAddressConfig: BillingAddressConfig(
isPhoneNumberRequired: false,
isRequired: false,
format: BillingAddressFormat.FULL,
),
),
);

#

Is that ok

#

?

bronze violet
#

I am looking at it

#

nothing stands out to be potential issue. But how was isGooglePaySupported?

shrewd moth
#

that works return true

#

I also can display the button but the init now working..

#

not

bronze violet
#

Ok, if you do this

const { error } = await initGooglePay

then print out the error how would it look like?

shrewd moth
#

this is like: final error =

#

?

bronze violet
#
const { error } = await initGooglePay({
      testEnv: true,
...

#

Can you try that?

shrewd moth
#

this is not flutter code

#

and the function Future<void>

#

return nothing

bronze violet
#

Oh I see, sorry

shrewd moth
#

no problem any suggestion?

bronze violet
#

If this code doesn't work then it might be a problem with your device

#

Do you have a card registered in the device you are testing?

shrewd moth
#

this is the first code i tried also doesn't work

#

My own device an yes i have a card registered

#

also using that Stripe.instance.createGooglePayPaymentMethod this one should be after the init right?

bronze violet
#

should be after

#

But your issue is your app stopped at init, right?

#

Without any error it is hard to diagnose

#

Can you try with a different device? Just to narrow down the issue?

shrewd moth
#

I think i got something from android logcat

#

maybe it's not try to again if i am getting this error

#

oh sorry that not happen again

#

I tried two different device both getting the same

#

waiting the function to finish but never does

#

what can be the problem?

bronze violet
#

Hi, I think it could be more of the issue where this code is called, than the code itself. Could you open an issue on flutter-stripe, include your full code?

#

Sorry I don't have a definite answer for you, but the maintainer of flutter-stripe should have other approaches to triage

shrewd moth
#

ok I'll do that

#

Thnanks