IPad App purchase fails SKErrorPaymentCancelled and "Unable to connect to iTunes Store"

Possible Duplicate:
iPhone storekit sandbox has stopped working.

Hey.

I upgraded to iPad iOS version 3.2.2 today and I noticed my in App Purchase testing was not working.
I am using a test account and all users have been working so far (our app has been running since June and is real in in-app purchases), but today I wanted to make a trial purchase with the same product and test the user I have always used and now he does not work.

The problem is this:

  • I am running an in-app purchase.
  • Confirm your purchase and sign in with a test user.
  • Since this is a non-consumable product, the App Store notifies me that I have already purchased it, but it has not been downloaded.
  • Click OK.
  • So far, the transaction watcher has received a transaction with START SKPaymentTransactionStatePurchased and the user has received his function in the application.
  • But now TransactionState is SKPaymentTransactionStateFailed with error:

    Domain Error = SKErrorDomain Code = 2 UserInfo = 0x2debe0 "Unable to connect to iTunes Store"

Code = 2 means SKErrorPaymentCancelled. WTF? This should happen if the user canceled the transaction, not a real error. This is very misleading. I shouldn't show this as an error because most of the time this is thrown if the user actually cancels their purchase and there is no way to determine if this error was caused by the user or the app store.

Everything is set up correctly as I mentioned app purchase testing and I am getting these products as valid. Also I haven't changed the code handling when purchasing the app.

The error must be somewhere on the app store side.

Has anyone else had this problem?

Thanks.

Update

I tested the app on an iPhone (this is a universal app) running iOS 4.0.2 and the error looks like this:

Domain Error = SKErrorDomain Code = 0 "Unable to connect to iTunes Store" UserInfo = 0x2620e0 {NSLocalizedDescription = Unable to connect to iTunes Store}

Code = 0 is SKErrorUnknown and the application displays the error to the user.
Thus, it seems that iOS 4.0.2 handles this problem better than iOS 3.2.2.

+1


a source to share


1 answer


I tested again and luckily the problem seems to go away. I can test the in-app purchase without any problem.



I hope this now works for others as well.

0


a source







All Articles