skip to Main Content

I’m trying to implement the StoreKit2 API to implement IAPs, but keep getting the error Error Domain=ASDErrorDomain Code=509 "No active account".

I’ve researched online but can’t find ANY information about different ASDErrorDomain error codes. Does anyone know what this error means?

If you’re curious, my full error log is below.

2022-05-31 02:33:35.491370-0500 (app name deleted for privacy) [Default] Error enumerating unfinished transactions for first transaction listener: Error Domain=ASDErrorDomain Code=509 "No active account" UserInfo={NSLocalizedDescription=No active account}
2022-05-31 02:33:35.884686-0500 (app name deleted for privacy) [Default] [StoreKit] Failed to get products through appstored in simulator, will try using appstoreagent on host mac:
Error Domain=ASDErrorDomain Code=507 "Error decoding response" UserInfo={NSLocalizedDescription=Error decoding response, NSLocalizedFailureReason=Could not decode media products response}
2022-05-31 02:33:36.296678-0500 (app name deleted for privacy) [Default] Error enumerating monthlySubscription current transactions: Error Domain=ASDErrorDomain Code=509 "No active account" UserInfo={NSLocalizedDescription=No active account}
objc[16313]: Class _PathPoint is implemented in both /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot/System/Library/PrivateFrameworks/UIKitCore.framework/UIKitCore (0x126673338) and /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot/System/Library/PrivateFrameworks/TextInputUI.framework/TextInputUI (0x137570fe8). One of the two will be used. Which one is undefined.
objc[16313]: Class _PointQueue is implemented in both /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot/System/Library/PrivateFrameworks/UIKitCore.framework/UIKitCore (0x126673310) and /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot/System/Library/PrivateFrameworks/TextInputUI.framework/TextInputUI (0x137571010). One of the two will be used. Which one is undefined.

3

Answers


  1. I did some googling myself and could not find much but ran into this link https://developer.apple.com/forums/thread/660287 which tells me your device is not connected to the Apple Store therefore unable to proceed to the usage of StoreKit. Go to the settings and tap on the first section of it where the profile picture is and sign in with a valid appleid.
    I hope this helps!

    Login or Signup to reply.
  2. You can test IAP in the simulator without connecting to the App Store. In this case, the project is not set up to do so by default. You have to select the included StoreKit configuration under the build scheme’s run > options tab to get the SKDemo app running as expected.

    Figured it out by looking at these generic instructions for testing StoreKit. You may find some useful information here as well – https://developer.apple.com/documentation/xcode/setting-up-storekit-testing-in-xcode?language=objc

    Edit: It turns out it is actually in the instructions on the project site (duh) – https://developer.apple.com/documentation/storekit/in-app_purchase/implementing_a_store_in_your_app_using_the_storekit_api under "Configure the sample code project"

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search