How to interpretet `WARNING: CBL_Pusher[]: _bulk_docs got an error ... reason = "Exception in JS sync function"; status = 500; ..` ?

71 views
Skip to first unread message

Pelle Krøgholt

unread,
Jun 28, 2015, 8:40:12 AM6/28/15
to mobile-c...@googlegroups.com
hi,

I have an iOS app using couchbase lite ('couchbase-lite-ios', '1.0.4').

I can successfully do pull replication but when doing push I get warnings. The code in use (swift):


let manager = ...
let database = manager.databaseNamed(<db name>, error: &error)
database.createPullReplication(self._address)
replicate.start()
manager.close()

for new documents created at the device the push replication - do not push the new docs and raises warnings like:

13:45:54.064‖ WARNING: CBL_Pusher[https://<user-id>:*****@<syngateway address>/<db name>]: _bulk_docs got an error: {
    error = 500;
    id = "some-id";
    reason = "Exception in JS sync function";
    status = 500;
}

how should I interpret this error?

is the error on the iOS side or in the sync gate way or in the couchbase it self ?

//

pelle



ajres

unread,
Jun 28, 2015, 2:12:00 PM6/28/15
to mobile-c...@googlegroups.com
@Pelle

This looks like the Sync Gateway sync function is rejecting one of the revisions being pushed by the mobile client.

If you enable all log channels in Sync Gateway by adding the following top level property to your config .json 

"log": ["*"],


Restart Sync Gateway and try to push from the mobile client again, you should see the underlying reason that one or more of the revisions was rejected.


If you add the log to a gist and post the link here we can help diagnose the issue.


Andy

Jens Alfke

unread,
Jun 28, 2015, 8:27:18 PM6/28/15
to mobile-c...@googlegroups.com

On Jun 28, 2015, at 11:11 AM, ajres <an...@couchbase.com> wrote:

This looks like the Sync Gateway sync function is rejecting one of the revisions being pushed by the mobile client.

Not actually rejecting the revision, but throwing an unexpected exception. (If it rejected the revision, the error would be 403 and it wouldn’t be causing the replication to fail.)

There’s probably a bug in the sync function — dereferencing an undefined value or something like that. The Sync Gateway logs will have more info.

—jens

Pelle Krøgholt

unread,
Jun 29, 2015, 1:31:38 AM6/29/15
to mobile-c...@googlegroups.com
@jens @ajres

thanks a lot for the hints / explanations!

//

pelle
Reply all
Reply to author
Forward
0 new messages