Question

Cannot finish transaction with SDK v.6.3.0 and MagicWeather example

  • 19 November 2023
  • 7 replies
  • 50 views

Badge +6

Hello,

 

I configured MagicWeather example (by only changing `appleApiKey` and `ios` bundle name); I also created in-app subscription product in Apple App Store, and configured RevenueCat. Subscription is shown correctly, but it seems transaction never finishes, I am in a loop: 
 

  1. Click on "Change the Weather" opens "paywall" widget with correct price shown, and "terms and conditions" footer.
  2. Click on the product item in the list (and I have single product only) will popup iOS username/password screen, "Sign in with Apple ID"
  3. After authentication, I can "purchase" chosen product, using iOS "Sandbox" native widget (in my case, clicking "Subscribe" button triggers "Enter password to authorize this transaction")
  4. After "purchase" it returns to "paywall" screen, and after few seconds delay it returns back to iOS "purchase product" widget, although I don't click anything. In a loop

I also added debug message right after `await Purchases.purchasePackage(myProductList[index]);` and it seems this call never returns.

Anyone succeeded with this example?

Also, it is very slow, when I choose offer from a list of available products, it takes few seconds to open purchase screen.


7 replies

Userlevel 3
Badge +8

Hi,

I can try to replicate this on my side. Which SDK are you using?

Badge +6

Hi,

I can try to replicate this on my side. Which SDK are you using?

sorry I forgot to mention: Flutter “MagicWeather” example, Flutter SDK (or library), latest version 6.3.0. 
I submitted it as a bug. I found 1+ year old post where RevenueCat developer says that this is bug from Apple. However, Google’s “in_app_purchase” Flutter library doesn’t have such behavior. It happens only with simulator; doesn’t havppen with physical device. RevenueCat is even slow: 5-7 seconds waiting time till screen with in-app offerings opens; “in_app_purchase” library doesn’t have such issues, opens it instantly. Therefore, it is not a bug from Apple; RevenueCat doesn’t work with simulator, but another Flutter library works.


Just try to configure MagicWeather example with some in-app products.

 

Userlevel 3
Badge +8

If you try with a physical device and StoreKit config file, does that solve the hang + speed issue? The sandbox network can be slow, and the other library may be relying on a config file (which is fast)

Badge +6

If you try with a physical device and StoreKit config file, does that solve the hang + speed issue? The sandbox network can be slow, and the other library may be relying on a config file (which is fast)

I assume you mean “App Store Simulator” when you mention “config file”. No, it is not simulator; other library uses real App Store Sandbox, remote, provided by Apple, and it is lighting fast. You can find “Dashclicker” example inn Google Flutter Codelabs. I configured my own offerings in App Store Connect, it is not local config file, it works just fine, with iPhone Simulator on Mac, and with real device attached to Mac; but RevenueCat does not work with iPhone Simulator at all.
 

Userlevel 3
Badge +8

Hi,

Just to clarify, I mean a StoreKit configuration file that you can setup in Xcode itself, which will process the purchases locally.

Can you send a screenshot of the purchase popup from the other library? It should say whether it’s using a local file or going over the sandbox network.

Badge +6

I believe I already answered. No, I am not using local app-store simulator for real-life integration tests. It would be nonsense; the goal here is to test that subscription settings configured in Apple Console are shown on simulator (and later on, on real mobile device) instantly, in milliseconds instead of 5-7 seconds of waiting. Google’s library does that in milliseconds. 
 

Badge +6

I should ask RevenueCat developers to provide working example; but instead, they ask me to provide them back their own non-working example? 
 

I even found more than a year posts describing the same issue where RevenueCat developer mentions that it is bug in Apple SDK and he submitted ticket to Apple. Then how to explain that Google’s library does work without such issues?
 

Reply