You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.

Forum Discussion

Jose L.8's avatar
Jose L.8
Explorer | Level 3
5 years ago

BadResponseException: Bad JSON: expected object value

Hi,

we are getting few errors of this kind 

com.dropbox.core.BadResponseException: Bad JSON: expected object value.
 at [Source: java.io.ByteArrayInputStream@3f3408aa; line: 1, column: 143897]
	at com.dropbox.core.v2.DbxRawClientV2$1.execute(DbxRawClientV2.java:158)
	at com.dropbox.core.v2.DbxRawClientV2.executeRetriable(DbxRawClientV2.java:330)
	at com.dropbox.core.v2.DbxRawClientV2.executeRetriableWithRefresh(DbxRawClientV2.java:351)
	at com.dropbox.core.v2.DbxRawClientV2.rpcStyle(DbxRawClientV2.java:137)
	at com.dropbox.core.v2.teamlog.DbxTeamTeamLogRequests.getEventsContinue(DbxTeamTeamLogRequests.java:101)
	at com.dropbox.core.v2.teamlog.DbxTeamTeamLogRequests.getEventsContinue(DbxTeamTeamLogRequests.java:127)
....
Caused by: com.fasterxml.jackson.core.JsonParseException: expected object value.
 at [Source: java.io.ByteArrayInputStream@3f3408aa; line: 1, column: 143897]
	at com.dropbox.core.stone.StoneSerializer.expectStartObject(StoneSerializer.java:91)
	at com.dropbox.core.v2.teamlog.TeamEvent$Serializer.deserialize(TeamEvent.java:530)
	at com.dropbox.core.v2.teamlog.TeamEvent$Serializer.deserialize(TeamEvent.java:480)
	at com.dropbox.core.stone.StructSerializer.deserialize(StructSerializer.java:21)
	at com.dropbox.core.stone.StoneSerializers$ListSerializer.deserialize(StoneSerializers.java:320)
	at com.dropbox.core.stone.StoneSerializers$ListSerializer.deserialize(StoneSerializers.java:299)
	at com.dropbox.core.v2.teamlog.GetTeamEventsResult$Serializer.deserialize(GetTeamEventsResult.java:196)
	at com.dropbox.core.v2.teamlog.GetTeamEventsResult$Serializer.deserialize(GetTeamEventsResult.java:161)
	at com.dropbox.core.stone.StructSerializer.deserialize(StructSerializer.java:21)
	at com.dropbox.core.stone.StoneSerializer.deserialize(StoneSerializer.java:66)
	at com.dropbox.core.v2.DbxRawClientV2$1.execute(DbxRawClientV2.java:150)

We are using Dropbox Java SDK latest version, 3.1.3. and we are iterating over the team log.

Find attached some request ids that are failing:

8fd15839028f92488d826a573df1c765

c56e8d70b7f0702ff048c0c5b1b7a97d

8e96c5be98fb3c8e87b9b0410215127b

 

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Staff rankDropbox Staff

    Thanks for the report! It looks like the SDK is receiving invalid JSON for some reason. I'm not aware of anything that should be causing that right now, and I can't seem to reproduce this myself, so we'll need to look into it specifically for you.

     

    Would you be able to print out the problematic response body? That may help show what the issue is. For instance, you could reproduce the call outside the SDK by calling /2/team_log/get_events/continue by plugging in your access token and the relevant cursor. Please feel free to open an API ticket if you'd prefer to share privately. Either way though, please don't share your access token.

      • Greg-DB's avatar
        Greg-DB
        Icon for Dropbox Staff rankDropbox Staff

        Thanks! That's very helpful. We have your ticket and are working on reproducing and investigating this issue based on that information. We'll follow up with you once we have an update on that.

  • guymayor's avatar
    guymayor
    Explorer | Level 4

     

    Hey,

     

    I have the same issue, do you have any status update fro this ticket?

    • Greg-DB's avatar
      Greg-DB
      Icon for Dropbox Staff rankDropbox Staff

      guymayor Thanks for checking in. We were able to reproduce this issue internally. This is now open with engineering, but I don't have an update on it yet. I'll follow up here once I do.

      • Greg-DB's avatar
        Greg-DB
        Icon for Dropbox Staff rankDropbox Staff

        This should be working properly in the latest version of the SDK. Please give that a try and let us know if there are still any issues with that. Thanks!