The library com.google.android.gms:play-services-measurement-base is being requested by various other libraries at [[15.0.4,15.0.4], [16.0.0,16.0.0]], but resolves to 16.0.0.

9,536 views
Skip to first unread message

Yu-Hsuan Lin

unread,
Jun 16, 2018, 10:42:54 AM6/16/18
to Firebase Google Group
Just upgrade to latest library and get this error.
Also I couldn't find firebase-invites:16.0.1 according to this page

Samuel Stern

unread,
Jun 18, 2018, 12:20:07 PM6/18/18
to fireba...@googlegroups.com
Hi there,

Could you show the whole dependencies block of your app's build.gradle file?  Also what version of the google-services plugin are you using?

I can also confirm that page has an error, 16.0.0 is the latest version of invites visible on maven.google.com. I will fix the docs.

- Sam

On Sat, Jun 16, 2018 at 7:42 AM Yu-Hsuan Lin <b955...@gmail.com> wrote:
Just upgrade to latest library and get this error.
Also I couldn't find firebase-invites:16.0.1 according to this page

--
You received this message because you are subscribed to the Google Groups "Firebase Google Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebase-tal...@googlegroups.com.
To post to this group, send email to fireba...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/firebase-talk/f9728126-88e6-4951-b253-fc1e9909c6bb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

AR Labs

unread,
Jun 18, 2018, 1:40:34 PM6/18/18
to Firebase Google Group
Hello, I have the same identical error of the topic and another similar:

The library com.google.firebase:firebase-analytics-impl is being requested by various other libraries at [[16.0.0,16.0.0], [16.1.1,16.1.1]], but resolves to 16.1.1. Disable the plugin and check your dependencies tree using ./gradlew :app:dependencies.

The dependencies are:

dependencies {
def work_version = "1.0.0-alpha02"
def lifecycle_version = "1.1.1"

// Including jars
implementation fileTree(include: ['*.jar'], dir: 'libs')
// Compiling external modules
implementation project(':ArLabsUtils')
implementation project(':Appirater')
implementation project(':geographiclib')
implementation project(':LVL')
// Advertising network only for free version
freeImplementation fileTree(dir: 'libs/ads', include: ['*.jar'])
amzfreeImplementation fileTree(dir: 'libs/ads', include: ['*.jar'])
huaImplementation fileTree(dir: 'libs/ads', include: ['*.jar'])
// To enable for minSdk < 21
implementation 'com.android.support:multidex:1.0.3'
// Including external libraries
implementation 'com.android.support:support-annotations:27.1.1'
implementation 'com.davemorrissey.labs:subsampling-scale-image-view:3.10.0'
implementation 'com.github.kizitonwose.colorpreference:support:1.0.2'
implementation 'com.android.support:gridlayout-v7:27.1.1'
implementation 'com.android.support:cardview-v7:27.1.1'
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support:design:27.1.1'
implementation 'com.google.android.gms:play-services-base:15.0.1'
implementation 'com.google.android.gms:play-services-location:15.0.1'
implementation 'com.google.android.gms:play-services-maps:15.0.1'
implementation 'com.android.support:percent:27.1.1'
implementation 'com.android.support:support-v4:27.1.1'
implementation 'com.android.support:preference-v14:27.1.1'
implementation 'com.android.support:support-vector-drawable:27.1.1'
implementation 'com.android.support:animated-vector-drawable:27.1.1'
implementation 'com.google.firebase:firebase-core:16.0.1'
implementation 'com.google.firebase:firebase-ads:15.0.1'
implementation 'com.google.firebase:firebase-invites:16.0.0'
implementation 'com.crashlytics.sdk.android:crashlytics:2.9.4'
implementation 'com.google.firebase:firebase-messaging:17.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.2'

implementation "android.arch.work:work-runtime:$work_version"
implementation "android.arch.work:work-firebase:$work_version"
implementation "android.arch.lifecycle:extensions:$lifecycle_version"

// MapBox
implementation 'com.mapbox.mapboxsdk:mapbox-android-sdk:5.5.0'

implementation 'com.opencsv:opencsv:4.0'

implementation ("com.github.bumptech.glide:glide:4.6.1@aar") {
transitive = true
}
annotationProcessor 'com.github.bumptech.glide:compiler:4.6.1'

implementation 'com.wdullaer:materialdatetimepicker:3.5.1'

configurations.all {
exclude group: 'com.android.support', module: 'support-v13'
}
}
apply plugin: 'com.google.gms.google-services'

The script dependencies (global build.gradle) are:

buildscript {
    repositories
{
        google
()
        jcenter
()
        maven
{ url 'https://maven.fabric.io/public' }
   
}
    dependencies
{
        classpath 'com.android.tools.build:gradle:3.1.3'
        classpath 'com.google.gms:google-services:4.0.1'
        classpath 'com.google.firebase:firebase-plugins:1.1.5'
        classpath
'io.fabric.tools:gradle:1.25.4'
    }
}

Thanks

Samuel Stern

unread,
Jun 20, 2018, 12:15:57 PM6/20/18
to fireba...@googlegroups.com
I just dug into this and have a workaround for you.  This is a bug and we'll fix in the next release, but for now the solution is simple.

First of all, the problem can be isolated to just these dependencies:
implementation 'com.google.firebase:firebase-core:16.0.1'
implementation 'com.google.firebase:firebase-invites:16.0.0'
In order to fix the error, you have to add one more dependency:
implementation 'com.google.android.gms:play-services-appinvite:16.0.1'
For me that solves it, hope it works for you too!
- Sam

Bhupendra Acharya

unread,
Oct 7, 2018, 11:35:30 AM10/7/18
to Firebase Google Group
Thanks alot. Adding:

implementation 'com.google.android.gms:play-services-appinvite:16.0.4' as I am using implementation 'com.google.firebase:firebase-core:16.0.4' instead of 16.0.1

Helped me!
Reply all
Reply to author
Forward
0 new messages