NoClassDefFoundError: AnalyticsConnector
Actual behaviour
- normal execution of app
Expected behaviour
************ CAUSE OF ERROR ************
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/firebase/analytics/connector/AnalyticsConnector; at com.google.firebase.messaging.MessagingAnalytics.zza(Unknown Source) at com.google.firebase.messaging.MessagingAnalytics.logNotificationReceived(Unknown Source) at com.google.firebase.messaging.FirebaseMessagingService.zzd(Unknown Source) at com.google.firebase.iid.zzc.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) at com.google.android.gms.common.util.concurrent.zza.run(Unknown Source) at java.lang.Thread.run(Thread.java:831) Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.firebase.analytics.connector.AnalyticsConnector" on path: DexPathList[[zip file "/data/app/com.nextcloud.client-1/base.apk"],nativeLibraryDirectories=[/data/app/com.nextcloud.client-1/lib/arm64, /vendor/lib64, /system/lib64]] at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56) at java.lang.ClassLoader.loadClass(ClassLoader.java:511) at java.lang.ClassLoader.loadClass(ClassLoader.java:469) ... 8 more Suppressed: java.lang.ClassNotFoundException: com.google.firebase.analytics.connector.AnalyticsConnector at java.lang.Class.classForName(Native Method) at java.lang.BootClassLoader.findClass(ClassLoader.java:781) at java.lang.BootClassLoader.loadClass(ClassLoader.java:841) at java.lang.ClassLoader.loadClass(ClassLoader.java:504) ... 9 more Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack available
************ APP INFORMATION ************ ID: com.nextcloud.client Version: 30080190 Build flavor: gplay
************ DEVICE INFORMATION ************ Brand: Huawei Device: hwALE-H Model: ALE-L21 Id: HuaweiALE-L21 Product: ALE-L21
************ FIRMWARE ************ SDK: 21 Release: 5.0.1 Incremental: C432B20
I got this too, multiple times a day for a while now, very annoying, basically every time I unlock my phone. I seems it happens everytime the phone come out of sleep.
This request did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!
@tobiasKaminsky referenced and closed all duplicates, this seems to happen quite a lot.
Having this happen to me too, almost the exact same backtrace too with the newest version of the app.
************ CAUSE OF ERROR ************
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/firebase/analytics/connector/AnalyticsConnector;
at com.google.firebase.messaging.MessagingAnalytics.zza(Unknown Source:68)
at com.google.firebase.messaging.MessagingAnalytics.logNotificationReceived(Unknown Source:2)
at com.google.firebase.messaging.FirebaseMessagingService.zzd(Unknown Source:50)
at com.google.firebase.iid.zzg.run(Unknown Source:4)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at com.google.android.gms.common.util.concurrent.zza.run(Unknown Source:7)
at java.lang.Thread.run(Thread.java:764)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.firebase.analytics.connector.AnalyticsConnector" on path: DexPathList[[zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/com.nextcloud.client-LTiS90daWMmAsD_F7QRCGQ==/base.apk"],nativeLibraryDirectories=[/data/app/com.nextcloud.client-LTiS90daWMmAsD_F7QRCGQ==/lib/arm64, /data/app/com.nextcloud.client-LTiS90daWMmAsD_F7QRCGQ==/base.apk!/lib/arm64-v8a, /system/lib64]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:134)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
... 8 more
************ APP INFORMATION ************
ID: com.nextcloud.client
Version: 30100051
Build flavor: gplay
************ DEVICE INFORMATION ************
Brand: asus
Device: ASUS_X00QD
Model: ASUS_X00QD
Id: PPR1.180610.009
Product: WW_X00QD
************ FIRMWARE ************
SDK: 28
Release: 9
Incremental: 16.0615.1908.109-0
Seems to often happen during the night for me, with the error message greeting me many mornings, as well as occasionally sometimes during the day when I unlock my phone.
@tobiasKaminsky can you have a look at this? It keeps getting reported over and over, so fixing might be important ❤️
Happens on my Samsung tablet, but not on the Smartphone...
Isn't this the same as #4586??
To be honest, I have no clue.
We explicitly disable firebase as we do not want to have any tracking in our app: https://github.com/nextcloud/android/blob/b8d042e1715586ea7a265db24ccb913290f6aaef/build.gradle#L51-L53 https://github.com/nextcloud/android/blob/533debfca04852c29b54a0ba745a2d7311039984/src/gplay/AndroidManifest.xml#L31-L36
Of course Gplay variant of NC app uses push notifications via firebase messaging, but this should all be self contained to work, otherwise a lot more user/devices would cause the trouble.

Analyzing recent apk also shows that this is in.
How and where did you installed the app? Do you have some custom rom? Magisk etc?
I only encountered this problem once, when I had an emulator with no google APIs at all and tried to launch Gplay variant of our app.
Do you have some custom rom? Magisk etc?
I'm on OmniRom 10 with Open GApps Nano and Magisk. Perhaps some missing Google apps in the nano package?
Btw: is it expected to have that L in front of the class path?
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/firebase/analytics/connector/AnalyticsConnector;
I have this problem on a Samsung Galaxy Tab S4 with stock OS. Installed from Google Play, it does not crash on the Galaxy Smartphone.
@Chartman123 Yeah, I fear that this is something with gapps / magisk. "L" is just a wrong debug output.
@lazyfrosch which Android version do you run?
@tobiasKaminsky that is an Android 9
I'm not that deep into Android development, but could it also be, that with some SDK version the Firebase Analytics are required to run some of the code Nextcloud is using for the notifications?
I found this in the Firebase docs from Google:
You no longer need to add the Android library com.google.firebase:firebase-core. This SDK included the Firebase SDK for Google Analytics. Now, to use Analytics (or any of the Firebase products that require or recommend the use of Analytics), you need to explicitly add the Analytics dependency: com.google.firebase:firebase-analytics:17.2.2.
https://firebase.google.com/docs/android/setup#add_firebase_to_your_app
It also states that it's recommended for Cloud Messaging
Detailed info:
************ APP INFORMATION ************
ID: com.nextcloud.client
Version: 30100090
Build flavor: gplay
************ DEVICE INFORMATION ************
Brand: samsung
Device: gts4llte
Model: SM-T835
Id: PPR1.180610.011
Product: gts4lltexx
************ FIRMWARE ************
SDK: 28
Release: 9
Incremental: T835XXU4BSJ6
This happens to me too. I have:
- Google Nexus 6P
- OS: LineageOS (Android 8.1)
- Open-GApps nano
- Magisk
************ CAUSE OF ERROR ************
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/firebase/analytics/connector/AnalyticsConnector;
at com.google.firebase.messaging.MessagingAnalytics.zza(Unknown Source:68)
at com.google.firebase.messaging.MessagingAnalytics.logNotificationReceived(Unknown Source:2)
at com.google.firebase.messaging.FirebaseMessagingService.zzd(Unknown Source:50)
at com.google.firebase.iid.zzg.run(Unknown Source:4)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
at com.google.android.gms.common.util.concurrent.zza.run(Unknown Source:7)
at java.lang.Thread.run(Thread.java:764)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.firebase.analytics.connector.AnalyticsConnector" on path: DexPathList[[zip file "/data/app/com.nextcloud.client-XIV3hreoVJQb7KqdFkoWdA==/base.apk"],nativeLibraryDirectories=[/data/app/com.nextcloud.client-XIV3hreoVJQb7KqdFkoWdA==/lib/arm64, /data/app/com.nextcloud.client-XIV3hreoVJQb7KqdFkoWdA==/base.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:125)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
... 8 more
************ APP INFORMATION ************
ID: com.nextcloud.client
Version: 30100190
Build flavor: gplay
************ DEVICE INFORMATION ************
Brand: google
Device: angler
Model: Nexus 6P
Id: OPM7.181205.001
Product: angler
************ FIRMWARE ************
SDK: 27
Release: 8.1.0
Incremental: fef9954632
Same here:
************ CAUSE OF ERROR ************
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/firebase/analytics/connector/AnalyticsConnector;
at com.google.firebase.messaging.MessagingAnalytics.zza(Unknown Source:68)
at com.google.firebase.messaging.MessagingAnalytics.logNotificationReceived(Unknown Source:2)
at com.google.firebase.messaging.FirebaseMessagingService.zzd(Unknown Source:50)
at com.google.firebase.iid.zzg.run(Unknown Source:4)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at com.google.android.gms.common.util.concurrent.zza.run(Unknown Source:7)
at java.lang.Thread.run(Thread.java:764)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.firebase.analytics.connector.AnalyticsConnector" on path: DexPathList[[zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/com.nextcloud.client-3J5837-wQ6ZBQIaMdCT0-Q==/base.apk"],nativeLibraryDirectories=[/data/app/com.nextcloud.client-3J5837-wQ6ZBQIaMdCT0-Q==/lib/arm64, /data/app/com.nextcloud.client-3J5837-wQ6ZBQIaMdCT0-Q==/base.apk!/lib/arm64-v8a, /system/lib64, /system/vendor/lib64]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:134)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
... 8 more
************ APP INFORMATION ************
ID: com.nextcloud.client
Version: 30100190
Build flavor: gplay
************ DEVICE INFORMATION ************
Brand: samsung
Device: dreamlte
Model: SM-G950F
Id: PPR1.180610.011
Product: dreamltexx
************ FIRMWARE ************
SDK: 28
Release: 9
Incremental: G950FXXS6DTA1
This error appears regularly on two phones having Lineageos 16 and ResurrectionRemix with MindtheGapps installed, but the Nextcloud client 3.10.1 installed from F-Droid.
Nextcloud client 3.10.1 installed from F-Droid
If NC app is installed via Fdroid there is no Firebase at all. So it should(tm) not be causing this.