[Solved] Purchasing Login Inconsistent

When I run our apk on my device, I’m able to log into purchasing without a problem.

Like this

05-31 13:57:28.738: I/UnityIAP(9727): invoking callback
05-31 13:57:28.738: I/UnityIAP(9727): Checking for in-app billing 3 support.
05-31 13:57:28.788: I/UnityIAP(9727): In-app billing version 3 supported for com.companyName.Project.Name
05-31 13:57:28.798: I/UnityIAP(9727): Subscriptions AVAILABLE.
05-31 13:57:28.798: I/UnityIAP(9727): onIabSetupFinished: 0
05-31 13:57:28.798: I/UnityIAP(9727): Requesting 3 products
05-31 13:57:28.798: I/UnityIAP(9727): QueryInventory: 3
05-31 13:57:28.798: I/UnityIAP(9727): invoking callback
05-31 13:57:28.798: I/UnityIAP(9727): Querying owned items, item type: inapp
05-31 13:57:28.798: I/UnityIAP(9727): Package name: com.companyName.Project.Name
05-31 13:57:28.798: I/UnityIAP(9727): Calling getPurchases with continuation token: null
05-31 13:57:28.808: I/UnityIAP(9727): Owned items response: 0
05-31 13:57:28.808: I/UnityIAP(9727): Continuation token: null
05-31 13:57:28.808: I/UnityIAP(9727): Querying SKU details.
05-31 13:57:28.898: I/UnityIAP(9727): Got sku details: SkuDetails:{"title":"Purchase 100  Points  (Project.Name)","price":"$0.99","type":"inapp","description":"Purchase 100 points to use in project","price_amount_micros":990000,"price_currency_code":"USD","productId":"manoke_purchase_points_0"}
05-31 13:57:28.898: I/UnityIAP(9727): Got sku details: SkuDetails:{"title":"Purchase 1000 Points (Project.Name)","price":"$4.99","type":"inapp","description":"Purchase Points for use in (Project.Name)","price_amount_micros":4990000,"price_currency_code":"USD","productId":"manoke_purchase_points_1"}
05-31 13:57:28.898: I/UnityIAP(9727): Got sku details: SkuDetails:{"title":"Purchase 10,000 Points (Project.Name)","price":"$29.99","type":"inapp","description":"Purchase Points for use in project","price_amount_micros":29990000,"price_currency_code":"USD","productId":"manoke_purchase_points_2"}
05-31 13:57:28.898: I/UnityIAP(9727): Querying owned items, item type: subs
05-31 13:57:28.898: I/UnityIAP(9727): Package name: com.companyName.Project.Name

But when others run the apk it ends up failing the Purchasing Login and saying that it’s “Notifying Unity…”

05-31 18:26:34.998: I/UnityIAP(24876): invoking callback
05-31 18:26:34.998: I/UnityIAP(24876): Checking for in-app billing 3 support.
05-31 18:26:35.008: W/Finsky(19521): [780] InAppBillingService.getPreferredAccount: com.companyName.Project.Name: No account found.
05-31 18:26:35.008: W/Finsky(19521): [780] InAppBillingService.checkBillingEnabled: Billing unavailable for this package and user.
05-31 18:26:35.008: I/UnityIAP(24876): onIabSetupFinished: 3
05-31 18:26:35.008: I/UnityIAP(24876): Failed to setup IAB. Notifying Unity...

Any suggestions on the difference between the two…?

The first was on Android, the second on iOS. The iOS Purchasing wasn’t fully setup.

Hi @Mycroft ,

On line 4 of the first snippet, is “com.CompanyName” your bundle ID or did you edit it for privacy reasons?

Also, is the app currently in alpha/beta testing? If so, could it be possible that the devices that are testing this app not be authorized testers?

Lastly, is it possible that you could be running on an older version of the market? Running on an older version of the market can cause these issues and it is explained more in depth here.

Please let me know if this information was helpful.

Ray

2 Likes

Yes, edited for privacy.

I had updated to a recent version of Purchasing to avoid a recent error like this, so I was reasonably sure that wasn’t the case.

The problem turned out to be simple. I was testing on Android and another person was testing on iOS when I thought they were testing Android. The iOS store settings weren’t setup correctly and would fail. Once the iOS IAP were setup comparable to the Google Play IAP it started connecting fine.

Thanks for the update.

1 Like

@Mycroft , glad everything worked out! Feel free to reach out if you run into any other issues!

1 Like