Closed Bug 1967673 Opened 1 year ago Closed 1 year ago

Show undefined properties in the list of properties when logging Indexed DB results

Categories

(DevTools :: Object Inspector, defect, P3)

defect

Tracking

(firefox-esr115 wontfix, firefox-esr128 wontfix, firefox138 wontfix, firefox139 wontfix, firefox140 fixed)

RESOLVED FIXED
140 Branch
Tracking Status
firefox-esr115 --- wontfix
firefox-esr128 --- wontfix
firefox138 --- wontfix
firefox139 --- wontfix
firefox140 --- fixed

People

(Reporter: jdescottes, Assigned: nchevobbe)

References

(Blocks 1 open bug, Regression)

Details

(Keywords: regression)

Attachments

(1 file)

See discussion on Bug 1966885, we should show undefined properties in the list of properties.

Do we know which bug/patch regresses this ?

(In reply to Jan Varga [:janv] from comment #1)

Do we know which bug/patch regresses this ?

My mozregression seems to be busted at the moment, but I'm seeing the issue in Firefox ESR 128, so if it is a regression (which I'm not sure it is), it's not recent. It's also probably not related to IndexedDB, but more likely that the IDBRequest is highlighting this specific issue (might be because result is a getter, but I didn't look into our implementation yet)

Ok, that makes sense, thank you.

This is where the undefined result property gets ignored: https://searchfox.org/mozilla-central/rev/c18faaae88b30182e487fa3341bc7d923e22f23a/devtools/server/actors/object.js#480-483

const getterValue = this._evaluateGetter(desc.get);
if (getterValue === undefined) {
  continue;
}

I think this was regressed by Bug 1554914 where we created _evaluateGetter but missed the case where we would get an undefined result (where before we'd only omit the property if it wasn't returning anything) https://searchfox.org/mozilla-central/rev/c18faaae88b30182e487fa3341bc7d923e22f23a/devtools/server/actors/object.js#524,529-531

const result = getter.call(this.obj);
...
if ("return" in result) {
  getterValue = result.return; // this might be `undefined`, but we want it

Looks like an easy fix, we can return a Symbol from _evaluateGetter when we couldn't get the getter value and check against it in _findSafeGetterValues

Keywords: regression
Regressed by: 1554914

Set release status flags based on info from the regressing bug 1554914

Assignee: nobody → nchevobbe
Status: NEW → ASSIGNED
Pushed by nchevobbe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/fc2f97b5ece1 [devtools] Don't omit valid safe getter undefined values in _findSafeGetterValues. r=devtools-reviewers,jdescottes
Pushed by amarc@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/a46f62e1559a Revert "Bug 1967673 - [devtools] Don't omit valid safe getter undefined values in _findSafeGetterValues. r=devtools-reviewers,jdescottes" by dev request
Flags: needinfo?(nchevobbe)

(In reply to amarc from comment #9)

Backed out by dev request: https://hg.mozilla.org/integration/autoland/rev/a46f62e1559ad4e3328adcc11a19b5c04c4fdb89

added test is failing in a11y_checks, like the others tests expanding object inspector, so let's add a fail_if annotation here too

Flags: needinfo?(nchevobbe)
Pushed by nchevobbe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/6a257ef19d91 [devtools] Don't omit valid safe getter undefined values in _findSafeGetterValues. r=devtools-reviewers,jdescottes
Pushed by ctuns@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/430010732d6e Revert "Bug 1967673 - [devtools] Don't omit valid safe getter undefined values in _findSafeGetterValues. r=devtools-reviewers,jdescottes" for causing failures with "1 not in success codes: [0] "

Backed out for causing multiple failures on macOS

  • Backout link
  • Push with failures
  • Failure Log
  • Failure line: 1 not in success codes: [0]
    Halting on failure while running ('/usr/local/bin/python3', '/opt/worker/tasks/task_174816769173650/mozharness/external_tools/macosx_resolution_refreshrate.py', '--check=refresh-rate')
Flags: needinfo?(nchevobbe)
Pushed by ctuns@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/7b97528bb2d6 [devtools] Don't omit valid safe getter undefined values in _findSafeGetterValues. r=devtools-reviewers,jdescottes DONTBUILD

That failures in https://bugzilla.mozilla.org/show_bug.cgi?id=1967673#c13 were cause by something else, I relanded it.

Flags: needinfo?(nchevobbe)
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 140 Branch
QA Whiteboard: [qa-triage-done-c141/b140]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: