Closed Bug 1308467 Opened 10 years ago Closed 10 years ago

Inspector is empty when remote debugging Firefox 51 or older from Firefox 52

Categories

(DevTools :: Inspector, defect, P1)

defect

Tracking

(firefox52 fixed)

RESOLVED FIXED
Firefox 52
Iteration:
52.2 - Oct 17
Tracking Status
firefox52 --- fixed

People

(Reporter: jdescottes, Assigned: jdescottes)

References

Details

(Whiteboard: [reserve-html])

Attachments

(1 file)

Regression from Bug 1265796. When trying to remote debug Firefox 51 or older from Firefox 52, the inspector is blank. The following error seems to be the root cause of the issue: Full message: TypeError: CSS_PROPERTIES_DB.properties[name] is undefined Full stack: normalizeCssData@resource://gre/modules/commonjs/toolkit/loader.js -> resource://devtools/shared/fronts/css-properties.js:303:1 initCssProperties<@resource://gre/modules/commonjs/toolkit/loader.js -> resource://devtools/shared/fronts/css-properties.js:222:43 In fronts/css-properties.js we have: > const serverDB = yield front.getCSSDatabase(getClientBrowserVersion(toolbox)); When connected to Firefox 51 or older, this returns an object with a key for each css property name (as expected) _and_ a "from" property which contains the actor id that returned the object. This then fails when trying to add "subproperties", because we don't check that that CSS_PROPERTIES_DB.properties[name] is a valid object.
Iteration: --- → 52.2 - Oct 17
Flags: qe-verify-
Priority: -- → P1
Whiteboard: [reserve-html]
Comment on attachment 8798846 [details] Bug 1308467 - fix fronts/css-properties.js when remote debugging old firefox; https://reviewboard.mozilla.org/r/84228/#review82804 Thank you. This looks good, though one nit before landing, please. ::: devtools/shared/fronts/css-properties.js:302 (Diff revision 1) > > // Add "subproperties" information to the css properties if it's > // missing. > if (!db.properties.background.subproperties) { > for (let name in db.properties) { > + if (typeof CSS_PROPERTIES_DB.properties[name] === "object") { I think both spots should have a short comment explaining the need for the check.
Attachment #8798846 - Flags: review?(ttromey) → review+
Comment on attachment 8798846 [details] Bug 1308467 - fix fronts/css-properties.js when remote debugging old firefox; Thanks for the review Tom. Re-flagging for review because I had to change a bit the implementation of normalizeCssData to avoid duplicating comments. There is now a single loop and a single check for `typeof CSS_PROPERTIES_DB.properties[name] !== "object"` instead of 3. Added a comment for the other check as well.
Attachment #8798846 - Flags: review+ → review?(ttromey)
Comment on attachment 8798846 [details] Bug 1308467 - fix fronts/css-properties.js when remote debugging old firefox; https://reviewboard.mozilla.org/r/84228/#review82924 Thanks. I think this is ok.
Attachment #8798846 - Flags: review?(ttromey) → review+
Pushed by jdescottes@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/9ddbdab896d8 fix fronts/css-properties.js when remote debugging old firefox;r=tromey
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 52
Depends on: 1319015
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: