Closed
Bug 1829801
Opened 1 year ago
Closed 1 year ago
Rule#getCompatibilityIssues guard isn't efficient
Categories
(DevTools :: Inspector: Compatibility, task)
DevTools
Inspector: Compatibility
Tracking
(firefox114 fixed)
RESOLVED
FIXED
114 Branch
Tracking | Status | |
---|---|---|
firefox114 | --- | fixed |
People
(Reporter: nchevobbe, Assigned: nchevobbe)
Details
Attachments
(1 file)
async getCompatibilityIssues() {
if (!this.compatibilityIssues) {
const [targetBrowsers, compatibility] = await Promise.all([
getTargetBrowsers(),
this.inspector.inspectorFront.getCompatibilityFront(),
]);
this.compatibilityIssues = await compatibility.getCSSDeclarationBlockIssues(
this.domRule.declarations,
targetBrowsers
);
}
return this.compatibilityIssues;
}
This function is called for each property in a rule.
The intent is to only retrieve the browsers, the compatibility front, and then the compat issues if it wasn't done before
But here, since we set this.compatibilityIssues
after retrieving the browsers and the front, multiple "concurrent" call will probably end up calling getCSSDeclarationBlockIssues
Assignee | ||
Comment 1•1 year ago
|
||
This patch sets this.compatibilityIssues
earlier so we effectively guard on
multiple "concurrent" calls.
Depends on D176395
Updated•1 year ago
|
Assignee: nobody → nchevobbe
Status: NEW → ASSIGNED
Pushed by nchevobbe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f5fd7e54df34 [devtools] Fix Rule#getCompatibilityIssues guard. r=jdescottes,devtools-reviewers.
Comment 3•1 year ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
status-firefox114:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 114 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•