Open Bug 1720707 Opened 3 months ago Updated 1 month ago

Refactor WebDriver session handling for better BiDi integration

Categories

(Remote Protocol :: WebDriver BiDi, task, P3)

task
Points:
13

Tracking

(Not tracked)

People

(Reporter: whimboo, Unassigned)

References

(Blocks 2 open bugs, )

Details

(Whiteboard: [bidi-m2-mvp])

James is working on a WebDriver session refactoring. The PR can be found at:
https://github.com/w3c/webdriver/pull/1608

This will use composition and mark specific session for HTTP and/or BiDi. This is also necessary for direct BiDi connections:

https://github.com/w3c/webdriver-bidi/pull/99

After the refactoring PR has been landed we have to update our current code around WebDriver session, which will land soon via bug 1691446.

This bug should most likely be added to the M1 milestone. Lets discuss in next weeks meeting.

Points: --- → 8
Priority: -- → P3
Whiteboard: [webdriver:triage] → [bidi-m1-mvp]

After a first glance over the refactoring the following seems to be important (maybe more to add):

  • Rename currentSession to just session
  • Having a base WebDriver session class with properties that can be shared between HTTP and BiDi, and a new Set with the name flags
  • Restricting to a single HTTP session which extends the WebDriver session for HTTP specific features (like current browsing context, timeouts, page load strategy, and others)
  • Allowing one or more BiDi sessions whereby each extends the WebDriver session with BiDi specific features
  • Do not parse webSocketUrl capability for direct BiDi connections
  • Fix webSocketUrl generation to return /session if session is null
Points: 8 → ---
Keywords: meta
Summary: Refactor WebDriver session handling for better BiDi integration → [meta] Refactor WebDriver session handling for better BiDi integration
Whiteboard: [bidi-m1-mvp]

The PR on Github hasn't been reviewed yet, so I'm not fully sure yet if we should add it as P2. I'm more inclined to have it as P3 for now. Also the importance of this bug will depend on any activity by the Puppeteer team. If they don't have spare cycles there won't be a need to add capability matching in milestone 2. Also this is a meta bug, and individual implementation bugs need to be filed. Lets decide in next weeks triage meeting.

Priority: P3 → --
Whiteboard: [bidi-m2-mvp]

Discussed with Julian and I will have to check what's actually required for M2 and file appropriate bugs.

Flags: needinfo?(hskupin)
Priority: -- → P3
No longer depends on: 1731730, 1731743
Flags: needinfo?(hskupin)

A couple of the originally included working items are actually not relevant to the Session refactoring. As such I moved them out. That means the amount of work has been reduced a lot, and I think it's quite ok as a maybe 13 points bug for M2.

Keywords: meta
Summary: [meta] Refactor WebDriver session handling for better BiDi integration → Refactor WebDriver session handling for better BiDi integration
Points: --- → 13
You need to log in before you can comment on or make changes to this bug.