gpt4 book ai didi

java - Fabric/Crashlytics NoClassDefFoundError 仅在某些设备上

转载 作者:塔克拉玛干 更新时间:2023-11-02 08:47:09 25 4
gpt4 key购买 nike

我在 Google Play 中看到与 Fabric/Crashlytics 相关的崩溃。这发生在我从普通的 Crashlytics 更新到新的 Fabric Crashlytics 之后。我只能在我的一台设备 (Galaxy S2) 上复制它。我拥有的所有其他设备(Nexus 5 和 S4)都没有崩溃。这是堆栈跟踪:

08-19 09:32:26.328    7084-7084/com.tsm.countryjam D/dalvikvm﹕ WAIT_FOR_CONCURRENT_GC blocked 0ms
08-19 09:32:26.653 7084-7088/com.tsm.countryjam D/dalvikvm﹕ GC_CONCURRENT freed 251K, 12% free 9567K/10823K, paused 12ms+2ms, total 70ms
08-19 09:32:26.653 7084-7084/com.tsm.countryjam D/dalvikvm﹕ WAIT_FOR_CONCURRENT_GC blocked 42ms
08-19 09:32:26.653 7084-7100/com.tsm.countryjam D/dalvikvm﹕ WAIT_FOR_CONCURRENT_GC blocked 42ms
08-19 09:32:26.668 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Failed resolving Lcom/crashlytics/android/beta/Beta; interface 9027 'Lio/fabric/sdk/android/services/common/DeviceIdentifierProvider;'
08-19 09:32:26.668 7084-7084/com.tsm.countryjam W/dalvikvm﹕ Link of class 'Lcom/crashlytics/android/beta/Beta;' failed
08-19 09:32:26.668 7084-7084/com.tsm.countryjam E/dalvikvm﹕ Could not find class 'com.crashlytics.android.beta.Beta', referenced from method com.crashlytics.android.Crashlytics.<init>
08-19 09:32:26.668 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to resolve new-instance 1791 (Lcom/crashlytics/android/beta/Beta;) in Lcom/crashlytics/android/Crashlytics;
08-19 09:32:26.668 7084-7084/com.tsm.countryjam D/dalvikvm﹕ VFY: replacing opcode 0x22 at 0x000a
08-19 09:32:26.668 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Failed resolving Lcom/crashlytics/android/beta/Beta; interface 9027 'Lio/fabric/sdk/android/services/common/DeviceIdentifierProvider;'
08-19 09:32:26.668 7084-7084/com.tsm.countryjam W/dalvikvm﹕ Link of class 'Lcom/crashlytics/android/beta/Beta;' failed
08-19 09:32:26.668 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to find class referenced in signature (Lcom/crashlytics/android/beta/Beta;)
08-19 09:32:26.673 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Failed resolving Lcom/crashlytics/android/beta/Beta; interface 9027 'Lio/fabric/sdk/android/services/common/DeviceIdentifierProvider;'
08-19 09:32:26.673 7084-7084/com.tsm.countryjam W/dalvikvm﹕ Link of class 'Lcom/crashlytics/android/beta/Beta;' failed
08-19 09:32:26.673 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to find class referenced in signature (Lcom/crashlytics/android/core/PinningInfoProvider;)
08-19 09:32:26.673 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to find class referenced in signature (Lcom/crashlytics/android/core/PinningInfoProvider;)
08-19 09:32:26.673 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to find class referenced in signature (Lcom/crashlytics/android/core/PinningInfoProvider;)
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to find class referenced in signature (Lcom/crashlytics/android/core/CrashlyticsListener;)
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to find class referenced in signature (Lcom/crashlytics/android/core/CrashlyticsListener;)
08-19 09:32:26.678 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Failed resolving Lcom/crashlytics/android/beta/Beta; interface 9027 'Lio/fabric/sdk/android/services/common/DeviceIdentifierProvider;'
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ Link of class 'Lcom/crashlytics/android/beta/Beta;' failed
08-19 09:32:26.678 7084-7084/com.tsm.countryjam D/dalvikvm﹕ DexOpt: unable to opt direct call 0x3474 at 0x0f in Lcom/crashlytics/android/Crashlytics;.<init>
08-19 09:32:26.678 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Failed resolving Lcom/crashlytics/android/answers/SessionEventTransform; interface 9072 'Lio/fabric/sdk/android/services/events/EventTransform;'
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ Link of class 'Lcom/crashlytics/android/answers/SessionEventTransform;' failed
08-19 09:32:26.678 7084-7084/com.tsm.countryjam E/dalvikvm﹕ Could not find class 'com.crashlytics.android.answers.SessionEventTransform', referenced from method com.crashlytics.android.answers.Answers.initializeSessionAnalytics
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to resolve new-instance 1784 (Lcom/crashlytics/android/answers/SessionEventTransform;) in Lcom/crashlytics/android/answers/Answers;
08-19 09:32:26.678 7084-7084/com.tsm.countryjam D/dalvikvm﹕ VFY: replacing opcode 0x22 at 0x0004
08-19 09:32:26.678 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Could not find method io.fabric.sdk.android.services.common.CommonUtils.logControlledError, referenced from method com.crashlytics.android.answers.Answers.initializeSessionAnalytics
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to resolve static method 59049: Lio/fabric/sdk/android/services/common/CommonUtils;.logControlledError (Landroid/content/Context;Ljava/lang/String;Ljava/lang/Throwable;)V
08-19 09:32:26.678 7084-7084/com.tsm.countryjam D/dalvikvm﹕ VFY: replacing opcode 0x77 at 0x0194
08-19 09:32:26.678 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Could not find method io.fabric.sdk.android.services.settings.Settings.getInstance, referenced from method com.crashlytics.android.answers.Answers.doInBackground
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to resolve static method 59331: Lio/fabric/sdk/android/services/settings/Settings;.getInstance ()Lio/fabric/sdk/android/services/settings/Settings;
08-19 09:32:26.678 7084-7084/com.tsm.countryjam D/dalvikvm﹕ VFY: replacing opcode 0x71 at 0x000c
08-19 09:32:26.678 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Could not find method io.fabric.sdk.android.services.common.CommonUtils.getStringsFileValue, referenced from method com.crashlytics.android.answers.Answers.getOverridenSpiEndpoint
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to resolve static method 59043: Lio/fabric/sdk/android/services/common/CommonUtils;.getStringsFileValue (Landroid/content/Context;Ljava/lang/String;)Ljava/lang/String;
08-19 09:32:26.678 7084-7084/com.tsm.countryjam D/dalvikvm﹕ VFY: replacing opcode 0x71 at 0x0008
08-19 09:32:26.678 7084-7084/com.tsm.countryjam E/dalvikvm﹕ Could not find class 'io.fabric.sdk.android.services.persistence.FileStoreImpl', referenced from method com.crashlytics.android.answers.Answers.getSdkDirectory
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to resolve new-instance 9090 (Lio/fabric/sdk/android/services/persistence/FileStoreImpl;) in Lcom/crashlytics/android/answers/Answers;
08-19 09:32:26.678 7084-7084/com.tsm.countryjam D/dalvikvm﹕ VFY: replacing opcode 0x22 at 0x0001
08-19 09:32:26.678 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Could not find method io.fabric.sdk.android.services.common.Crash$FatalException.getSessionId, referenced from method com.crashlytics.android.answers.Answers.onException
08-19 09:32:26.678 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to resolve virtual method 59056: Lio/fabric/sdk/android/services/common/Crash$FatalException;.getSessionId ()Ljava/lang/String;
08-19 09:32:26.678 7084-7084/com.tsm.countryjam D/dalvikvm﹕ VFY: replacing opcode 0x6e at 0x000b
08-19 09:32:26.683 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Could not find method io.fabric.sdk.android.services.common.Crash$LoggedException.getSessionId, referenced from method com.crashlytics.android.answers.Answers.onException
08-19 09:32:26.683 7084-7084/com.tsm.countryjam W/dalvikvm﹕ VFY: unable to resolve virtual method 59058: Lio/fabric/sdk/android/services/common/Crash$LoggedException;.getSessionId ()Ljava/lang/String;
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/dalvikvm﹕ VFY: replacing opcode 0x6e at 0x000b
08-19 09:32:26.683 7084-7084/com.tsm.countryjam I/dalvikvm﹕ Failed resolving Lcom/crashlytics/android/answers/SessionEventTransform; interface 9072 'Lio/fabric/sdk/android/services/events/EventTransform;'
08-19 09:32:26.683 7084-7084/com.tsm.countryjam W/dalvikvm﹕ Link of class 'Lcom/crashlytics/android/answers/SessionEventTransform;' failed
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/dalvikvm﹕ DexOpt: unable to opt direct call 0x3455 at 0x0c in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/dalvikvm﹕ DexOpt: unable to opt direct call 0xe6da at 0x19 in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/dalvikvm﹕ DexOpt: unable to opt direct call 0xe78c at 0x36 in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam W/dalvikvm﹕ Unable to resolve superclass of Lcom/crashlytics/android/answers/SessionAnalyticsFilesManager; (9073)
08-19 09:32:26.683 7084-7084/com.tsm.countryjam W/dalvikvm﹕ Link of class 'Lcom/crashlytics/android/answers/SessionAnalyticsFilesManager;' failed
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/dalvikvm﹕ DexOpt: unable to opt direct call 0x342a at 0x4b in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam I/dalvikvm﹕ DexOpt: unable to optimize static field ref 0x5e1e at 0x72 in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam I/dalvikvm﹕ DexOpt: unable to optimize static field ref 0x5e1c at 0x7e in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam I/dalvikvm﹕ DexOpt: unable to optimize static field ref 0x5e21 at 0x8a in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/dalvikvm﹕ DexOpt: unable to opt direct call 0xe78f at 0x115 in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/dalvikvm﹕ DexOpt: unable to opt direct call 0xe78f at 0x17d in Lcom/crashlytics/android/answers/Answers;.initializeSessionAnalytics
08-19 09:32:26.683 7084-7084/com.tsm.countryjam I/dalvikvm﹕ DexOpt: unable to optimize instance field ref 0x5e91 at 0x20 in Lcom/crashlytics/android/answers/Answers;.doInBackground
08-19 09:32:26.683 7084-7084/com.tsm.countryjam I/dalvikvm﹕ DexOpt: unable to optimize instance field ref 0x5e8c at 0x22 in Lcom/crashlytics/android/answers/Answers;.doInBackground
08-19 09:32:26.683 7084-7084/com.tsm.countryjam I/dalvikvm﹕ DexOpt: unable to optimize instance field ref 0x5e8e at 0x2a in Lcom/crashlytics/android/answers/Answers;.doInBackground
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/dalvikvm﹕ DexOpt: unable to opt direct call 0xe7ac at 0x07 in Lcom/crashlytics/android/answers/Answers;.getSdkDirectory
08-19 09:32:26.683 7084-7084/com.tsm.countryjam D/AndroidRuntime﹕ Shutting down VM
08-19 09:32:26.683 7084-7084/com.tsm.countryjam W/dalvikvm﹕ threadid=1: thread exiting with uncaught exception (group=0x4127b2a0)
08-19 09:32:26.683 7084-7084/com.tsm.countryjam E/AndroidRuntime﹕ FATAL EXCEPTION: main
java.lang.NoClassDefFoundError: com.crashlytics.android.beta.Beta
at com.crashlytics.android.Crashlytics.<init>(Crashlytics.java:29)
at com.tsm.events.application.TownsquareEvents.onCreate(TownsquareEvents.java:59)
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1014)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4251)
at android.app.ActivityThread.access$1400(ActivityThread.java:140)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1297)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:4921)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1027)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:794)
at dalvik.system.NativeStart.main(Native Method)

这是我的 build.gradle 的内容:

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

dependencies {
classpath 'com.android.tools.build:gradle:1.0.+'
classpath 'io.fabric.tools:gradle:1.+'
}
}
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'

repositories {
jcenter()
flatDir {
dirs 'libs'
}
maven { url 'https://maven.fabric.io/public' }
}


android {
compileSdkVersion 22
buildToolsVersion "22.0.1"

defaultConfig {
applicationId "com.tsm.events"
minSdkVersion 15
targetSdkVersion 22
versionCode 1
versionName "1.0.0"
multiDexEnabled = true
}
dexOptions {
javaMaxHeapSize "4g"
}
buildTypes {
debug {
debuggable true
}
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}

}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile project(':libraries:ResideMenu')
//compile 'com.android.support:support-v4:20.0.+'
compile 'com.android.support:support-v4:22.0.+'
compile files('libs/universal-image-loader-1.9.3.jar')
compile 'io.realm:realm-android:0.81.1'
compile 'se.emilsjolander:stickylistheaders:2.5.2'
compile 'com.google.android.gms:play-services:6.5.87'
compile 'com.parse.bolts:bolts-android:1.+'
compile fileTree(dir: 'libs', include: 'Parse-*.jar')
compile('com.crashlytics.sdk.android:crashlytics:2.4.0@aar') {
transitive = true
}
// Twitter Kit
compile('com.twitter.sdk.android:twitter:1.6.0@aar') {
transitive = true
}
compile('com.twitter.sdk.android:tweet-composer:0.8.0@aar') {
transitive = true;
}
compile 'com.facebook.android:facebook-android-sdk:3.20.0'
compile 'com.google.maps.android:android-maps-utils:0.3+'
compile(name: 'estimote-sdk-preview', ext: 'aar')
compile files('libs/biweekly-0.4.2.jar')
compile files('libs/jackson-core-2.5.2.jar')
}

最佳答案

我只是凭直觉想通了!我最近不得不在升级到新的 Fabric 框架后添加 multi-dex 支持,我有一种感觉,也许我没有做对。所以在添加这些额外的更改之后,现在它不再崩溃了:

在我的 build.gradle 中,我添加了一个增量设置:

dexOptions {
incremental true
javaMaxHeapSize "4g"
}

和一个额外的依赖:

compile 'com.android.support:multidex:'

在我的应用程序类上,我正在扩展 MultiDexApplication:

public class TownsquareEvents extends android.support.multidex.MultiDexApplication

关于java - Fabric/Crashlytics NoClassDefFoundError 仅在某些设备上,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32097150/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com