Skip to main content
Question

Payment screen keep showing in an endless loop


Forum|alt.badge.img+1

Hello,

I am trying to add Revenue cat to my IOS flutter app using this package: https://pub.dev/packages/purchases_flutter

After i make a purchase with sandbox and the screens show done(in picture 2), I got stuck in the payment screen, even i re-enter my credentials and pay again the app keeps showing me tha payment screen over and over (i got stuck in this function: Purchases.purchaseStoreProduct it does not return any CustomerInfo even though I paid and the ios screen shows done.).

I checked snadbox in revenue cat dashboard but all of my payment did not get persisted.

Can someone help me, and thanks in advace.

Here is my code(Picture 1):

 

12 replies

Forum|alt.badge.img

Did you find a solution?


Forum|alt.badge.img+1

I switched from emulator to my device and it worked !


Forum|alt.badge.img

It works man. Thank you


Forum|alt.badge.img+3
  • Dedicated Member
  • 17 replies
  • November 17, 2023

I’m having the same issue testing in Xcode 15 in the simulator!


Forum|alt.badge.img+3
  • Dedicated Member
  • 17 replies
  • November 17, 2023

RevenueCat, are you aware that this is happening? I am testing iOS 17.0.1, multiple devices. The successful purchase never calls the completion block. The dialog shows in an endless loop.


Forum|alt.badge.img+3
  • Dedicated Member
  • 17 replies
  • November 17, 2023

Also, my app is a huge old Objective-C code base, in case that makes a difference. So this is running in Objective-C.


Forum|alt.badge.img+3
  • Dedicated Member
  • 17 replies
  • November 17, 2023

It does work when testing on the device.


Forum|alt.badge.img+3
  • New Member
  • 2 replies
  • November 19, 2023

yes this is happening to me on Xcode similators!

 


Forum|alt.badge.img
  • New Member
  • 2 replies
  • January 31, 2024

was anyone able to find a solution?


cengiz-han-parlak
Forum|alt.badge.img+1

A real device might be working in this situation but I was unable to do so. So, to test purchases on an iOS simulator, after you complete the StoreKit configuration for Xcode, you need to manually add this configuration to your run scheme.

 

Press edit scheme:

Press edit scheme

Add configuration from the Options submenu:

Options submenu

Give it a go again.

 


So this was helpful for me while testing on Simulator.

From thread: 

 

  

lloyd-319549 wrote:

Hey guys, I had the same issue using expo and react-native with RevenueCat. Here’s how I managed to fix it:

  • Setup Storekit config as ford-david-32adae has linked.
  • Make sure your schema is linked to the .storekit file in Xcode. This will not work in just expo / expo run:ios.
  • Run `expo start` as normal, but build the app from Xcode.
     

Tldr; you need to run your dev build from Xcode for it to work, as expo doesn’t appear to pick up the .storekit file otherwise.

 

ford-davis-32adae wrote:

Hi all, found this thread when experiencing the same problem and thought I would share now I’ve fixed it.

In order to make subscriptions work on simulator you have to do some custom config in Xcode.
https://developer.apple.com/documentation/xcode/setting-up-storekit-testing-in-xcode?language=objc

Related discussion here: https://github.com/dooboolab-community/react-native-iap/issues/2603


 


Forum|alt.badge.img+1
cengiz-han-parlak wrote:

A real device might be working in this situation but I was unable to do so. So, to test purchases on an iOS simulator, after you complete the StoreKit configuration for Xcode, you need to manually add this configuration to your run scheme.

 

Press edit scheme:

Press edit scheme

Add configuration from the Options submenu:

Options submenu

Give it a go again.

 

Thanks for this tip!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings