-
Notifications
You must be signed in to change notification settings - Fork 615
ANR #2014
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight. |
Previously FIID broadcast handling was done and main thread and caused lots of ANR. It was fixed and rolled out earlier this year (not sure which release was in. Likely >= 20.1.3). IIRC, you updated the app to 20.2.4 but still sees many ANR crashes. Do you have any insights on the demographics of the SDK versions these crashes are on? |
I was also getting the same ANR. So i'm sharing my finding here with you all guys to reduce this ANR. Memory Leak can be one reason for emitting this com.google.firebase.iid.firebaseinstanceidreceiver ANR. Hope this help to all you guys. |
Hi @zwu52 @google-oss-bot , I have many app in my phone which receive daily 200+ push-notification each-app every-day. So i putted my device offline for 2-3days, later then came to online and then started getting notification more than 1000+ PNs (older & pending PN). Log Details:- Device details:- So in my opinion, if we receive many PN at same time this ANR surely occur. @google-oss-bot @zwu52 kindly look on this use case. while receiving 500+ push-notifications is their a way to properly schedule these many push notification to prevent this happening? |
I am also seeing this issue. |
@Jack29913 @rlazo Rodrigo, |
@zwu52
com.google.firebase.crashlytics.startup1" prio=5 tid=15 Waiting
GoogleApiHandler" prio=5 tid=24 Blocked
Broadcast of Intent act=com.google.android.c2dm.intent.RECEIVE flg=0x11000010
"Crashlytics Exception Handler1" prio=5 tid=20 Waiting
"com.google.firebase.crashlytics.startup1" prio=5 tid=21 Waiting
|
Jack, |
@zwu52 'com.google.android.gms:play-services-base:17.5.0' |
Same issue here |
@Jack29913 Jack, For 1st one on Android 5.0 - Android 7.1, main shows the last trace to be on some shared preference operations. Couple possible reasons that this can happen. 1. Shared preference is dead locked somehow. 2. Shared preference is ok and the stack just trace shows the tail of your processes. This could be caused by slow disk write typically on older devices where storage is less than 1G. For 2nd one on Android 9 - Android 10, the UI thread seems to be just chilling out and not blocked. I'd like to triage this to our Crashlytics folks to further diagnose if possible. @zjamshidi @JeremyR34, the ANR could be caused by various reasons, please check out the #594 to see if it helps. Otherwise, we'll update in this thread. |
Hi everyone - just wanted to let you know that the |
@zwu52 You are true. ANR could be caused by other reasons. I made some changes in my code and will see if the resolve the issue. |
@google-oss-bot ¯_(ツ)_/¯ |
We have high volume of DAUs and we're seeing this ANR more often. Using Any updates on this? -- @nzayatz14 @zjamshidi after updating to 21.0.0 (or above) do you notice any drop in ANRs? |
@joelfernandes19 I actually had a huge increase in ANRs when upgrading to |
I fixed the ANRS. They weren't related to Firebase SDK and the source was how we access the DB. |
@zjamshidi Could you share what kind of changes you made?, maybe I or anyone have the same issue. Thanks, |
The ANR was: So I was suspicious of Firebase SDK but when I checked the stack trace I noticed we wait for reading data from DB in the application onCreate method.
I moved this part from the application onCreate to the first activity after the splash and it's fixed now. In general, what I learned is we should not do or wait for a task that may take longer than 5 seconds (like reading data from db) on the main thread. Very simple! |
@zjamshidi Got it, I'll check that in my app, thanks a lot! |
This is not the case at all. This is the stacktrace of main thread. Also there is no DB access in our app.
|
any luck so far? |
nope. they probably think if no one talks about it, it will magically solve itself. |
Same issue on
It actually removes the dependency on Did anyone try, using BoM |
I have been following this issue for a long time. I found that after I started using App Bundle recently, the anr is much less.I didn't do anything else. |
To organize the thread bit since there is a mix of ANR here, some are resolved some aren't yet resolved. Below are two seemingly ongoing issue: OP @RodolfoGS on FM @Jack29913 on FM |
@mtrezza have you try BOM 27.0.0 or above finally? |
I updated BOM to version 28.0.1, and still have the ANR :(. |
Any update on this? Even we are facing lot many ANR |
Hi @prcaen , @kiranInmobi and rest of friends who are experiencing ANR, I am inclining to close this thread because it's becoming a soup of ANR by different root cause as far as I could tell and hard to read and follow for folks coming later. Please read above & see if you could find your crashes/fixes above. If not, please fill a separate bug attaching a full bug report. As you might have noticed from above, ANR could be caused by many factors including low RAM/disk, fcm related, non-fcm related issues. Majority of the stack traces provided don't contain enough information for us to diagnose forward. So if a comprehensive bug report or logcat could be provided that would super helpful and greatly appreciated. Cheers 🍺 |
Hey @RodolfoGS. We need more information to resolve this issue but there hasn't been an update in 5 weekdays. I'm marking the issue as stale and if there are no new updates in the next 5 days I will close it automatically. If you have more information that will help us get to the bottom of this, just add a comment! |
Since there haven't been any recent updates here, I am going to close this issue. @RodolfoGS if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this. |
[READ] Step 1: Are you in the right place?
Issues filed here should be about bugs in the code in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:
with the firebase tag.
google group.
of the above categories, reach out to the personalized
Firebase support channel.
[REQUIRED] Step 2: Describe your environment
[REQUIRED] Step 3: Describe the problem
Appear tons of ANR errors in Play Console related to firebase messaging. And a lot of users have the same problem and are reporting in a closed issue of 2 years ago (2018).
Issue closed that continues active with more than 50 comments and 33 participants firebase/quickstart-android#594
Steps to reproduce:
I can't reproduce, I just see the issues in the play console.
Relevant Code:
The text was updated successfully, but these errors were encountered: