onepf / OpenIAB

Open In-App Billing for Google Play, SlideMe, Amazon Store, Nokia Store, Samsung Apps, Yandex.Store, Appland, Aptoide, AppMall and Fortumo.
http://onepf.org/openiab/
Apache License 2.0
476 stars 171 forks source link

Amazon In App Purchase fails with Amazon App Tester: IabResult: 6, Current UserId doesn't match purchase UserId #472

Closed sergeyvl closed 9 years ago

sergeyvl commented 9 years ago

Hi!

D/pbchess (23911): Purchase finished: IabResult: 6, Current UserId doesn't match purchase UserId (response: 6:Error), purchase: PurchaseInfo(type:inapp): {"orderId":null,"packageName":null,"productId":license,"purchaseTime":0,"purchaseState":0,"developerPayload":null,"token":q1YqVrJSyslMTs0rTlXSUUoB8gxNjCxMzC1MLS0MzM2BYqUgFcYePuYRBQWuvhlF_u4ueaVFlrqlOWWF-blFwelmhZX-Lt65iRnmZjleobZALSVKVoa1AA}

queryInventory() also shows that item is not purchased. But:

  1. I can see this purchase in Amazon App Tester
  2. If I try to purchase this item again, I get: "IabResult: 7, Item is already purchased"

Libs used: openiab-0.9.8.6.jar, in-app-purchasing-2.0.1.jar (also tried with the latest in-app-purchasing-2.0.61.jar - the same result)

RomanZhilich commented 9 years ago

Hi.

I'm pretty sure this issue is only relevant to App Tester. Most likely you change Amazon User option under 1. User Account Settings tab. Real Amazon Store shouldn't return items purchased by another user.

sergeyvl commented 9 years ago

Roman, I used user 1 in App Tester and didn't change this setting. I see in the logs that purchase UserId is empty while current UserId is my App Tester user 1.

RomanZhilich commented 9 years ago

Well, this is weird. Can't you use Delete All option under 3. Manage Transactions tab and try to reproduce this?

sergeyvl commented 9 years ago

I deleted my purchase and tried again several times. Is is reproduced constantly every time I make purchase.

sergeyvl commented 9 years ago

Hmm... Just re-tested it with my HTC Sensation XE. Purchase works well... But on my Cube Talk 9x tablet this problem is stable reproducible.

RomanZhilich commented 9 years ago

As I said, I'm pretty sure App Tester is to blame for this. If you use OpenIAB in your application, I recommend trying to reproduce it with Amazon live testing.

sergeyvl commented 9 years ago

So, It is not quite clear whether it is App Tester problem or Open IAB library problem. Anyway, thanks for help. I'll use live testing.

RomanZhilich commented 9 years ago

Please reopen this issue if you find anything.