question

Cid avatar image
Cid asked ·

Error after purchasing subscription

Hi,

We are getting a java.lang.IllegalArgumentException thrown after we purchase a subscription in live app testing.

We are adding the user's email to the list of live app testers, we have the account registered on the device and even entered in the device's email client. We can star the purchase flow and see the native pop-up and can subscribe. But after this, we get this exception thrown in logcat :

The account that this AuthenticationMethod with is no longer registered

Account not registered: ***3Q. Registered accounts are: ***BQ

java.lang.IllegalArgumentException at com.amazon.identity.auth.device.utils.MAPLog.accountNotRegisteredError(MAPLog.java:259) at com.amazon.identity.auth.device.api.AuthenticationMethod.throwIfInvalidAccount(AuthenticationMethod.java:447) at com.amazon.identity.auth.device.api.AuthenticationMethod.authenticateConnection(AuthenticationMethod.java:136) at com.amazon.identity.auth.device.api.AuthenticatedHttpURLConnection.performOnConnectionRequested(AuthenticatedHttpURLConnection.java:78) at com.amazon.identity.auth.device.framework.WrappableHttpURLConnection.onConnectionRequested(WrappableHttpURLConnection.java:53) at com.amazon.identity.auth.device.framework.WrappableHttpURLConnection.connect(WrappableHttpURLConnection.java:153) at com.amazon.identity.auth.device.api.AuthenticatedHttpsURLConnection.connect(AuthenticatedHttpsURLConnection.java:174) at com.amazon.dcp.framework.iuc.ConnectionWrapper.connect(ConnectionWrapper.java:326) at com.amazon.dcp.framework.iuc.LoggingURLConnection.access$201(LoggingURLConnection.java:13) at com.amazon.dcp.framework.iuc.LoggingURLConnection$2.call(LoggingURLConnection.java:135) at com.amazon.dcp.framework.iuc.LoggingURLConnection$2.call(LoggingURLConnection.java:131) at com.amazon.dcp.framework.tracing.BaseTracer.trace(BaseTracer.java:34) at com.amazon.dcp.framework.tracing.BaseTracer.traceOnCurrentThread(BaseTracer.java:62) at com.amazon.dcp.framework.iuc.LoggingURLConnection.connect(LoggingURLConnection.java:130) at com.amazon.dcp.framework.iuc.ConnectionEstablisherWithExternalConnectionFactory.doEstablishConnectionWithBody(ConnectionEstablisherWithExternalConnectionFactory.java:118) at com.amazon.dcp.framework.iuc.ConnectionEstablisherWithExternalConnectionFactory.access$100(ConnectionEstablisherWithExternalConnectionFactory.java:20) at com.amazon.dcp.framework.iuc.ConnectionEstablisherWithExternalConnectionFactory$1.onBodyAvailable(ConnectionEstablisherWithExternalConnectionFactory.java:99) at com.amazon.dcp.framework.iuc.ConnectionWithBufferedOutput.processBody(ConnectionWithBufferedOutput.java:46) at com.amazon.dcp.framework.iuc.ConnectionWithBufferedOutput.access$000(ConnectionWithBufferedOutput.java:15) at com.amazon.dcp.framework.iuc.ConnectionWithBufferedOutput$1.close(ConnectionWithBufferedOutput.java:22) at com.amazon.org.apache.commons.io.IOUtils.closeQuietly(IOUtils.java:303) at com.amazon.org.apache.commons.io.IOUtils.closeQuietly(IOUtils.java:274) at com.amazon.dcp.framework.iuc.ConnectionEstablisherWithRetry.establishConnectionWithTimeout(ConnectionEstablisherWithRetry.java:193) at com.amazon.dcp.framework.iuc.ConnectionEstablisherWithRetry.doEstablishConnectionWithBody(ConnectionEstablisherWithRetry.java:113) at com.amazon.dcp.framework.iuc.ConnectionEstablisherWithRetry.access$200(ConnectionEstablisherWithRetry.java:26) at com.amazon.dcp.framework.iuc.ConnectionEstablisherWithRetry$1.onBodyAvailable(ConnectionEstablisherWithRetry.java:101) at com.amazon.dcp.framework.iuc.ConnectionWithBufferedOutput.processBody(ConnectionWithBufferedOutput.java:46) at com.amazon.dcp.framework.iuc.ConnectionWithBufferedOutput.access$000(ConnectionWithBufferedOutput.java:15) at com.amazon.dcp.framework.iuc.ConnectionWithBufferedOutput$1.close(ConnectionWithBufferedOutput.java:22) at com.amazon.org.apache.commons.io.IOUtils.closeQuietly(IOUtils.java:303) at com.amazon.org.apache.commons.io.IOUtils.closeQuietly(IOUtils.java:274) at com.amazon.dcp.framework.webrpc.CallExecutor.writeRequest(CallExecutor.java:164) at com.amazon.dcp.framework.webrpc.CallExecutor.doExecute(CallExecutor.java:114) at com.amazon.dcp.framework.webrpc.CallExecutor.access$100(CallExecutor.java:26) at com.amazon.dcp.framework.webrpc.CallExecutor$2.call(CallExecutor.java:98) at com.amazon.dcp.framework.webrpc.CallExecutor$2.call(CallExecutor.java:91) at com.amazon.dcp.framework.tracing.BaseTracer.trace(BaseTracer.java:34)

If we restart the app, the user is subscribe and everything works. It just that flow breaks on subscription and we do not get any callback because of this.

What could cause this? Is there anyway to fix it on our side? Will this happen only in Live App Testing?

Thanks!

iappurchasing
10 |2000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

Levon@Amazon avatar image
Levon@Amazon answered ·

Hi Cid,

Can you please login to your Dev Portal account, click on "Contact Us" and specify your app name / ID, the problematic IAP subscription SKU, the device you test it on and the exact OS version on it, the tools / framework you built your app with, and the country you / the tester test the app from? Include the URL to this forum post for context. Thanks!

10 |2000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.