I have an iOS App using Purchases SDK version 3.13.0
I have factory reset the iPad I am testing with.
I am running a development build (debug)
I have never made a purchase with this device after factory reset.
On startup of the app I will present an onboarding screen to purchase subscription.
My IAP has a 1 week free trial then a monthly subscription.
I call the API checkTrialOrIntroductoryPriceEligibility to try and know whether I should inform them if the free 1 week trial is available to them.
I was not expecting the dialog “Sign in with Apple ID to pop up” along with soft keyboard over the top of my onboarding screen.
Is this expected behavior? I would prefer the Apple dialog “Sign in with Apple ID” be user initiated.
I see the following Purchases Log in console if that helps.
2021-11-19 11:16:08.928454-0700 Pick 3 ProP582:34641] 8Purchases] - DEBUG: Debug logging enabled
2021-11-19 11:16:08.928736-0700 Pick 3 Pro7582:34641] rPurchases] - DEBUG: SDK Version - 3.13.0
2021-11-19 11:16:08.928835-0700 Pick 3 Pro3582:34641] Purchases] - DEBUG: Initial App User ID - (null)
2021-11-19 11:16:08.931387-0700 Pick 3 Pro3582:34641] iPurchases] - DEBUG: Sending latest PurchaserInfo to delegate.
2021-11-19 11:16:08.936017-0700 Pick 3 Pro0582:34641] 0Purchases] - DEBUG: Delegate set
2021-11-19 11:16:09.418896-0700 Pick 3 Pro:582:34641] 6Purchases] - DEBUG: applicationDidBecomeActive
2021-11-19 11:16:09.448353-0700 Pick 3 Pro9582:34861] 4Purchases] - DEBUG: There are no requests currently running, starting request GET /subscribers/$RCAnonymousID0X0P+049b30dd0f61f47ceb05e72efa25738db
2021-11-19 11:16:09.448937-0700 Pick 3 Pro1582:34861] 0Purchases] - DEBUG: API request started: GET /v1/subscribers/$RCAnonymousID:49b30dd0f61f47ceb05e72efa25738db
2021-11-19 11:16:09.451094-0700 Pick 3 Pro0582:34861] :Purchases] - DEBUG: There's a request currently running and 0 requests left in the queue, queueing GET /subscribers/$RCAnonymousID0X0P+049b30dd0f61f47ceb05e72efa25738db/offerings
2021-11-19 11:16:10.110374-0700 Pick 3 Pron582:34872] 9Purchases] - DEBUG: API request completed with status: GET /v1/subscribers/$RCAnonymousID:49b30dd0f61f47ceb05e72efa25738db 304
2021-11-19 11:16:10.113116-0700 Pick 3 Pros582:34872] 1Purchases] - DEBUG: Serial request done: GET /subscribers/$RCAnonymousID0X0P+049b30dd0f61f47ceb05e72efa25738db, 1 requests left in the queue
2021-11-19 11:16:10.113732-0700 Pick 3 Pro<582:34872] 0Purchases] - DEBUG: Starting the next request in the queue, <RCHTTPRequest: httpMethod=GET
2021-11-19 11:16:10.114759-0700 Pick 3 Pro<582:34872] nPurchases] - DEBUG: There are no requests currently running, starting request GET /subscribers/$RCAnonymousID0X0P+049b30dd0f61f47ceb05e72efa25738db/offerings
2021-11-19 11:16:10.225105-0700 Pick 3 Proo582:34866] sPurchases] - DEBUG: API request completed with status: GET /v1/subscribers/$RCAnonymousID:49b30dd0f61f47ceb05e72efa25738db/offerings 304
2021-11-19 11:16:10.225469-0700 Pick 3 Pro/582:34866]
2021-11-19 11:16:10.226593-0700 Pick 3 Pro 582:34866]
2021-11-19 11:16:10.273867-0700 Pick 3 Proe582:34865] oPurchases] - DEBUG: Products request finished.
2021-11-19 11:16:10.273994-0700 Pick 3 Prot582:34865] /Purchases] - DEBUG: Retrieved SKProducts:
2021-11-19 11:16:10.274063-0700 Pick 3 Prod582:34865] :Purchases] - DEBUG: com.pick3pro.subscription1month - <SKProduct: 0x28211ae50>
2021-11-19 11:16:10.274131-0700 Pick 3 Pro:582:34865] 0Purchases] - DEBUG: 1 completion handlers waiting on products
2021-11-19 11:16:11.481293-0700 Pick 3 Pros582:34641] Purchases] - DEBUG: Vending PurchaserInfo from cache.
2021-11-19 11:16:12.100791-0700 Pick 3 ProP582:34641] oPurchases] - DEBUG: Vending PurchaserInfo from cache.
2021-11-19 11:16:12.105804-0700 Pick 3 Proi582:34641] rPurchases] - DEBUG: Vending Offerings from cache
2021-11-19 11:16:12.110026-0700 Pick 3 Pro582:34641] Purchases] - DEBUG: Loaded receipt from url file:///private/var/mobile/Containers/Data/Application/E0CFA6A3-3F7E-4D2B-BE56-484E6BEA38AD/StoreKit/sandboxReceipt
2021-11-19 11:16:12.110259-0700 Pick 3 Pro-582:34641] DPurchases] - DEBUG: Receipt empty, refreshing
2021-11-19 11:37:39.997045-0700 Pick 3 Pro-589:38729] <SKReceiptRefreshRequest: 0x281830680>: Finished refreshing receipt with error: Error Domain=ASDErrorDomain Code=907 "Unhandled exception" UserInfo={NSUnderlyingError=0x281600d80 {Error Domain=AMSErrorDomain Code=100 "Authentication Failed" UserInfo={NSLocalizedFailureReason=The verify credentials call failed., NSLocalizedDescription=Authentication Failed, NSUnderlyingError=0x281600de0 {Error Domain=AMSErrorDomain Code=6 "Authentication Failed" UserInfo={NSLocalizedFailureReason=User cancelled, NSLocalizedDescription=Authentication Failed, NSUnderlyingError=0x281600e40 {Error Domain=AMSErrorDomain Code=15 "An unknown error occurred. Please try again." UserInfo=0x2819ae420 (not displayed)}}}}}, NSLocalizedFailureReason=An unknown error occurred, NSLocalizedDescription=Unhandled exception}
2021-11-19 11:18:57.626731-0700 Pick 3 ProL582:34641] cPurchases] - ERROR: SKRequest failed: An unknown error occurred
2021-11-19 11:18:57.640056-0700 Pick 3 Pro582:34641] sPurchases] - DEBUG: Loaded receipt from url file:///private/var/mobile/Containers/Data/Application/E0CFA6A3-3F7E-4D2B-BE56-484E6BEA38AD/StoreKit/sandboxReceipt
2021-11-19 11:18:57.640431-0700 Pick 3 Pro-582:34641] EPurchases] - WARN: Unable to load receipt, ensure you are logged in to a valid Apple account.
2021-11-19 11:18:57.640689-0700 Pick 3 Pror582:34641] uPurchases] - WARN: App running on sandbox without a receipt file. Unable to determine into eligibility unless you've purchased before and there is a receipt available.
Is this just an issue with debug sandbox testing or should I expect the same behavior with a TestFlight or live environment of sign in dialog popping up in this case? If the answer is yes then I probably cannot use this API because I think its a bad user experience to ask someone to sign in when presenting an onboarding screen.