robotmedia / RMStore

A lightweight iOS library for In-App Purchases
Apache License 2.0
2.42k stars 450 forks source link

"Cannot connect to iTunes Store" when a user doesn't have the payment info #195

Open rhwu opened 7 years ago

rhwu commented 7 years ago

Hi,

Thanks for RMStore, it's awesome! We got this problem which can only be reproduced with a production version app. Any thoughts?

Steps to reproduce: 1) An app with IAP using RMStore. 2) An iTunes account without payment info 3) Try to buy something 4) Saw Apple dialog asking user to provide billing info 5) Press "Continue" to switch to the iTunes account settings 6) At the meantime, in the app, the [RMStore defaultStore] addPayment call got a failure callback with "Cannot connect to iTunes Store".

Is there a way to distinguish this case from other failure cases? User may just provide the billing info and complete the purchase. When they come back to the app, we don't want to show them an error.

Thanks in advance!

ed-at-work commented 7 years ago

Are you sure you're not just running into the limitation that you can't test In-App Purchase on the Simulator at all? To test IAP in a non-production scenario, you need to be using an actual Apple device with your app installed with a development certificate.