Closed
Bug 951888
Opened 11 years ago
Closed 11 years ago
[System] Application does not degrade gracefully when `mozMobileConnections` is undefined
Categories
(Firefox OS Graveyard :: Gaia::System, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: jugglinmike, Assigned: arthurcc)
References
Details
Attachments
(1 file)
When run in contexts that do not implement the `navigator.mozMobileConnections` API, the System application (specifically `airplane_mode.js` [1]) raises an uncaught exception.
This is particularly troublesome in automated testing environments, where uncaught exceptions (even non-critical ones) can interrupt test execution.
This bug specifically causes an intermittent failures in the integration tests for the JavaScript Marionette client (see bug 950973, along with the failing build on TravisCI [2]).
[1] https://github.com/mozilla-b2g/gaia/blob/744f691f670dae93f160dc1199592a033b30b78a/apps/system/js/airplane_mode.js#L157
[2] https://travis-ci.org/mozilla-b2g/marionette-js-client/builds/15585099
Comment 1•11 years ago
|
||
Assigning to ej chen since it looks like this came in as part of bug 945140
Assignee: nobody → ejchen
Assignee | ||
Comment 2•11 years ago
|
||
Gaia has already migrated to the new mobile connection API. I would suggest to update the testing environments to the latest gecko instead of patching gaia.
Comment 3•11 years ago
|
||
The travis environment has been running on the latest b2g desktop build available at time of test kickoff from b2g-incoming for quite a while now. We can't get any more new than that. It's that we don't build mozMobileConnection into Desktop.
Assignee | ||
Updated•11 years ago
|
Assignee: ejchen → arthur.chen
Comment 5•11 years ago
|
||
Hey Arthur, I guess bug 956428 is because of the same issue. If so, could you take care of it as well?. Thanks.
Flags: needinfo?(arthur.chen)
Comment 7•11 years ago
|
||
This is now blocking both FTE and Rocketbar integration tests since they run on B2G desktop. Will the AirplaneModeHelper be landing soon, and should that help this?
Assignee | ||
Comment 8•11 years ago
|
||
Alive, could you help review this one line patch? Thanks.
Attachment #8360889 -
Flags: review?(alive)
Updated•11 years ago
|
Attachment #8360889 -
Flags: review?(alive) → review+
Assignee | ||
Comment 9•11 years ago
|
||
master: f976d8d8673753d4816197744ac60880855aaeb7
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Comment 10•11 years ago
|
||
So if I'm reading this patch right, now we just disallow setting of airplane mode if mozMobileConnections doesn't exist? What about wifi and bluetooth?
Assignee | ||
Comment 12•11 years ago
|
||
(In reply to Kyle Machulis [:kmachulis] [:qdot] from comment #10)
> So if I'm reading this patch right, now we just disallow setting of airplane
> mode if mozMobileConnections doesn't exist? What about wifi and bluetooth?
Good point. Currently airplane mode relies on the existence of mozMobileConnections and which does not make sense. Let's fix the undefined error in this patch. I've filed bug 960861 for tracking the issue.
You need to log in
before you can comment on or make changes to this bug.
Description
•