implementation 'com.google.android.gms:play-services-base:15.0.1'
implementation 'com.google.android.gms:play-services-maps:15.0.1'
implementation 'com.google.android.gms:play-services-analytics:16.0.1'
implementation 'com.google.firebase:firebase-core:16.0.1'
implementation 'com.google.firebase:firebase-messaging:17.1.0'
implementation 'com.google.firebase:firebase-crash:16.0.1'
implementation 'com.google.firebase:firebase-perf:16.0.0'
implementation 'com.google.android.gms:play-services-tagmanager:16.0.1'
my app met some mistakes about perf
1:
Exception java.lang.NullPointerException: Attempt to invoke virtual method 'boolean com.google.android.gms.internal.firebase-perf.zzq.zzb(com.google.android.gms.internal.firebase-perf.zzah)' on a null object reference
com.google.android.gms.internal.firebase-perf.zzg.zza ()
com.google.android.gms.internal.firebase-perf.zzg.zzb ()
com.google.android.gms.internal.firebase-perf.zzg.zza ()
com.google.android.gms.internal.firebase-perf.zzj.run ()
java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1113)
java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:588)
java.lang.Thread.run (Thread.java:818)
2:
Exception java.lang.RuntimeException: Package manager has died
android.app.ApplicationPackageManager.getPackageInfo (ApplicationPackageManager.java:142)
com.google.android.gms.internal.firebase-perf.zzg.zzd ()
com.google.android.gms.internal.firebase-perf.zzg.zzp ()
com.google.android.gms.internal.firebase-perf.zzg.zzb ()
com.google.android.gms.internal.firebase-perf.zzh.run ()
java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1113)
java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:588)
java.lang.Thread.run (Thread.java:818)
3:
Exception java.lang.NullPointerException: Null pointer exception during instruction 'monitor-enter v10'
android.os.Parcel.readException (Parcel.java:1620)
android.os.Parcel.readException (Parcel.java:1567)
android.app.ActivityManagerProxy.getContentProvider (ActivityManagerNative.java:3770)
android.app.ActivityThread.acquireProvider (ActivityThread.java:5249)
android.app.ContextImpl$ApplicationContentResolver.acquireUnstableProvider (ContextImpl.java:2138)
android.content.ContentResolver.acquireUnstableProvider (ContentResolver.java:1517)
android.content.ContentResolver.query (ContentResolver.java:482)
android.content.ContentResolver.query (ContentResolver.java:441)
com.google.android.gms.internal.firebase-perf.zza.zza ()
com.google.android.gms.internal.firebase-perf.zzq.<init> ()
com.google.android.gms.internal.firebase-perf.zzg.zzp ()
com.google.android.gms.internal.firebase-perf.zzg.zzb ()
@LiuDongCai apologies for the slow response, a few of us were on vacation.
Are you seeing this on your own device or just in customer crash reports? Do you know what behavior causes any of these exceptions to happen?
Just in customer crash reports.
And I don't know how to reappear.But it has appeared many times.
I have this problem too.
Just in customer crash reports.
Device :
com.google.android.gms.internal.firebase-perf.zzg.zza (Unknown Source:173)
com.google.android.gms.internal.firebase-perf.zzg.zzb (Unknown Source:78)
com.google.android.gms.internal.firebase-perf.zzg.zza (Unknown Source)
com.google.android.gms.internal.firebase-perf.zzj.run (Unknown Source:6)
java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1162)
java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:636)
java.lang.Thread.run (Thread.java:764)
I also have this happening in customer crash reports.
Devices:
1- Infinix - multiple models (Android 7.0)
2- TECNO - multiple models (Android 7.0)
Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean com.google.android.gms.internal.firebase-perf.zzq.zzb(com.google.android.gms.internal.firebase-perf.zzah)' on a null object reference
at com.google.android.gms.internal.firebase-perf.zzg.zza(Unknown Source)
at com.google.android.gms.internal.firebase-perf.zzg.zzb(Unknown Source)
at com.google.android.gms.internal.firebase-perf.zzg.zza(Unknown Source)
at com.google.android.gms.internal.firebase-perf.zzi.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
at java.lang.Thread.run(Thread.java:761)
Thanks everybody. I don't have a good way to reproduce this myself right now but I have shown this thread to the Firebase Performance SDK team and I hope they can help dig into it.
java.lang.RuntimeException: android.os.DeadSystemException
at android.app.ActivityThread.acquireProvider(ActivityThread.java:5828)
at android.app.ContextImpl$ApplicationContentResolver.acquireUnstableProvider(ContextImpl.java:2434)
at android.content.ContentResolver.acquireUnstableProvider(ContentResolver.java:1554)
at android.content.ContentResolver.query(ContentResolver.java:525)
at android.content.ContentResolver.query(ContentResolver.java:476)
at com.google.android.gms.internal.clearcut.zzab.zzi(Unknown Source)
at com.google.android.gms.internal.clearcut.zzab.zzg(Unknown Source)
at com.google.android.gms.internal.clearcut.zzaf.zzp(Unknown Source)
at com.google.android.gms.internal.clearcut.zzae.zza(Unknown Source)
at com.google.android.gms.internal.clearcut.zzae.zzl(Unknown Source)
at com.google.android.gms.internal.clearcut.zzae.get(Unknown Source)
at com.google.android.gms.internal.clearcut.zzp.zza(Unknown Source)
at com.google.android.gms.clearcut.ClearcutLogger$LogEventBuilder.log(Unknown Source)
at com.google.android.gms.internal.firebase-perf.zzg.zza(Unknown Source)
at com.google.android.gms.internal.firebase-perf.zzg.zzb(Unknown Source)
at com.google.android.gms.internal.firebase-perf.zzg.zza(Unknown Source)
at com.google.android.gms.internal.firebase-perf.zzj.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
at java.lang.Thread.run(Thread.java:776)
Caused by: android.os.DeadSystemException
@samtstern
implementation 'com.google.firebase:firebase-perf:16.0.0'
It reproduce on phones without Play Services
@samtstern
targetSdkVersion 27
java.lang.NoClassDefFoundError: com.google.android.gms.common.internal.zzbq
at com.google.firebase.perf.provider.FirebasePerfProvider.attachInfo(Unknown Source)
at android.app.ActivityThread.installProvider(ActivityThread.java:4819)
at android.app.ActivityThread.installContentProviders(ActivityThread.java:4432)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4372)
at android.app.ActivityThread.access$1300(ActivityThread.java:141)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1294)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:5041)
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:793)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
at dalvik.system.NativeStart.main(Native Method)
I believe this is the same as #536, which I was able to reproduce and we are now investigating. Closing...
@samtstern
I think the recent release 16.1.0 fixed #536.
But didn't fix this. I am still having similar error report in crashlytics.
Seems the source of the problems are different.
We're also still getting these crashes. It looks like the Firebase Performance team is looking into it and updating things on this Stackoverflow thread.
@lognaturel I see you have an open source project which was experiencing the NoClassDefFoundError - would you potentially be able to share the released APK that you were seeing crashes on?
Like I mentioned on the StackOverflow question, I suspect this issue has to do with some of the FirebasePerformance classes not being in the main dex - and being able to analyze an APK on which you were seeing the crashes would be super useful!
Edit: Nvm, found the apk on your github page :) Thanks!
as mentioned by @tejasd in stackoverflow
com.google.firebase:firebase-perf:16.2.0 may fix the problem.
Thanks for looking into it, @tejasd and @seventhmoon! Do you have a consistent way to repro? Is there a way for us to verify that the fix does in fact work other than pushing to production and seeing if one of our users happens to get a crash? If not, we'll need to at least wait until the next beta before trying it out.
I'm also seeing this problem, from a customer crash report:
Session summary
2.237 (237)
9
TECNO SPARK 4 Air
Mar 13, 2020, 7:58:00 PM
Stack trace
Keys
Logs
Data
Device
Brand: TECNO MOBILE LIMITED
Model: TECNO SPARK 4 Air
Orientation: Portrait
RAM free: 535.73 MB
Disk free: 10.16 GB
Operating System
Version: 9
Orientation: Portrait
Rooted: No
Fatal Exception: java.lang.NullPointerException
Attempt to invoke virtual method 'void com.google.firebase.perf.internal.zzv.zzc(boolean)' on a null object reference
com.google.firebase.perf.internal.zzf.zzd (com.google.firebase:firebase-perf@@19.0.5:170)
com.google.firebase.perf.internal.zzi.run (com.google.firebase:firebase-perf@@19.0.5:2)
java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1167)
java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:641)
java.lang.Thread.run (Thread.java:764)
pool-17-thread-3
com.crashlytics.android.core.CrashlyticsController.handleUncaughtException
com.crashlytics.android.core.CrashlyticsController$6.onUncaughtException (CrashlyticsController.java:301)
com.crashlytics.android.core.CrashlyticsUncaughtExceptionHandler.uncaughtException (CrashlyticsUncaughtExceptionHandler.java:42)
java.lang.ThreadGroup.uncaughtException (ThreadGroup.java:1068)
java.lang.Thread.dispatchUncaughtException (Thread.java:1955)
We're also seeing this issue come up from time to time in crashlytics, last two devices were
We're using com.google.firebase:firebase-perf:19.0.7.
Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'void com.google.firebase.perf.internal.v.a(boolean)' on a null object reference
at com.google.firebase.perf.internal.zzf.zzd(zzf.java:170)
at com.google.firebase.perf.internal.zzi.run(zzi.java:2)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:764)
Please re-open..
@tomblenz @fractalbob Thanks for your report! I've forwarded this to the folks currently taking care of this - but AFAICT these seem to be new bugs and so might be worth opening a new issue!
Thanks @tejasd for keeping an eye on this one. Also to everyone: if you are experiencing bugs in the Firebase Android SDK please file those on the firebase-android-sdk repo. We try to keep this repo for quickstart issues only.
Most helpful comment
@samtstern
I think the recent release 16.1.0 fixed #536.
But didn't fix this. I am still having similar error report in crashlytics.
Seems the source of the problems are different.