-
Notifications
You must be signed in to change notification settings - Fork 234
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Purchasing Auto-Renewing Subscriptions Fails (Unknown Error) #47
Comments
Since this plugin is delivered by Also, please give a |
Have you logged out of the device and only use a Sandbox account when the purchase dialog appears in app? I've seen this error when testing a purchase but have forgotten to log out of the device's account. Don't forget to not login to the device with the Sandbox account either or it will create a "real" user Update: You get this error when trying to access IAP on iOS when using a proxy (like Charles) as well |
Is this issue still open? |
I do not understand what you mean by the various log in log out tips. I'm running into this as well. With a real account and with a sandbox account. I would consider this open... |
I'm running into this issue as well with a non-renewing subscription. The error log is below. I've confirmed that I can get this IAP to work with a Sandbox User in a previous version of the app that was built using only Swift. Purchase Started !! Purchase Failed !! |
same for us, identical behavior only for renewable products Version of flutter_inapp_purchase Platforms you faced the error (IOS or Android or both?) Expected behavior Actual behavior Tested environment (Emulator? Real Device?) |
Before testing, have you logged out of your device by going to Settings -> TAP Your name Apple ID at the top -> Sign Out Then do the purchase again. You will be prompted to login with your Apple ID, use the Sandbox user. |
getting the same things as tjviking. I started using this plugin 2 days ago for the first time. I've test in_app purchases before as an IOS developer, first time with flutter. I am logging in with sandbox account when trying to purchase and it is successfully pulling down the products for display. Purchase Started !! Purchase Failed !! |
@jodymac @tjviking I had this same exact issue. Switching to the Google Flutter team plugin was the best way to solve this. This exact error was reported out differently by this other plugin and it was much easier to debug. Link here: https://pub.dev/packages/in_app_purchase |
Thanks. I don’t suppose you could send an example of working code for this. I found very little on the internet to work with and the example doesn’t work for me. I am trying to download two subscriptions and be able purchase them, on iOS first.
… On Jun 13, 2019, at 4:45 PM, ericduffett ***@***.***> wrote:
@jodymac <https://github.com/jodymac> @tjviking <https://github.com/tjviking> I had this same exact issue. Switching to the Google Flutter team plugin was the best way to solve this. This exact error was reported out differently by this other plugin and it was much easier to debug. Link here: https://pub.dev/packages/in_app_purchase <https://pub.dev/packages/in_app_purchase>
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#47>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AF7MOFFT7XPX6KCFDPXQPETP2LLZPANCNFSM4GATPQHQ>.
|
subscriptions download ok for me I can show products, but when calling buyProduct or buySubscription with valid SKU , I got PlatformException which states that Product id is wrong, which is not possible, product was added and accepted by Appstore connect and is valid @jodymac maybe you do not use non-consumable subscription product, if its non-consumable non-subscription product it all works ok |
@jodymac @tjviking I'm thinking back on this and how I fixed it after switching plugins. One thing that came to mind is that I think one of the issues I ran into was that I hadn't accepted the latest agreements from apple in appstoreconnect or my apple developer account. Before you do any more coding, try going there and making sure you've accepted the latest terms and conditions on both platforms. I don't have any code for auto-renewing subscriptions, but I have successfully implemented non-renewing subscriptions by treating them like a consumable. I don't have any code I can share, but I am happy to move this chat to another channel to discuss in more detail. |
I suppose we should move this somewhere else. But, I have it downloading and buying. Just need to parse receipts so I can keep features enabled on valid subscription and the required restore button for purchase in the app store.
… On Jun 14, 2019, at 5:08 AM, ericduffett ***@***.***> wrote:
@jodymac <https://github.com/jodymac> @tjviking <https://github.com/tjviking> I'm thinking back on this and how I fixed it after switching plugins. One thing that came to mind is that I think one of the issues I ran into was that I hadn't accepted the latest agreements from apple in appstoreconnect or my apple developer account. Before you do any more coding, try going there and making sure you've accepted the latest terms and conditions on both platforms.
I don't have any code for auto-renewing subscriptions, but I have successfully implemented non-renewing subscriptions by treating them like a consumable. I don't have any code I can share, but I am happy to move this chat to another channel to discuss in more detail.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#47>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AF7MOFHQJQEX2TMOVJTKE4TP2OC4LANCNFSM4GATPQHQ>.
|
I just had the error
Trying to purchase an autorenewing subscription while still logged in as a previous sandbox user. I forgot to sign out at Settings -> iTunes and App Store -> Scroll down to SANDBOX ACCOUNT When testing an autorenewing purchase you need to create a new sandbox account each time you want to test a purchase |
Yes, I've test with sandbox user and on my actual device. Didn't make a difference. I was really hoping to use this plugin as it's apparent the developer had put some thought into it and the example/documentation was much better than the others. I switched to in_app_purchase and have successfully initiated purchases, but am trying to figure out restore and checking receipt for expiration date on subscription. |
I switched to in_app_purchase and it works nicely with subscriptions, so stop wasting you time :P move on |
Sorry that I was so busy these days and couldn't follow up all the threads promptly. I knew that I am thinking of deprecating this plugin and recommend users to use official one instead. |
|
This issue is still happening for me. I am using the flutter_inapp_purchase: ^5.1.2 version. This issue is happening in the Sandbox environment. |
Version of flutter_inapp_purchase
0.8.5
Platforms you faced the error (IOS or Android or both?)
iOS
Expected behavior
Purchase of auto-renewing subscription would work.
Actual behavior
Fetching of the products works as expected, however, when I call buyProduct on the item (an auto-renewing subscription), the transaction fails and the error message is: "An unknown or unexpected error has occurred. Please try again later." Tried to debug in XCode and can only see that the transaction state goes from purchasing to failed. I've checked that in app purchases are enabled in capabilities in the XCode project, all the products are set up appropriately in AppStoreConnect, and canMakePurchases returns true every time. Curious if anyone has run into this issue and what was done to mitigate. Thanks!
Tested environment (Emulator? Real Device?)
Real device
The text was updated successfully, but these errors were encountered: