Closed Bug 1721398 Opened 3 years ago Closed 3 years ago

browser_jsterm_autocomplete_getters_cache.js fails with server side target switching enabled

Categories

(DevTools :: Console, defect)

defect

Tracking

(Fission Milestone:MVP, firefox92 fixed)

RESOLVED FIXED
92 Branch
Fission Milestone MVP
Tracking Status
firefox92 --- fixed

People

(Reporter: ochameau, Assigned: nchevobbe)

References

Details

(Whiteboard: dt-fission-m3-mvp)

Attachments

(1 file, 1 obsolete file)

$ ./mach mochitest --headless devtools/client/webconsole/test/browser/browser_jsterm_autocomplete_getters_cache.js --setpref devtools.target-switching.server.enabled=true

This one test fail because the browsing context target actor tries to restore the focus during a target switch, which uterly confuses this test which times out over here:
https://searchfox.org/mozilla-central/rev/79a3ae0b0fa6abeca2cb7cf220df293c8dec9207/devtools/client/webconsole/test/browser/browser_jsterm_autocomplete_getters_cache.js#123
We end up trigerring a key shortcut, while the console is no longer focused, instead the web page is.
The page is focused because of this code:
https://searchfox.org/mozilla-central/rev/79a3ae0b0fa6abeca2cb7cf220df293c8dec9207/devtools/server/actors/targets/browsing-context.js#1318
Which unconditionaly tries to restore the focus to the page anytime the target is destroyed. Ideally this should only be done when we close the toolbox and it really shouldn't be done during a target switch.

See bug 1721379, where we are having similar issues, but rather about creation instead of destruction.

Depends on: 1721372
Whiteboard: dt-fission-m3-triage
Assignee: nobody → nchevobbe
Status: NEW → ASSIGNED
Pushed by nchevobbe@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/a1c0b1655e1b
[devtools] Don't restore target configuration on target switching. r=ochameau.
Fission Milestone: --- → MVP
Whiteboard: dt-fission-m3-triage → dt-fission-m3-mvp
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 92 Branch
Attachment #9232169 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: