6 Replies
      Latest reply on Jul 25, 2017 8:50 AM by fozoglu
      fozoglu Level 1 Level 1 (0 points)

        I developed an application in Swift language. I've added in-app purchases to remove ads. I also created a sandbox account to test. But then I forgot the information of this account. (I'm not sure of the information) The password entry screen is still displayed in a flashing screen display. Even if I reset the device and reload it, it did not benefit. Actually everything is working properly. This is my only problem.What should I do. I'm glad you helped me. Thank you.

        • Re: Sandbox test account asking password repeatedly for iOS In-App Purchase
          PBK Level 6 Level 6 (2,605 points)

          You may have a transaction in the StoreKit queue for which your test user did not call "finishTransaction".  Search the forum (circa 2015) for "the endless loop" to read about the horrors of having hundreds of these un-finishedTransaction-s.  You can contact Apple engineers (use a DTS ticket) and ask them to remove the transaction from the queue - but that can take months. 

            • Re: Sandbox test account asking password repeatedly for iOS In-App Purchase
              fozoglu Level 1 Level 1 (0 points)

              Thanks, really bad situation. Where can I send a link to ask Apple engineers? What is DTS? I'll mail them too. I hope they help me.

               

              • Re: Sandbox test account asking password repeatedly for iOS In-App Purchase
                fozoglu Level 1 Level 1 (0 points)

                Apple answered, but I already do what they say. I also do not want to reset my device. How am I supposed to solve this problem?

                 

                Answer :

                <. I also created a sandbox account to test. But then I forgot the information of this account.>

                Your issue may be due to one or more of the following reasons:

                 

                -You are running into a transient bug with the App Store. The workaround is restore the device to the latest iOS version. Note that doing so will reset your device to its factory default settings.

                 

                Create a new test user account in iTunes Connect. Make sure that you are signed out of the Store on your device before starting to test In-App Purchase on your device. Build and launch your app on your device, enter the new test user account when prompted by StoreKit to authenticate the purchase. Be sure to always use sandbox test user accounts created in iTunes Connect to test your In-App Purchase products. StoreKit connects to the sandbox environment when you launch your application from Xcode, from your test device (iOS), or from the Finder (OS X). It connects to a production environment for applications that were downloaded from the App Store. You must not use your test user account to sign into the production environment. This will result in your test user account becoming invalid. Invalid test accounts cannot be used to test In-App Purchase again.

                -You may have an unfinished transaction.  As such, you need to call finishTransaction: on the associated transaction to end the loop to resolve your issue. See TN2387 In-App Purchase Best Practices > Add a transaction queue observer at application launch  and Finish the transaction for more information  on how to prevent this issue.

                -You are calling SKReceiptRefreshRequest or restoreCompletedTransactions, which is prompting you to enter your username and password. If calling restoreCompletedTransactions, see When should I use SKPaymentQueue’ s restoreCompletedTransactions method? for more information. If calling SKReceiptRefreshRequest, that would be the expected behavior.

                accounts and it works properly. Even though I am deleted from the sandbox , the account continues to ask. >

                If your device still prompts you to log in with a deleted test user account, restore your device to the latest iOS version. Note that doing so will reset your device to its factory default settings.

                Be sure to not restore your device’s back up. Make sure that you are signed out of the Store on your device before starting to test In-App Purchase on your device. Build and launch your app on your device, enter the new test user account when prompted by StoreKit to authenticate the purchase.

                 

                Thanks.