Skip to main content
Solved

Purchase was cancelled - iOS 16 iPhone 14 Pro simulator

  • October 31, 2022
  • 2 replies
  • 710 views

Forum|alt.badge.img+3

Hi there,

 

May you please assist.

 

Im am using purchases_flutter: ^4.3.1

 

❯ flutter --version
Flutter 3.3.6 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 6928314d50 (6 days ago) • 2022-10-25 16:34:41 -0400
Engine • revision 3ad69d7be3
Tools • Dart 2.18.2 • DevTools 2.15.0

 

The issue is -

After filling in apple id + password

Clicking on either ‘Cancel’ or ‘Ok’

 

 

I always get the error below

 

PlatformException(1, Purchase was cancelled., {userCancelled: true, code: 1, message: Purchase was cancelled., underlyingErrorMessage: , readableErrorCode: PURCHASE_CANCELLED, readable_error_code: PURCHASE_CANCELLED}, null)

 

I am OKAY with getting the exception when user clicks cancel, but I don’t understand why I get the error when user clicks OK

 

 

Please note: Android implementation working fine. Only iOS affected

Also all offerings displayed on screenshot below are coming from RevenueCat without any issues.

 

 

 

 

Best answer by cody

Hey @Koketso!

IAP’s won’t work in the simulator unless you’re using StoreKit configuration files: https://www.revenuecat.com/docs/apple-app-store#ios-14-only-testing-on-the-simulator

 

Are you seeing this issue on real devices, too?

View original
Did this post help you find an answer to your question?

2 replies

Forum|alt.badge.img+3
  • New Member
  • 1 reply
  • November 8, 2022

I am facing the same issue on the simulator. On device it works fine though. Not sure if IAPs are supposed to work on the simulator.


cody
RevenueCat Staff
Forum|alt.badge.img+8
  • RevenueCat Staff
  • 497 replies
  • Answer
  • November 10, 2022

Hey @Koketso!

IAP’s won’t work in the simulator unless you’re using StoreKit configuration files: https://www.revenuecat.com/docs/apple-app-store#ios-14-only-testing-on-the-simulator

 

Are you seeing this issue on real devices, too?


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