Closed
Bug 1108271
Opened 9 years ago
Closed 6 years ago
[System] Only start the idle timer until the boot is complete
Categories
(Firefox OS Graveyard :: Gaia::System, defect)
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: tzimmermann, Assigned: alive)
References
Details
Attachments
(1 file)
There's a timeout of 60 sec after which the System app switches off the screen by releasing a wakelock. The emulator-{jb,kk} requires five to six minutes for startup, two of them in Gaia (no kidding). Consequently, the system suspends during startup. Automated testing fails in this case with a timeout.
Reporter | ||
Comment 1•9 years ago
|
||
I think this should be solved by keeping suspending disabled unconditionally until startup has been finished.
Comment 3•9 years ago
|
||
Yeah I can put this in my queue. Is this urgent?
Assignee: nobody → timdream
Flags: needinfo?(timdream)
Comment 4•9 years ago
|
||
Update the title to make it more descriptive.
Summary: FxOS suspends during startup → [System] Only start the idle timer until the boot is complete
Reporter | ||
Comment 5•9 years ago
|
||
(In reply to Tim Guan-tin Chien [:timdream] (MoCo-TPE) (please ni?) from comment #3) > Yeah I can put this in my queue. Is this urgent? It's not urgent, but should have priority over regular features. We want to get emulator-kk ready and this is currently the one unresolved blocker.
Comment 6•9 years ago
|
||
(In reply to Thomas Zimmermann (on PTO) [:tzimmermann] [:tdz] from comment #5) > (In reply to Tim Guan-tin Chien [:timdream] (MoCo-TPE) (please ni?) from > comment #3) > > Yeah I can put this in my queue. Is this urgent? > > It's not urgent, but should have priority over regular features. We want to > get emulator-kk ready and this is currently the one unresolved blocker. The system app start-up patch is current a mess, it would be hard for the part of the system (specifically, ScreenManager) to realize the time the phone actually boots. The quick workaround is to set mozSettings value "screen.timeout" of the profile-to-test to 0, which will make the screen never sleeps. We should do that first to unblock your work.
Comment 7•9 years ago
|
||
(In reply to Tim Guan-tin Chien [:timdream] (MoCo-TPE) (please ni?) from comment #6) > The system app start-up patch is current a mess, it would be hard for the > part of the system (specifically, ScreenManager) to realize the time the > phone actually boots. > > The quick workaround is to set mozSettings value "screen.timeout" of the > profile-to-test to 0, which will make the screen never sleeps. We should do > that first to unblock your work. Greg, Does lock screen / lock screen window manager currently emits events to the System app scope saying either "Hey, the main panel is shown." or "Hey, I am loaded but lock screen is not enabled." during System app boot-up? I think these are the two events needed for this bug.
Flags: needinfo?(gweng)
Comment 8•9 years ago
|
||
Main panel is a part of the index.html of System app, if your 'shown' means HTML is ready, it's implicit done by loading the page at bootstraping. If you mean the initialization code of LockScreen has been executed, we need to create it. However, since there is a 'lockscreen-appopened' which means the app window animation is done, I think it should be 'lockscreen-appready' or something like that, which is similar to the idea of allowing app to dispatch an event through API or IAC that I've sent a mail to dev-gaia and then been totally ignored.
Flags: needinfo?(gweng)
Updated•9 years ago
|
Status: NEW → ASSIGNED
Updated•9 years ago
|
Flags: needinfo?(timdream)
Reporter | ||
Comment 10•9 years ago
|
||
Hi This bug blocks any progress with automated tests on emulator-kk. Can we find a solution in the foreseeable future?
Severity: normal → blocker
Comment 11•9 years ago
|
||
Hi Thomas, I thought changing the "screen.timeout" value will unblock? Is that not the case?
Flags: needinfo?(tzimmermann)
Reporter | ||
Comment 12•9 years ago
|
||
(In reply to Tim Guan-tin Chien [:timdream] (MoCo-TPE) (please ni?) from comment #11) > Hi Thomas, > > I thought changing the "screen.timeout" value will unblock? Is that not the > case? Hi Is there a way to make this the default on emulators? We'd like to run automated tests on emulator-kk.
Flags: needinfo?(tzimmermann) → needinfo?(timdream)
Comment 13•9 years ago
|
||
You can do something like this, pass a SCREEN_TIMEOUT=0 from BoardConfig.mk: https://github.com/mozilla-b2g/device-rpi/blob/ab404c/BoardConfig.mk#L54 If DEVICE_DEBUG=1 (I don't know where is it being set), the timeout will be changed to 300 sec https://github.com/mozilla-b2g/gaia/blob/05f8670/Makefile#L125
Flags: needinfo?(timdream)
Updated•9 years ago
|
Flags: needinfo?(tzimmermann)
Updated•9 years ago
|
Blocks: emulator-l_taskcluster
Updated•9 years ago
|
No longer blocks: emulator-l_taskcluster
Comment 14•9 years ago
|
||
Hi all, This bug is focusing on a long-term solution for system app. I just filed bug 1124567 for a quick workaround for emulator-kk. Let's move there for kk discussion :) I will adjust bug dependency accordingly.
Updated•9 years ago
|
Comment 16•9 years ago
|
||
Probably something doable once bug 1094759 lands.
Depends on: system-bootstrap
Assignee | ||
Comment 17•8 years ago
|
||
Write down my idea here: We could only set the idle timer in ScreenManager when it knows the system is fully loaded. Now there's no this event, but after bug 1094759, we could make system/js/app.js to dispatch an event, or even register a service and in ScreenManager.start() we could: Service.request("fullyLoaded").then(() => { this.setIdleTimeout(); });
Comment 18•8 years ago
|
||
Assignee | ||
Comment 19•8 years ago
|
||
Comment on attachment 8613440 [details] [review] [gaia] alivedise:bugzilla/1108271/set-idle-timeout-once-fullyloaded > mozilla-b2g:master Hi Thomas, could you make sure this work for you or not? Thanks.
Attachment #8613440 -
Flags: feedback?(tzimmermann)
Assignee | ||
Updated•8 years ago
|
Assignee: timdream → alive
Assignee | ||
Comment 20•8 years ago
|
||
(In reply to Alive Kuo [:alive][NEEDINFO!] from comment #17) > Write down my idea here: > > We could only set the idle timer in ScreenManager when it knows the system > is fully loaded. > Now there's no this event, but after bug 1094759, we could make > system/js/app.js to dispatch an event, or even register a service and in > ScreenManager.start() we could: > > Service.request("fullyLoaded").then(() => { > this.setIdleTimeout(); > }); Insteadly, I am using visuallyLoaded (Service.request('schedule')) in the WIP. If it's not working for emulator I will implement the fullyLoaded version.
Assignee | ||
Comment 21•8 years ago
|
||
Note: I am working on reland bug 1094759. Will back to this later
Reporter | ||
Comment 22•8 years ago
|
||
Thanks for all your work! There's no need to rush in a patch for this bug, as we currently have a workaround in place.
Reporter | ||
Comment 23•8 years ago
|
||
Comment on attachment 8613440 [details] [review] [gaia] alivedise:bugzilla/1108271/set-idle-timeout-once-fullyloaded > mozilla-b2g:master I don't know enough about the code to give good feedback on the patch itself. What we need is to keep the emulator running until the automated tests have been started. We currently have a workaround in the emulator's board config, [1] but a solution in gecko/gaia would certainly be better. I'd guess that the automated tests only start after the system sent 'fullyLoaded' and a timeout of 60 seconds might not be enough to reach this state on the emulator. (Booting takes 5+ minutes.) Using 'fullyLoaded' might be safer. There's no good way of testing, because failures only show up as connection timeouts in the test logs. In any case, I'd give a try to any solution you propose. [1] https://github.com/mozilla-b2g/platform_build/pull/97/files
Attachment #8613440 -
Flags: feedback?(tzimmermann)
Comment 24•6 years ago
|
||
Firefox OS is not being worked on
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•