Closed Bug 1620782 Opened 4 years ago Closed 4 years ago

Can't expand object in Sets with 10 entries or less

Categories

(DevTools :: Console, defect, P1)

73 Branch
Desktop
All
defect

Tracking

(firefox-esr68 unaffected, firefox74 wontfix, firefox75 verified, firefox76 verified)

VERIFIED FIXED
Firefox 76
Tracking Status
firefox-esr68 --- unaffected
firefox74 --- wontfix
firefox75 --- verified
firefox76 --- verified

People

(Reporter: nchevobbe, Assigned: nchevobbe)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file, 1 obsolete file)

Steps to reproduce

  1. Open the console
  2. Evaluate new Set(Array.from({length: 10}, (_, i) => ({item: i})))
  3. Expand the set, the <entries> node and the 0 entry

Expected results

The 0 entry is expanded and I can see item: 0

Actual results

The 0 entry isn't expanded


Note that this doesn't impact Sets with more than 10 entries (e.g. new Set(Array.from({length: 11}, (_, i) => ({item: i}))) is fine)

This does not impact Map.

This is probably because before fetching new properties we check if we already have them in the preview (https://searchfox.org/mozilla-central/rev/5a52cec97c41ae1eda9412dfe6f4099a9af4c7dd/devtools/client/debugger/packages/devtools-reps/src/object-inspector/utils/load-properties.js#182), and that probably triggers some issue

There was an issue for test with less than 10 entries
as we were assuming we already had everything we needed
in the grip preview. This wasn't the case and was making
loading entries object failing.
Since there's not reason we should find actors in the
preview object, and we should have a unified way of
loading objects, whatever their sizes is, this patch remove
this specific behaviour to always load entries.
Jest tests had to be modified or removed, and the mochitest
that is already testing expanding Maps and Sets is enhanced
to make sure this issue is fixed.

Attachment #9131829 - Attachment description: Bug 1620782 - Fix expanding object in Sets of 10 entries or less. r=Honza. → Bug 1620782 - Fix expanding object in Sets of 10 entries or less. r=jlast.
Pushed by nchevobbe@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/dae213f4d583
Fix expanding object in Sets of 10 entries or less. r=jlast.
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 76

Comment on attachment 9131829 [details]
Bug 1620782 - Fix expanding object in Sets of 10 entries or less. r=jlast.

Beta/Release Uplift Approval Request

  • User impact if declined: users won't be able to expands objects in Sets with less than 10 entries in them.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: No
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: 1. Open the console
  1. Evaluate new Set(Array.from({length: 10}, (_, i) => ({item: i})))
  2. Expand the set, the <entries> node and the 0 entry

-> The 0 entry is expanded and I can see item: 0

  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): devtools only, remove a specific use case to use the more general one, automated test added.
  • String changes made/needed:
Attachment #9131829 - Flags: approval-mozilla-beta?
Flags: qe-verify+

When the saveAs option is true, instead of always starting in the default
download directory, remember and reuse the last directory that the user
chose. The content preferences service is used to store the path on a
per-extension basis.

QA Whiteboard: [qa-triaged]

Is this a new issue, or has it been around for a long time?

Flags: needinfo?(nchevobbe)

Comment on attachment 9133697 [details]
Bug 1620782 - downloads.download() should remember the last directory used. r=robwu

Revision D67060 was moved to bug 1395207. Setting attachment 9133697 [details] to obsolete.

Attachment #9133697 - Attachment is obsolete: true

(In reply to Julien Cristau [:jcristau] from comment #6)

Is this a new issue, or has it been around for a long time?

This was a regression from Bug 1579090

Flags: needinfo?(nchevobbe)
Regressed by: 1579090
Has Regression Range: --- → yes
Version: unspecified → 73 Branch

I have reproduced this issue in Nightly v76.0a1 from 2020-03-14 and verified the fix in Nightly v76.0a1 from 2020-03-17 on Windows 10 and Ubuntu 18.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
OS: Unspecified → All
Hardware: Unspecified → Desktop

Comment on attachment 9131829 [details]
Bug 1620782 - Fix expanding object in Sets of 10 entries or less. r=jlast.

approved for 75.0b6

Attachment #9131829 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

I have also verified this fix in Beta v75.0b6 on Ubuntu 18 and Windows 10.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: