Reputation: 3755
In my Ubuntu OS I am adding play-services-ads-identifier to android studio build.gradle like this:
implementation "com.google.android.gms:play-services-ads-identifier:17.0.0"
And it works fine. But In Windows OS when I add the exact same thing in dependencies it throws error and does not build. the message is like this:
Warning:project ':app': Unable to build Kotlin project configuration Details: org.gradle.api.internal.artifacts.ivyservice.DefaultLenientConfiguration$ArtifactResolveException: Could not resolve all files for configuration ':app:debugImplementationDependenciesMetadata'. Caused by: org.gradle.internal.resolve.ArtifactNotFoundException: Could not find play-services-ads-identifier.jar (com.google.android.gms:play-services-ads-identifier:17.0.0). Searched in the following locations: https://dl.google.com/dl/android/maven2/com/google/android/gms/play-services-ads-identifier/17.0.0/play-services-ads-identifier-17.0.0.jar
Upvotes: 2
Views: 4022
Reputation: 16407
i had same problem . it was solved with update gradle and android studio.
Upvotes: 1
Reputation: 3755
After carefully reading the error message I noticed that Gradle is looking for the jar file as it is provided by the link in the error message:
So I changed the dependency to this:
implementation "com.google.android.gms:play-services-ads-identifier:17.0.0@aar"
And it is working and building now. Hope it helps someone.
Upvotes: 4