我正在使用Android studio和Fabric插件。 我已经能够向Fabric报告崩溃。
我的应用程序的Gradle构建脚本:
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'
repositories {
maven { url 'https://maven.fabric.io/public' }
}
android {
compileSdkVersion 23
buildToolsVersion "23.0.3"
defaultConfig {
applicationId "com.xxx.yyy"
minSdkVersion 16
targetSdkVersion 23
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile group: 'org.apache.commons', name: 'commons-lang3', version: '3.0'
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.android.support:design:23.1.1'
compile 'com.android.support:support-v4:23.1.1'
compile 'com.android.support:recyclerview-v7:23.1.1'
compile 'com.loopj.android:android-async-http:1.4.9'
compile 'com.squareup.picasso:picasso:2.5.2'
androidTestCompile('com.android.support.test:runner:0.5') {
}
androidTestCompile 'com.android.support.test:rules:0.5'
androidTestCompile 'com.android.support.test.espresso:espresso-core:2.2.2'
androidTestCompile('com.android.support.test.espresso:espresso-contrib:2.2.2') {
}
compile 'com.squareup.retrofit2:retrofit:2.1.0'
compile('com.crashlytics.sdk.android:crashlytics:2.6.0@aar') {
transitive = true;
}
}
答案 0 :(得分:38)
2.6.1版本解决了这个问题。将您的崩溃版本从2.6.0升级到2.6.1
compile('com.crashlytics.sdk.android:crashlytics:2.6.1@aar') {
transitive = true;
}
答案 1 :(得分:9)
来自Fabric的Mike。
抱歉这个错误! Crashlytics的2.6.1版纠正了这一点。发布说明:https://docs.fabric.io/android/changelog.html#id6
答案 2 :(得分:8)
清理,重建对我来说不起作用,我回到了2.5.7,所以暂时我的app build.gradle现在回到了(并且没有例外):
compile('com.crashlytics.sdk.android:crashlytics:2.5.7@aar') {
transitive = true;
}