java.lang.NoClassDefFoundError: com.google.firebase.FirebaseOptions [英] java.lang.NoClassDefFoundError: com.google.firebase.FirebaseOptions

查看:29
本文介绍了java.lang.NoClassDefFoundError: com.google.firebase.FirebaseOptions的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的谷歌开发者控制台上遇到了这个奇怪的错误.所以我使用谷歌云测试实验室来查看真正发生的事情.结果发现我的应用在几乎所有设备上都失败了

I was getting this weird error on my google developer console. So i used google Cloud Test Lab to See whats really happening. turns out my app is failing on almost all devices

FATAL EXCEPTION: main
 Process: com.blackcurrantapps.iamin, PID: 16706
 java.lang.NoClassDefFoundError: com.google.firebase.FirebaseOptions
    at com.google.firebase.FirebaseApp.zzbu(Unknown Source)
    at com.google.firebase.provider.FirebaseInitProvider.onCreate(Unknown Source)
    at android.content.ContentProvider.attachInfo(ContentProvider.java:1591)
    at android.content.ContentProvider.attachInfo(ContentProvider.java:1562)
    at com.google.firebase.provider.FirebaseInitProvider.attachInfo(Unknown Source)
    at android.app.ActivityThread.installProvider(ActivityThread.java:4871)
    at android.app.ActivityThread.installContentProviders(ActivityThread.java:4466)
    at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4406)
    at android.app.ActivityThread.access$1500(ActivityThread.java:139)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1270)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:136)
    at android.app.ActivityThread.main(ActivityThread.java:5102)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:515)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601)
    at dalvik.system.NativeStart.main(Native Method)

这是测试的屏幕截图.

现在是有趣的部分,我什至根本不在我的应用中使用 Firebase.当我在整个应用程序的路径中查找时,没有提到Firebase"这个词.不过,我确实使用了谷歌云服务、登录和谷歌应用引擎.

Now Here's the funny part, I dont even use Firebase in my app at all. There is no reference to the word "Firebase" when i do a find in path on my entire application. I Do use google cloud services, login and Google app engine though.

这是我的 build.gradle 文件:

Here's my build.gradle file:

buildscript {
    repositories {
        maven { url 'https://maven.fabric.io/public' }
    }

    dependencies {
        classpath 'io.fabric.tools:gradle:1.+'
    }
}
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
apply plugin: 'com.google.gms.google-services'

android {
    compileSdkVersion 23
    buildToolsVersion '23.0.2'

    defaultConfig {
        applicationId "com.blackcurrantapps.iamin"
        minSdkVersion 16
        targetSdkVersion 23
        versionCode 11
        versionName "Fixed Check in Bug"
        multiDexEnabled = true
    }
    buildTypes {
        release {
            shrinkResources true
//            minifyEnabled true
//            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
    packagingOptions {
        exclude 'META-INF/LICENSE'
        exclude 'META-INF/NOTICE'
    }
    dexOptions {
        javaMaxHeapSize "4g"
    }
}
repositories {
    maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
    maven { url "https://oss.sonatype.org/content/groups/public/" }
    maven { url "https://jitpack.io" }
    maven { url 'https://maven.fabric.io/public' }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])

    compile('com.mikepenz:materialdrawer:4.5.8@aar') {
        transitive = true
    }

    compile 'com.mikepenz:google-material-typeface:1.2.0.1@aar' //Google Material Design Icons
    compile 'com.mikepenz:fontawesome-typeface:4.4.0.1@aar'

    compile('com.vincentbrison.openlibraries.android:dualcache:2.2.2@jar') {
        transitive = true;
    }

    compile project(':htmlDialog')
    compile('com.twitter.sdk.android:twitter:1.8.0@aar') {
        transitive = true;
    }
    compile 'com.android.support:palette-v7:23.4.0'
    compile 'com.android.support:multidex:1.0.1'
    compile 'com.android.support:appcompat-v7:23.4.0'
    compile 'com.android.support:design:23.4.0'
    compile 'com.google.android.gms:play-services-maps:9.0.0'
    compile 'com.google.android.gms:play-services-gcm:9.0.0'
    compile 'com.google.android.gms:play-services-identity:9.0.0'
    compile 'com.google.android.gms:play-services-base:9.0.0'
    compile 'com.google.android.gms:play-services-plus:9.0.0'
    compile 'com.google.android.gms:play-services-analytics:9.0.0'
    compile 'com.google.android.gms:play-services-location:9.0.0'
    compile 'com.android.support:cardview-v7:23.4.0'
    compile 'com.rengwuxian.materialedittext:library:2.1.3'
    compile 'com.twotoasters.jazzylistview:library:1.2.1'
    compile 'com.twotoasters.jazzylistview:library-recyclerview:1.2.1'
    compile 'com.pnikosis:materialish-progress:1.7'
    compile 'com.getbase:floatingactionbutton:1.10.1'
    compile 'com.squareup.picasso:picasso:2.5.2'
    compile 'com.squareup.okhttp:okhttp:2.6.0'
    compile 'me.dm7.barcodescanner:zbar:1.8.3'
    compile 'net.glxn.qrgen:android:2.0'
    compile 'com.edmodo:cropper:1.0.1'
    compile 'com.github.PhilJay:MPAndroidChart:v2.1.6'
    compile 'de.greenrobot:eventbus:2.4.0'
    compile 'com.android.support:support-v4:23.4.0'
    compile 'com.pavelsikun:material-seekbar-preference:0.12.1+'

    compile project(path: ':backend', configuration: 'android-endpoints')
}

有人可以帮我吗?

推荐答案

感谢您发布问题 Sanket.我是 Firebase 测试实验室(以前称为云测试实验室)的 PM.想让您知道这是我们这边的一个错误,现在应该修复.

Thanks for posting the question Sanket. I'm the PM on Firebase Test Lab (formerly Cloud Test Lab). Wanted to let you know that this is a bug on our end that should now be fixed.

您的应用目前似乎正在使用最新最好的 Google Play 服务.上周我们更新了我们的设备以使用它们,然后我们发现了一个错误,使我们恢复到旧版本.现在,我们在我们的设备上重新部署了最新的 Play 服务,因此重新运行您的测试应该可以正常工作.如果没有,请告诉我,我们会调查并修复.

It seems that your app is currently using the latest and greatest Google Play Services. We updated our devices to use them last week then we discovered a bug that had us revert to an older version. Right now, we re-deployed the latest Play services on our devices so rerunning your tests should work. If not, please let me know and we'll look into it and fix it.

这篇关于java.lang.NoClassDefFoundError: com.google.firebase.FirebaseOptions的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆