Closed Bug 1766802 Opened 10 months ago Closed 9 months ago

With the Remote Agent starting earlier the "session.new" command has to wait for the browser window

Categories

(Remote Protocol :: WebDriver BiDi, defect, P2)

Firefox 101
defect
Points:
1

Tracking

(firefox-esr91 unaffected, firefox99 unaffected, firefox100 unaffected, firefox101 fixed)

RESOLVED FIXED
101 Branch
Tracking Status
firefox-esr91 --- unaffected
firefox99 --- unaffected
firefox100 --- unaffected
firefox101 --- fixed

People

(Reporter: whimboo, Assigned: whimboo)

References

(Regression)

Details

(Keywords: regression, Whiteboard: [bidi-m3-mvp])

Attachments

(1 file)

With bug 1759169 landed the Remote Agent gets started before any browser window is open. If a direct BiDi connection requests a new session right after starting the browsre the command immediately returns and as such can cause trouble with following-up BiDi commands that require a browser window:

0:15.59 INFO STDOUT: 1651131463434	WebDriver BiDi	DEBUG	ffd9734f-c718-4690-b6fe-1fb99caf5999 -> {"id":2,"method":"browsingContext.getTree","params":{"maxDepth":0}}
 0:15.60 INFO STDOUT: 1651131463437	RemoteAgent	TRACE	Registered MessageHandlerFrame actors
 0:15.60 INFO STDOUT: 1651131463438	RemoteAgent	TRACE	Created MessageHandler ROOT for session ffd9734f-c718-4690-b6fe-1fb99caf5999
 0:15.60 INFO STDOUT: 1651131463439	RemoteAgent	TRACE	Received command browsingContext.getTree for destination ROOT
 0:15.60 INFO STDOUT: 1651131463440	RemoteAgent	TRACE	Module root/browsingContext.jsm found for ROOT
 0:15.60 INFO STDOUT: 1651131463440	WebDriver BiDi	DEBUG	ffd9734f-c718-4690-b6fe-1fb99caf5999 <- {"id":2,"result":{"contexts":[]}}

Similar to CDP we should wait for sessionstore-windows-restored which can be done with await RemoteAgent.browserStartupFinished;.

This currently blocks my work for creating a test on bug 1719505.

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

Blocks: 1753997
No longer blocks: 1606604
Has Regression Range: --- → yes
Attachment #9274243 - Attachment description: Bug 1766802 - [remote] Delay startup of WebDriver BiDi until all initial application windows have been loaded. → Bug 1766802 - [remote] Delay startup of WebDriver BiDi until all initial application windows have been restored.
Attachment #9274243 - Attachment description: Bug 1766802 - [remote] Delay startup of WebDriver BiDi until all initial application windows have been restored. → Bug 1766802 - [remote] Delay startup of WebDriver BiDi until all initial application windows have been loaded.
Attachment #9274243 - Attachment description: Bug 1766802 - [remote] Delay startup of WebDriver BiDi until all initial application windows have been loaded. → Bug 1766802 - [remote] Delay startup of WebDriver BiDi until all initial application windows have been restored.
Pushed by hskupin@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/67124d2fa796
[remote] Delay startup of WebDriver BiDi until all initial application windows have been restored. r=webdriver-reviewers,jdescottes
Status: ASSIGNED → RESOLVED
Closed: 9 months ago
Resolution: --- → FIXED
Target Milestone: --- → 101 Branch
You need to log in before you can comment on or make changes to this bug.