Startup crash - java.lang.IllegalStateException: This ViewTreeObserver is not alive, call getViewTreeObserver() again
Categories
(Firefox for Android Graveyard :: General, defect)
Tracking
(firefox-esr60 wontfix, firefox-esr6869+ verified, firefox67 wontfix, firefox67.0.1 wontfix, firefox68 wontfix, firefox69 verified)
People
(Reporter: andrei.a.lazar, Assigned: andrei.a.lazar)
References
Details
(Whiteboard: [fennec68.1])
Crash Data
Attachments
(2 files)
|
47 bytes,
text/x-phabricator-request
|
RyanVM
:
approval-mozilla-esr68+
|
Details | Review |
|
47 bytes,
text/x-phabricator-request
|
RyanVM
:
approval-mozilla-beta+
RyanVM
:
approval-mozilla-esr68+
|
Details | Review |
Steps to reproduce:
- fresh install Fennec / clear all data
- close all internet connections
Expected result:
Onboarding screen is being shown
Actual result:
Application crashes with IllegalStateException
Crash sig:
java.lang.IllegalStateException: This ViewTreeObserver is not alive, call getViewTreeObserver() again
at android.view.ViewTreeObserver.checkIsAlive(ViewTreeObserver.java:850)
at android.view.ViewTreeObserver.removeOnGlobalLayoutListener(ViewTreeObserver.java:579)
at org.mozilla.gecko.home.TabMenuStripLayout$1.onGlobalLayout(TabMenuStripLayout.java:136)
| Assignee | ||
Updated•7 years ago
|
| Assignee | ||
Comment 1•7 years ago
|
||
Now checking the global view tree observer to see if it's alive in order to unsubscribe from further
notifications.
| Assignee | ||
Updated•7 years ago
|
Pushed by nbeleuzu@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/ea121152fa96
Startup crash - java.lang.IllegalStateException: This ViewTreeObserver is not alive, call getViewTreeObserver() again r=petru
Comment 3•7 years ago
|
||
| bugherder | ||
Comment 4•7 years ago
|
||
esr68=affected because we should consider uplifting this crash fix to Fennec ESR 68.0.x or 68.1.
Comment 5•7 years ago
|
||
Andrei, we'll want to uplift your crash fix to Fennec ESR 68.1.
Comment 7•7 years ago
|
||
Hello, I can confirm that the crash doesn't occur on Beta 69.0b6 using:
- Motorola Moto G6 (Android 8);
- Samsung Galaxy S8 (Android 9);
- Google Pixel (Android Q);
| Assignee | ||
Comment 8•7 years ago
|
||
Comment on attachment 9075132 [details]
Bug 1562622 Startup crash - java.lang.IllegalStateException: This ViewTreeObserver is not alive, call getViewTreeObserver() again r=petru
ESR Uplift Approval Request
- If this is not a sec:{high,crit} bug, please state case for ESR consideration: This is critical because it reproduces 100% of time.
- User impact if declined: Users will encounter a significant amount of crashes.
- Fix Landed on Version:
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): This is a small change and doesn't change any behavior but rather adds a sanity check.
- String or UUID changes made by this patch:
Comment 9•7 years ago
|
||
Comment on attachment 9075132 [details]
Bug 1562622 Startup crash - java.lang.IllegalStateException: This ViewTreeObserver is not alive, call getViewTreeObserver() again r=petru
Fixes a Fennec topcrash. Approved for 68.1b3.
Updated•7 years ago
|
Comment 10•7 years ago
|
||
| bugherder uplift | ||
Comment 11•7 years ago
|
||
Hi!
Verified as fixed on ESR 68.1b3 with OnePlus 5T (Android 9) and Motorola Nexus 6 (Android 7.1.1).
I will mark this as verified on Firefox esr68. Thanks!
Updated•7 years ago
|
Comment 13•7 years ago
|
||
I just upgraded to 68.1b3 and still seeing this crash:
https://crash-stats.mozilla.org/report/index/1a6546bf-01e7-48b1-a25f-dbf050190724
Updated•7 years ago
|
| Assignee | ||
Comment 14•7 years ago
|
||
Can you give me some STR please? I can't manage to repro this with the initial STR
Comment 15•7 years ago
|
||
If I rotate the orientation of my phone while Firefox is open, it will crash about 50% of the time. It doesn't matter what is open in Firefox.
Locking the phone's orientation prevents the crash.
Comment 16•7 years ago
|
||
Hi!
I tested the behavior described in Comment 15 on ESR 68.1b3, Beta 69.0b8 with OnePlus 5T (Android 9), Sony Xperia Z5 Premium (Android 7.1.1), Google Pixel (Android Q) and I could not reproduce it.
robsmith11: Please provide the device name and Android version.
Thank you!
Comment 17•7 years ago
|
||
Hi Eliza, that should be in the crash report of comment 13.
Comment 18•7 years ago
|
||
Looks as if the device is HUAWEI EVR-L29 (Huawei Mate 20 X), and the API is 28.
Comment 19•7 years ago
|
||
Hi! I tested this on ESR 68.1b3, Beta 69.0b9 with Huawei Mate 20 Lite (Android 8.1) and I wasn't able to reproduce the behavior from Comment 15. Thanks!
Comment 20•7 years ago
|
||
How do I run Firefox for Android in Safe Mode so that I can confirm the bug is not triggered by one of my settings?
Comment 21•7 years ago
|
||
BTW, searching using the crash report shows hundreds of other installs with thousands of other crashes across many devices and manufacturers, so I don't think it's device specific. Should a new bug ticket be opened for this?
Comment 22•7 years ago
|
||
robsmith11: Hello!
(In reply to robsmith11 from comment #20)
How do I run Firefox for Android in Safe Mode so that I can confirm the bug is not triggered by one of my settings?
You can try by Clearing Data from Android settings or reinstalling Fennec. Another option is to restart you device in safe mode.
(In reply to robsmith11 from comment #21)
BTW, searching using the crash report shows hundreds of other installs with thousands of other crashes across many devices and manufacturers, so I don't think it's device specific. Should a new bug ticket be opened for this?
Yes, a new ticket is needed, where we can add any new information and keep track of the issue. Thank you!
Comment 23•7 years ago
|
||
How do I back up and restore my profile (without root)?
I've installed Nightly and it's not crashing, so it's likely a setting but I don't want to lose my entire profile.
Comment 24•7 years ago
|
||
Comment 25•7 years ago
|
||
Even though I am not assigned I was requested to review this bug as a potential issue to another bug 1565488. I noticed the use of a local method variable being referenced from a callback method onGlobalLayout which could cause the NPE condition prior to the isAlive() check on the observer object. It is convention to everything I have seen to retrieve the TreeObserver object again inside the callback to ensure you have the latest reference provided.
I have attached a differential that will do exactly this and thereby eliminate the exception that is occuring.
| Assignee | ||
Updated•7 years ago
|
Comment 26•7 years ago
|
||
Hi Brad, can you please request Beta/ESR68 approval on this patch too when you get a chance? Thanks!
Comment 27•7 years ago
|
||
Comment on attachment 9081733 [details]
Bug 1562622 - Calling getViewTreeObserver again to get new object to test isAlive().;r?VladBaicu
ESR Uplift Approval Request
- If this is not a sec:{high,crit} bug, please state case for ESR consideration: Requested by RyanVM to eliminate NPE condition.
- User impact if declined: Continued NPEs reported daily.
- Fix Landed on Version:
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): Re-getting the GlobalLayout is considered normal practice for this object's usage.
- String or UUID changes made by this patch: *NONE
Comment 28•7 years ago
|
||
Pushed by rvandermeulen@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/2fab9efb6ec5
Calling getViewTreeObserver again to get new object to test isAlive().;r=VladBaicu
Comment 29•7 years ago
•
|
||
Comment on attachment 9081733 [details]
Bug 1562622 - Calling getViewTreeObserver again to get new object to test isAlive().;r?VladBaicu
Potential Fennec topcrash fix. Approved for Fennec 68.1b5 and landing now for the 2-Aug nightly builds.
Updated•7 years ago
|
Comment 30•7 years ago
|
||
| bugherder uplift | ||
Comment 31•7 years ago
|
||
| bugherder uplift | ||
Comment 32•7 years ago
|
||
| bugherder | ||
Updated•7 years ago
|
Updated•5 years ago
|
Description
•