This repository was archived by the owner on Mar 11, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 89
This repository was archived by the owner on Mar 11, 2022. It is now read-only.
Android Sync Update (1.1.3) Causes Failed to get cookie from server error when using API key permissions #415
Copy link
Copy link
Closed
Description
I have tested this from 1.1.2 (which works fine) and 1.1.3, which causes the following error when attempting to utilize api Key permissions:
E/CookieInterceptor: Failed to get cookie from server, response code {0}, cookie authentication will not be attempted again
Batch 0 ended with error:
CouchException: error: unauthorized, reason: _reader access is required for this request, statusCode: 401, msg: Unauthorized, cause: java.io.FileNotFoundException: https://f80a1a79-5d2f-4fe1-8ff3-f78abcad4fb1-bluemix.cloudant.com:443/ocimaoi/_bulk_get
at com.cloudant.mazha.CouchClient$ExecuteResult.<init>(CouchClient.java:139)
at com.cloudant.mazha.CouchClient$ExecuteResult.<init>(CouchClient.java:89)
at com.cloudant.mazha.CouchClient.execute(CouchClient.java:193)
at com.cloudant.mazha.CouchClient.isBulkSupported(CouchClient.java:749)
at com.cloudant.sync.replication.CouchClientWrapper.isBulkSupported(CouchClientWrapper.java:280)
at com.cloudant.sync.replication.PullStrategy.run(PullStrategy.java:176)
at java.lang.Thread.run(Thread.java:818)
Caused by: java.io.FileNotFoundException: https://f80a1a79-5d2f-4fe1-8ff3-f78abcad4fb1-bluemix.cloudant.com:443/ocimaoi/_bulk_get
at com.android.okhttp.internal.huc.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:238)
at com.android.okhttp.internal.huc.DelegatingHttpsURLConnection.getInputStream(DelegatingHttpsURLConnection.java:210)
at com.android.okhttp.internal.huc.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java)
at com.cloudant.http.HttpConnection.responseAsInputStream(HttpConnection.java:420)
at com.cloudant.mazha.CouchClient.execute(CouchClient.java:176)
at com.cloudant.mazha.CouchClient.isBulkSupported(CouchClient.java:749)
at com.cloudant.sync.replication.CouchClientWrapper.isBulkSupported(CouchClientWrapper.java:280)
at com.cloudant.sync.replication.PullStrategy.run(PullStrategy.java:176)
at java.lang.Thread.run(Thread.java:818)
Note: setting the default permissions for all users does not cause this error. Only when I attempt to use specific api key credentials with version 1.1.3 does this occur.