{"action":"created","issue":{"url":"https://api.github.com/repos/cloudant/java-cloudant/issues/60","labels_url":"https://api.github.com/repos/cloudant/java-cloudant/issues/60/labels{/name}","comments_url":"https://api.github.com/repos/cloudant/java-cloudant/issues/60/comments","events_url":"https://api.github.com/repos/cloudant/java-cloudant/issues/60/events","html_url":"https://github.com/cloudant/java-cloudant/issues/60","id":91918193,"number":60,"title":"Fetching docs from cloudant using java-cloudant APIs","user":{"login":"Everly-Okorji","id":5440761,"avatar_url":"https://avatars.githubusercontent.com/u/5440761?v=3","gravatar_id":"","url":"https://api.github.com/users/Everly-Okorji","html_url":"https://github.com/Everly-Okorji","followers_url":"https://api.github.com/users/Everly-Okorji/followers","following_url":"https://api.github.com/users/Everly-Okorji/following{/other_user}","gists_url":"https://api.github.com/users/Everly-Okorji/gists{/gist_id}","starred_url":"https://api.github.com/users/Everly-Okorji/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Everly-Okorji/subscriptions","organizations_url":"https://api.github.com/users/Everly-Okorji/orgs","repos_url":"https://api.github.com/users/Everly-Okorji/repos","events_url":"https://api.github.com/users/Everly-Okorji/events{/privacy}","received_events_url":"https://api.github.com/users/Everly-Okorji/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-06-29T21:49:19Z","updated_at":"2015-07-22T22:20:38Z","closed_at":"2015-07-22T22:20:38Z","body":"I tried calling db.view(\"_all_docs\").includeDocs(true).query(JSONObject.class) on my code but I'm getting weird errors about Gson, and it raised an exception:\r\njava.lang.IllegalArgumentException: Invalid type of value. Type: [com.google.gson.internal.LinkedTreeMap] with value: [my_json_but_with_all_quotes_stripped]\r\n\r\nWhen I called the function with Object.class instead of JSONObject.class, I got an Object which, when printed, looks almost like JSON but with all of the quotes stripped out (even for strings with whitespace). \r\n\r\nWhen I called the function with String.class, I got some error along the lines of \"Expected STRING but found BEGIN_OBJECT\"."},"comment":{"url":"https://api.github.com/repos/cloudant/java-cloudant/issues/comments/123887214","html_url":"https://github.com/cloudant/java-cloudant/issues/60#issuecomment-123887214","issue_url":"https://api.github.com/repos/cloudant/java-cloudant/issues/60","id":123887214,"user":{"login":"Everly-Okorji","id":5440761,"avatar_url":"https://avatars.githubusercontent.com/u/5440761?v=3","gravatar_id":"","url":"https://api.github.com/users/Everly-Okorji","html_url":"https://github.com/Everly-Okorji","followers_url":"https://api.github.com/users/Everly-Okorji/followers","following_url":"https://api.github.com/users/Everly-Okorji/following{/other_user}","gists_url":"https://api.github.com/users/Everly-Okorji/gists{/gist_id}","starred_url":"https://api.github.com/users/Everly-Okorji/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Everly-Okorji/subscriptions","organizations_url":"https://api.github.com/users/Everly-Okorji/orgs","repos_url":"https://api.github.com/users/Everly-Okorji/repos","events_url":"https://api.github.com/users/Everly-Okorji/events{/privacy}","received_events_url":"https://api.github.com/users/Everly-Okorji/received_events","type":"User","site_admin":false},"created_at":"2015-07-22T22:20:38Z","updated_at":"2015-07-22T22:20:38Z","body":"My app was supposed to be pretty basic, and so the amount of work required relative to my code is pretty high. Thanks for the suggestion though!\r\n\r\nI'll go ahead and mark this as solved because I found a workaround that works temporarily."}}