iOS Development In-App Purchase (IAP) Endless Loop Solution
When developing an iOS app, I have learned from experience that you should NEVER delete a Sandbox test user. If you do and that user has some open In-App purchase (IAP) transactions, you will end up with an endless loop of this dialog box:
Note that it says, “Enter the password for”, but does not give you the username email that it is requesting a password for.
I could not remember any of the passwords I used, so I attempted several possibilities. The dialog would just reappear after I tapped Continue. After a couple tries of (probably) entering the wrong password, I got this different dialog box:
Eureka! This dialog actually showed the username email!
Now, I don’t remember the exact sequence of things and, honestly, I don’t want to recreate the problem ;-) However, the following is my best recollection. YMMV
I tapped Settings on the above dialog. Something said my account was locked, but I could reset the password. I was a bit concerned that I was locked out of my real Apple account, but tapped the reset password link anyways. The next screen said I could get an email or answer the secret question. I tried to answer the secret question, but it started with the birthday which didn’t work. As such, I went back and tried the email option.
I checked the email account shown in the dialog box above and, low and behold, there was a password reset email! I clicked the link and set a new password. The next time the endless loop dialog box appeared, I entered the new password. So far, I have not received another of those dialogs!
I hope this helps you if you are experiencing this issue. I’ve been working with Apple developer tech support for over a month with no resolution, despite telling them exactly what the problem was.
Here are some tips for setting up Sandbox Testers:
- If you can, set up a “catch-all” email account. I don’t know if all services have this, but I had an unused domain and mailbox account on HotpointDomains.com which has this feature. Basically, any email to the @domain is redirected to one email account. This lets you dream up any email you want for Sandbox tester emails and you only need to look in one inbox.
- Make sure you can remember the password later…obviously.
- Finally, NEVER delete a Sandbox Tester for your project!