Closed Bug 919902 Opened 11 years ago Closed 11 years ago

[B2G][Helix][System][denghuachang]Device can not enter OS and stay on the third logo after uninstall some applications

Categories

(Core Graveyard :: DOM: Apps, defect, P1)

ARM
Gonk (Firefox OS)
defect

Tracking

(blocking-b2g:hd+, firefox25 wontfix, firefox26 wontfix, firefox27 fixed, b2g18 wontfix, b2g-v1.1hd fixed, b2g-v1.2 fixed)

RESOLVED FIXED
mozilla27
blocking-b2g hd+
Tracking Status
firefox25 --- wontfix
firefox26 --- wontfix
firefox27 --- fixed
b2g18 --- wontfix
b2g-v1.1hd --- fixed
b2g-v1.2 --- fixed

People

(Reporter: lecky.wanglei, Assigned: fabrice)

References

Details

Attachments

(3 files, 1 obsolete file)

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; aff-kingsoft-ciba; .NET4.0C; .NET4.0E; Tablet PC 2.0)

Steps to reproduce:

[Probability]
High, about 3 devices / 1 hour
[repro steps]
No SD card, No sim card, WIFI connected.
1. Download applications(about 100 applications on the Top 100) from Marketplace through WIFI and install.
2. Play some applications, then quit. 
3. Uninstall some applications randomly.
4. Press Powerkey to restart the device.

repeat steps 2、3、4 ,sometimes  steps 3、4.


Actual results:

Device can not enter OS and stay on the third logo. 


Expected results:

Device can enter OS and work well.

[Analyze & Question]
Device always stay on the third logo even reboot.
When it appears, press powerkey still can wakeup/sleep the device, and press volume key can +/- the volume, we can see the volume progress bar on the top bar at the same time.
Touch the screen and try to unlock it as the normal device. We can hear the unlock sound. Device always stay on the third logo during the above operations

We get the data from the FrameBuffer or press home+power to take a screenshot, the data is also the third logo.It is a gaia/gecko bug. 

It is a fatal bug and can not recover. 

thanks
Severity: normal → blocker
blocking-b2g: --- → hd?
Flags: needinfo?(wchang)
OS: All → Gonk (Firefox OS)
Priority: -- → P1
Hardware: All → ARM
Attached file bugreports.part01.rar
Attached file bugreports.part02.rar
Hi Keven,

Can you dedicate some resource to check this? It seems very concerning.
Flags: needinfo?(wchang) → needinfo?(kkuo)
Lecky,

1> can you provide the software information you detected this on?

2> Can you makes sure this is reproduced on Mozilla gecko/gaia builds as well and provide the software information?

Marco, FYR
Flags: needinfo?(mchen)
Flags: needinfo?(lecky.wanglei)
Hi Wayne,

I debug with the device, I find that all the download applications under "/data/local/webapps" can be found in /data/local/webapps/webapps.json. but there is one application record in the webapps.json can not be found under "/data/local/webapps".
so I do another test, under "/data/local/webapps", I rmove one application(such as "twitter"), but doesn't remove it from the webapp.json, the issue can repro with 100% probability.

so I think the root reason is that system has a low probability that do not remove the application from the /data/local/webapps/webapps.json sucessfully while unistall one application.

thanks
Flags: needinfo?(lecky.wanglei)
Hi Wayne,
According to my analysis, it happens after uninstall the application "alezaa". 
And from logcat(applogcat-log.1), I find it is difference as the normal uninstall:
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
(correct)
09-23 16:15:50.589 I/Gecko   (  468): -- webapps.js uninstall http://enclavegames.com/play/captain-rogers-fxos/manifest.webapp?feature_profile=1f7ffffb839b.45.2
09-23 16:15:50.629 I/Gecko   (  159): -- webapps.js uninstall http://enclavegames.com/play/captain-rogers-fxos/manifest.webapp?feature_profile=1f7ffffb839b.45.2

(maybe error)
09-23 16:15:57.249 I/Gecko   (  468): -- webapps.js uninstall http://read.alezaa.com/firefox_app/manifest.webapp?feature_profile=1f7ffffb839b.45.2
09-23 16:16:00.019 I/Gecko   (  159): -- webapps.js uninstall http://read.alezaa.com/firefox_app/manifest.webapp?feature_profile=1f7ffffb839b.45.2
09-23 16:16:00.429 I/Gecko   (  468): -- webapps.js uninstall http://read.alezaa.com/firefox_app/manifest.webapp?feature_profile=1f7ffffb839b.45.2
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Maybe the application alezaa is uninstalled two times or some errors.

please give us some suggestions to fix it.
Hi Tim,

Based on comment 5, it seems there is a issue on the consistence between "/data/local/webapps/webapps.json" and "/data/local/webapps/XXX" after uninstalling apps. Could you help to check this? Thanks.
Flags: needinfo?(timdream)
Flags: needinfo?(mchen)
Flags: needinfo?(kkuo)
Unfortunately I can't help with Gecko part here.
Flags: needinfo?(timdream)
Hi Fabrice,

Please refer to comment 7 and could you help this case? Thanks.
Flags: needinfo?(fabrice)
Thanks Marco, I'll take a look at that bug tomorrow.
Assignee: nobody → fabrice
Component: Gaia::Homescreen → DOM: Apps
Flags: needinfo?(fabrice)
Product: Boot2Gecko → Core
Status: UNCONFIRMED → NEW
Ever confirmed: true
Attached patch patch (obsolete) — Splinter Review
This patch recovers gracefully from such errors. They actually should not happen in the first place but that will only be fixed once we refactor the registry storage.
Attachment #812440 - Flags: review?(ferjmoreno)
Fabrice,

This bug has only been seen happening on helix, but it looks like it could happen for any release. Would you recommend this to be landed on v1.1 as well so that other OEMs taking the v1.1 update can benefit or should i restrict this to helix only to resolve their concerns?

thanks,
Flags: needinfo?(fabrice)
Comment on attachment 812440 [details] [diff] [review]
patch

Review of attachment 812440 [details] [diff] [review]:
-----------------------------------------------------------------

Did you mean to only fix this for B2G? If I am not wrong "_processManifestForIds" is not executed for desktop or android.

Also, comment 6 suggests that the uninstall method might be called twice. Could that be the reason of the webapps.json file inconsistency? We probably shouldn't allow an uninstall request while another one is already being processed.
Attachment #812440 - Flags: review?(ferjmoreno)
(In reply to Fernando Jiménez Moreno [:ferjm] (needinfo, please) from comment #13)
> Comment on attachment 812440 [details] [diff] [review]
> patch
> 
> Review of attachment 812440 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> Did you mean to only fix this for B2G? If I am not wrong
> "_processManifestForIds" is not executed for desktop or android.

You're right. New patch coming.

> Also, comment 6 suggests that the uninstall method might be called twice.
> Could that be the reason of the webapps.json file inconsistency? We probably
> shouldn't allow an uninstall request while another one is already being
> processed.

tbh, I think we'll get rid of all this class of issues once we have a better storage backend (bug 910469). If we could finish bug 910466 soon that would help.
Flags: needinfo?(fabrice)
(In reply to Wayne Chang [:wchang] from comment #12)
> Fabrice,
> 
> This bug has only been seen happening on helix, but it looks like it could
> happen for any release. Would you recommend this to be landed on v1.1 as
> well so that other OEMs taking the v1.1 update can benefit or should i
> restrict this to helix only to resolve their concerns?
> 
> thanks,

Are people still taking patches for 1.1? If so, I have no objections to backport.
Attached patch patch v2Splinter Review
Now also cleaning up in the android/desktop code path.
Attachment #812440 - Attachment is obsolete: true
Attachment #812722 - Flags: review?(ferjmoreno)
Attachment #812722 - Flags: review?(ferjmoreno) → review+
https://hg.mozilla.org/mozilla-central/rev/4ad7201d5318
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla27
Nominating this bug for leo? as when it is hit, it is unrecoverable unless a factory reset is performed and the device essentially becomes unusable. - Low hit rate, but high impact.

This has however so far only been reported on helix, but looking at Fabrice's patch it seems to be possible for this to occur on any device. So nominating leo? for all v1.1 releases.

If this doesn't qualify for leo+, please hd+ for helix has hit this.
blocking-b2g: hd? → leo?
See Also: → 906618
Hi Wayne&&Beatriz:
Please help us to push this patch merged on V1.1HD asap. Thank you very much!
:wayne I think its too late for leo at this point, but do you want to get this in 1.1HD atleast ?
Flags: needinfo?(wchang)
(In reply to bhavana bajaj [:bajaj] from comment #21)
> :wayne I think its too late for leo at this point, but do you want to get
> this in 1.1HD atleast ?

Agree, will take this in HD.

Fabrice, can you please help with a v1.1HD backport on this? :) Thank you.
blocking-b2g: leo? → hd+
Flags: needinfo?(wchang) → needinfo?(fabrice)
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: