Closed
Bug 783825
Opened 12 years ago
Closed 12 years ago
Fix b2g breakage after bug 553102
Categories
(Firefox OS Graveyard :: General, defect)
Firefox OS Graveyard
General
Tracking
(blocking-basecamp:+)
VERIFIED
FIXED
blocking-basecamp | + |
People
(Reporter: cjones, Assigned: fabrice)
References
Details
Attachments
(2 files, 5 obsolete files)
11.56 KB,
patch
|
gal
:
review+
|
Details | Diff | Splinter Review |
860 bytes,
patch
|
fabrice
:
review+
|
Details | Diff | Splinter Review |
This prevents the gaia homescreen from starting, among other things.
See https://github.com/mozilla-b2g/gaia/issues/3575
E/GeckoConsole( 78): [JavaScript Error: "Exposing chrome JS objects to content without __exposedProps__ is insecure and deprecated. See https://developer.mozilla.org/en/XPConnect_wrappers for more information." {file: "app://homescreen.gaiamobile.org/js/homescreen.js" line: 113}]
E/GeckoConsole( 78): [JavaScript Error: "Exposing chrome JS objects to content without __exposedProps__ is insecure and deprecated. See https://developer.mozilla.org/en/XPConnect_wrappers for more information." {file: "app://system.gaiamobile.org/js/activities.js" line: 16}]
Reporter | ||
Comment 1•12 years ago
|
||
In particular,
727d3361eafae05eb1de4fbfc8a063666a854910 is the first bad commit
commit 727d3361eafae05eb1de4fbfc8a063666a854910
Author: Bobby Holley <bobbyholley@gmail.com>
Date: Fri Aug 17 23:14:55 2012 -0700
Bug 553102 - Make content-> access default to deny if __exposedProps__ is not defined. r=mrbkap
:040000 040000 ffb373457aa8c841ed2692f9bb2b7d0f62b6a3fe 66c9e43f357edb79ca3f03a40d764199d812a403 M content
:040000 040000 8137a2782c07ab4d1dc7f5cfaccb751a1e4affb8 ea39c4da277d98a27d005f40bd3807f203227dde M dom
:040000 040000 a62ad5cd9f310ad09ac7fdb51743398e1ff01b01 42512d4d4df59a1ecd7e82fe75a90895b25b209d M js
Thanks to "lissyx"!
Assignee | ||
Comment 2•12 years ago
|
||
All data send to content via customEvents (ie. all our mozChromeEvents) must either wrap properly their |details| property of set the _exposedProps_ on |details|.
Summary: Activities API broken by bug 553102 → Fix b2g breakage after bug 553102
Assignee | ||
Updated•12 years ago
|
Component: DOM: Apps → General
Product: Core → Boot2Gecko
Reporter | ||
Updated•12 years ago
|
Assignee: nobody → fabrice
Assignee | ||
Comment 3•12 years ago
|
||
In this patch we take care of wrapping properly the payload of mozChromeEvent events, and also what is sent by system messages.
We already had a wrapping helper in Webapps.jsm, so I moved it (with some improvements to properly support arrays) to its own jsm at dom/base/ObjectWrapper.jsm
For the custom event wrapping, maybe that should be done at a lower level when dispatching the event, since this is now needed by all users of CustomEvent.
Attachment #653121 -
Flags: review?(jones.chris.g)
Attachment #653121 -
Flags: review?(gal)
Reporter | ||
Comment 4•12 years ago
|
||
Comment on attachment 653121 [details] [diff] [review]
patch
Looks fine, but your .jsm is missing.
Attachment #653121 -
Flags: review?(jones.chris.g)
Attachment #653121 -
Flags: review?(gal)
Attachment #653121 -
Flags: review-
Assignee | ||
Comment 5•12 years ago
|
||
Now with the .jsm
Attachment #653121 -
Attachment is obsolete: true
Attachment #653124 -
Flags: review?(jones.chris.g)
Reporter | ||
Comment 6•12 years ago
|
||
Comment on attachment 653124 [details] [diff] [review]
patch v2
r=me if you remove the .rej from this patch
Attachment #653124 -
Flags: review?(jones.chris.g) → review+
Assignee | ||
Comment 7•12 years ago
|
||
Maybe I will manage to submit the right patch :(
Attachment #653124 -
Attachment is obsolete: true
Attachment #653126 -
Flags: review?(jones.chris.g)
Reporter | ||
Updated•12 years ago
|
Attachment #653126 -
Flags: review?(jones.chris.g) → review+
Assignee | ||
Comment 8•12 years ago
|
||
Comment 9•12 years ago
|
||
Backed out in https://hg.mozilla.org/integration/mozilla-inbound/rev/b2559ad2a0fe - the webapps mochitest-chrome tests don't seem to think that was the right patch either ;)
Assignee | ||
Comment 10•12 years ago
|
||
So, it looks like the test are not testing arrays in the manifests correctly, so I removed the check of the allow_installed_from property.
I pushed this patch to try at https://tbpl.mozilla.org/?tree=Try&rev=990d2373cd3e
Assignee | ||
Comment 11•12 years ago
|
||
Actually I found a bug in my wrapping function that was over-wrapping primitive values in arrays.
All tests pass unchanged locally, try run is at:
https://tbpl.mozilla.org/?tree=Try&rev=6fe4e9c28cdb
Attachment #653126 -
Attachment is obsolete: true
Attachment #653149 -
Attachment is obsolete: true
Attachment #653150 -
Flags: review?(jones.chris.g)
Attachment #653150 -
Flags: review?(gal)
Comment 12•12 years ago
|
||
Great, I applied the patch locally, it works :)
Comment 13•12 years ago
|
||
I'm experiencing issues with virtual keyboard: it shows but never disappear. I'm investigating, but already noticed that in apps/keyboard/js/keyboard.js, the event that comes "onfocuschange" seems affected: the "type" being used seems to be constantly "undefined".
Comment 14•12 years ago
|
||
This patch fixes the MozKeyboard events that were not wrapped and hence broke the virtual keyboard (appearing, not disappearing).
Assignee | ||
Comment 15•12 years ago
|
||
Comment on attachment 653155 [details] [diff] [review]
Fixing the MozKeyboard events
Review of attachment 653155 [details] [diff] [review]:
-----------------------------------------------------------------
r=me with nits addressed. Thanks!
::: b2g/components/MozKeyboard.js
@@ +11,4 @@
>
> Cu.import("resource://gre/modules/XPCOMUtils.jsm");
> Cu.import("resource://gre/modules/Services.jsm");
> +Cu.import('resource://gre/modules/ObjectWrapper.jsm');
Nit: double quotes
@@ +104,4 @@
> "detail": msg.json
> };
>
> + let evt = new this._window.CustomEvent("focuschanged", ObjectWrapper.wrap(detail, this._window));
Nit: can you restrict that to 80 chars by moving the second arguments on its own line?
Attachment #653155 -
Flags: review+
Comment 16•12 years ago
|
||
It should address your comments.
Attachment #653155 -
Attachment is obsolete: true
Comment 17•12 years ago
|
||
FYI - This is from a first time b2g/gaia DIY enthusiast. So, please take this report with a pinch of salt...
I am using the b2g desktop client to test.
Before these patches,
1. Cannot see any icon on the home screen. Just saw the wallpaper.
2. Settings screen showed nothing.
With these two set of patches,
1. I can see the home screen with a search icon which brings up firefox.
2. The keyboard fix seems to work for me. i.e. the keyboard hides after done.
But I am unable to see any icons other than the search icon on the home screen. I am using a recent version of b2g and gaia.
b2g -profile /home/vijay/garage/b2g/gaia/profile -no-remote http://system.gaiamobile.org:8080 -jsconsole
Hope this helps.
Thanks!
Assignee | ||
Updated•12 years ago
|
Attachment #653183 -
Flags: review+
Comment 18•12 years ago
|
||
Comment on attachment 653150 [details] [diff] [review]
patch v5
Nice. Karma points if you land a test after you land the fix so we don't break this again.
Attachment #653150 -
Flags: review?(jones.chris.g)
Attachment #653150 -
Flags: review?(gal)
Attachment #653150 -
Flags: review+
Assignee | ||
Comment 19•12 years ago
|
||
Comment 20•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/b95f8a1ca34c
https://hg.mozilla.org/mozilla-central/rev/6c1dfc8d5b4b
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Updated•12 years ago
|
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•