rlalfo / google-http-java-client

Automatically exported from code.google.com/p/google-http-java-client
0 stars 0 forks source link

Tasks API not working with this version #233

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Version of google-http-java-client (e.g. 1.15.0-rc)?
v-1.13.1

Java environment (e.g. Java 6, Android 2.3, App Engine)?
java 6
Describe the problem.

when using this version of jar, i am not able to use tasks api.
I get the following error 
java.lang.NoSuchMethodError:com.google.api.client.http.HttpRequest.setAllowEmpty
Content(Z)Lcom/google/api/client/http/HttpRequest;
    at com.google.api.client.googleapis.services.GoogleClient.buildHttpRequest(GoogleClient.java:171)
    at com.google.api.client.http.json.JsonHttpRequest.buildHttpRequest(JsonHttpRequest.java:179)
    at com.google.api.client.http.json.JsonHttpRequest.executeUnparsed(JsonHttpRequest.java:207)
    at com.google.api.services.tasks.Tasks$Tasklists$List.execute(Tasks.java:1731)

This occurs even in the latest jar.
Can you please let me know what should I do to fix this...I cannot use older 
version, because the Adwords API doesnt work with the older version

Original issue reported on code.google.com by vjchauha...@gmail.com on 28 Jun 2013 at 12:49

GoogleCodeExporter commented 9 years ago
This issue is unrelated to the Tasks API. The method you are trying to call, 
setAllowEmptyContent, was deprecated in version 1.11 and removed in 1.12. Use 
setContent(new EmptyContent()) instead.

Original comment by ngmic...@google.com on 28 Jun 2013 at 2:19