1

I'm facing this error when I'm syncing my project, I've searched over the web and haven't gotten any results that gets me going forward

Error

ERROR: Failed to resolve: com.google.android.gms:play-services-base:17.2.0

Below are my dependencies

buildscript {
    repositories {
        mavenCentral()
        google()
        jcenter()
    }

    dependencies {
        classpath 'com.android.tools.build:gradle:3.5.0'
    }
}

    dependencies {
        implementation fileTree(dir: 'libs', include: '*.jar')
        // SUB-PROJECT DEPENDENCIES START
        implementation(project(path: ":CordovaLib"))
        implementation 'com.android.support:support-annotations:28.0.0'
        implementation 'com.android.support:support-v4:28.0.0'
        implementation 'com.android.support:support-v4:28.0.0'
        implementation 'com.android.support:support-v13:28.0.0'
        implementation 'me.leolin:ShortcutBadger:1.1.22@aar'
        implementation 'com.google.firebase:firebase-core:17.2.0'
        implementation 'com.google.firebase:firebase-messaging:20.0.0'
        implementation 'com.google.android.gms:play-services-base:17.2.0'
        implementation 'com.google.android.gms:play-services-ads:18.2.0'

        // SUB-PROJECT DEPENDENCIES END
    }

Any solution on how to get it sync?

Phantômaxx
  • 37,901
  • 21
  • 84
  • 115
neiza
  • 265
  • 4
  • 15

1 Answers1

5

The dependency:

implementation 'com.google.android.gms:play-services-base:17.2.0'

(currently) doesn't exist.

Use 17.1.0 or 17.0.0.

This is list of the latest available versions.
You can also check the history in the release notes page.

Gabriele Mariotti
  • 320,139
  • 94
  • 887
  • 841
  • when I change 17.10 or 17.0.0, I get this error: Please fix the version conflict either by updating the version of the google-services plugin (information about the latest version is available at https://bintray.com/android/android-tools/com.google.gms.google-services/) or updating the version of com.google.android.gms to 17.2.0. – neiza Sep 03 '19 at 12:44
  • Hi @neiza.This is a separate problem. It has nothing to do with your question. You may wish to consider asking a separate question. Also pay attention because some of your dependencies (as ads-18.2.0) [can't work with support libraries](https://stackoverflow.com/questions/57760036/play-services-ads-conflicts-with-appcompat/57760165#57760165) but require androidx migration. – Gabriele Mariotti Sep 03 '19 at 12:56