Closed shagufta-codit closed 1 year ago
Hi,
Could you let me know which release of the library you are using?
https://github.com/googleads/google-ads-java/releases
Also, please share how you are declaring your dependencies. It may also be useful to share the output from mvn dependency:tree
(if using Maven) or ./gradlew dependencies
(if using Gradle). This looks like a dependency issue to me.
Thanks, Josh, Google Ads API Team
Hi Josh,
I am using this library: Google Ads API Client Library for Java - v26.0.0
Maven dependency I am using is:
<dependency>
Thanks, Shagufta
On Fri, Sep 22, 2023 at 7:12 PM Josh Radcliff @.***> wrote:
Hi,
Could you let me know which release of the library you are using?
https://github.com/googleads/google-ads-java/releases
Also, please share how you are declaring your dependencies. It may also be useful to share the output from mvn dependency:tree (if using Maven) or ./gradlew dependencies (if using Gradle). This looks like a dependency issue to me.
Thanks, Josh, Google Ads API Team
— Reply to this email directly, view it on GitHub https://github.com/googleads/google-ads-java/issues/736#issuecomment-1731443322, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATMD6OCIRX6SZKCQ2QYSI3LX3WIUVANCNFSM6AAAAAA5C4NA4M . You are receiving this because you authored the thread.Message ID: @.***>
Could you share the output from the following command?
mvn dependency:tree
On Fri, Sep 22, 2023 at 7:25 PM Josh Radcliff @.***> wrote:
Could you share the output from the following command?
mvn dependency:tree
— Reply to this email directly, view it on GitHub https://github.com/googleads/google-ads-java/issues/736#issuecomment-1731464837, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATMD6OH2XQPY5YMW3TAWYKDX3WKDPANCNFSM6AAAAAA5C4NA4M . You are receiving this because you authored the thread.Message ID: @.***>
I see you have dependencies on the following libraries for the old, sunset AdWords API:
com.google.api-ads:ads-lib:4.2.0
com.google.api-ads:adwords-axis:4.2.0
Since that API is completely shut down, you shouldn't need those anymore, and those dependencies are pulling in outdated versions of some libraries such as com.google.http-client:google-http-client:1.23.0
. That's what is leading to the error you're seeing.
Please remove those two dependencies and let me know if you still encounter issues.
Thanks, Josh
I'm closing this issue since removing the old AdWords API dependencies from your project should fix it. If you still encounter issues after making that change, feel free to reopen this issue.
Thanks, Josh, Google Ads API Team
@shagufta-codit I just received an alert because your first post on this issue included your refreshToken
. Please do the following:
Thank you
Describe the bug: While Upgrading the version for Google Ads API from v13 to v14, I am getting below Exception when trying to add budget for campaign creation.
Its failing while trying to make below call while sending request to create campaign
CampaignBudgetServiceClient campaignBudgetServiceClient = googleAdsClient.getLatestVersion().createCampaignBudgetServiceClient()
On further investigation we figured that its failing while executing this function GrpcOperationsStub, The client context its using is as below:
ClientContext{backgroundResources=[GrpcTransportChannel{managedChannel=com.google.api.gax.grpc.ChannelPool@663e4405}, com.google.api.gax.core.ExecutorAsBackgroundResource@40a30edc, com.google.api.gax.rpc.Watchdog@1a5589fc], executor=java.util.concurrent.ScheduledThreadPoolExecutor@ce1ef8f[Running, pool size = 1, active threads = 0, queued tasks = 1, completed tasks = 0], credentials=UserCredentials{requestMetadata=null, temporaryAccess=null, clientId=994750371900-uljdn20laj671ni2laj28cqmnjp26ouo.apps.googleusercontent.com, tokenServerUri=https://oauth2.googleapis.com/token, transportFactoryClassName=com.google.auth.oauth2.OAuth2Utils$DefaultHttpTransportFactory, quotaProjectId=null}, transportChannel=GrpcTransportChannel{managedChannel=com.google.api.gax.grpc.ChannelPool@663e4405}, headers={}, internalHeaders={x-goog-api-client=gl-java/1.8.0_382 gapic/26.0.0 gax/2.29.0 grpc/1.55.1}, clock=com.google.api.core.NanoClock@186b8c7a, defaultCallContext=com.google.api.gax.grpc.GrpcCallContext@9a9cd06d, streamWatchdog=com.google.api.gax.rpc.Watchdog@1a5589fc, streamWatchdogCheckInterval=PT10S, endpoint=googleads.googleapis.com:443, quotaProjectId=null, tracerFactory=com.google.api.gax.tracing.BaseApiTracerFactory@75d4cb0d}
Steps to Reproduce:
Exception: java.lang.reflect.InvocationTargetException [java.lang.NoSuchMethodError: com.google.api.client.util.escape.PercentEscaper.(Ljava/lang/String;)V]
Expected behavior:
The request should have went through and created a campaign for the same
Client library version and API version: Client library version: java 8 Google Ads API version: V14 JDK version: 1.8
Request/Response Logs:
Anything else we should know about your project / environment: