Skip to content

[docs] charter: list the BiDi work deferred past Selenium 5 as out of scope - #18293

Open
titusfortner wants to merge 5 commits into
SeleniumHQ:trunkfrom
titusfortner:charter-out-of-scope
Open

titusfortner wants to merge 5 commits into
SeleniumHQ:trunkfrom
titusfortner:charter-out-of-scope

Conversation

@titusfortner

@titusfortner titusfortner commented Nov 9, 2026 •

Copy link
Copy Markdown
Member

🔗 Related Issues

💥 What does this PR do?

  • Specifies additional features that are on our roadmap and clarifies which are out of scope for Selenium 5

🔧 Implementation Notes

Maybe it is worth having a separate road map beyond what is in this document, but this is what I'm thinking for how we approach BiDi implementations based on what we defined in #17670

Subscription Events

There are 24 events that BiDi spec defines. Either we are providing a domain off of the driver to manage these with explicit add/remove/clear methods, or we need to provide users low-level access to them.

Event ADR Domain Selenium 5
network.beforeRequestSent, responseStarted, authRequired #17685 driver.network yes
log.entryAdded, script.message #17776 driver.script yes
browsingContext.userPromptOpened #18283 driver.alerts maybe - proposed by the PR
browsingContext.contextCreated, contextDestroyed Browser context ADR driver.windows no
browsingContext.navigationCommitted, fragmentNavigated, historyUpdated Navigation ADR driver.navigate (one "navigated" handler covers all three) no
browsingContext.downloadEnd File handling ADR driver.file (download handler, fires with the file's path) no
browsingContext.userPromptClosed, downloadWillBegin, navigationStarted, domContentLoaded, load, navigationAborted, navigationFailed None None no
network.responseCompleted, fetchError Network observation ADR driver.network (observe-only handlers, alongside the intercepting ones) no
input.fileDialogOpened None None no
script.realmCreated, realmDestroyed None None no

New BiDi Features

Things BiDi can do that Classic cannot, beyond what the events above cover.

I'm looking at these as how we augment our current API with new functionality with minimal changes. In order of least change to most change required.

  1. Options: When the feature reasonably applies to the entire session, the minimum change for a user is to add it to the browser options and Selenium will send the commands when/if applicable based on the values there. Note, it would be easy to start with a browser option and implement new methods or classes later if people ask for more control.
  2. New Argument Values: If an existing method can accept a new kind of value (a new locator strategy)
  3. Method Parameter: If it is a behavior change to an existing Selenium command, we can add it as an optional parameter or kwarg
  4. Class Method: If it is a new command but belongs to an existing Selenium concept
  5. New Class/API: When the feature is a new concept and has no natural home in the current Selenium API
BiDi supports ADR Level Selenium 5
User contexts User context ADR New Class/API no
Permissions #17677 New Class/API (driver.permissions) no
Screencast (video recording) Screencast ADR New Class/API no
Viewports (size and pixel ratio) Emulation ADR Options no
Extra headers, offline Network commands ADR Class Method (Network) no
File dialog response (files to pick, or cancel; spec proposal w3c/webdriver-bidi#1193) File handling ADR New Class/API (driver.file) no
Web extension (install/uninstall) #17817 Class Method (Driver) no
Locators (Accessibility and inner text) Locator ADR New Argument Values (find element) no
Screenshots (Full-page and clipped) Screenshot ADR Method Parameter (screenshot methods) no
Cookies (set in other contexts) Cookies ADR Method Parameter (cookie methods) no
Emulation (geolocation, locale, timezone, user agent, etc) Emulation ADR Options no
Cache behavior Network commands ADR Options no

Features Built on Pinned Scripts

We've also been discussing a number of features that aren't explicitly BiDi, but are things we can implement with JavaScript pinned to the browser.

Feature ADR Level Selenium 5
DOM mutation handlers #17776 Class Method (Script) yes
Custom page event handlers (add_event_handler) #17776 Class Method (Script) yes
Interaction readiness (click, send keys and clear wait for the element to be actionable) #17886 Options no
Settledness and actionability handlers #17886 Class Method (Script) no

Support ADRs

In addition to supporting new functionality, there are likely to be additional ADRs needed to clarify or support the ADRs that we've agreed are in scope for Selenium 5 (like #17786). This is likely to include a Subscription ADR, and possibly others.

🤖 AI assistance

  • AI assisted (complete below)
    • Tool(s): Claude Code (Claude Fable 5.1)
    • What was generated: the charter wording, the inventory of BiDi events and commands from the spec, and first drafts of the tables
    • I reviewed all AI output and can explain the change

🔄 Types of changes

  • Cleanup (documentation only: release charter scope)

@selenium-ci

Copy link
Copy Markdown
Member

/agentic_describe

@qodo-code-review

qodo-code-review Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

PR Summary by Qodo

Clarify BiDi features deferred beyond Selenium 5

📝 Documentation 🕐 Less than 10 minutes

Grey Divider

AI Description

• Clarify which classic behaviors a future BiDi migration must preserve.
• List context, file-handling, and navigation APIs deferred beyond Selenium 5.
Diagram

graph TD
  A["Selenium 5 charter"] --> B["Deferred BiDi scope"] --> C["Classic migration"] & D["Context APIs"] & E["File handling"] & F["Navigation events"]
Loading
High-Level Assessment

Keep the exclusions in the release charter: reviewers can see deferred work beside the Selenium 5 requirements. A separate roadmap could provide more detail later, but would not replace this boundary.

Files changed (1) +19 / -2

Documentation (1) +19 / -2
selenium-5.mdExpand the charter’s out-of-scope BiDi work +19/-2

Expand the charter’s out-of-scope BiDi work

• Clarifies the classic behavior that a future BiDi migration must preserve and expands the deferred browsing-context API. Adds user-context, file-handling, and navigation capabilities to the work explicitly excluded from Selenium 5.

docs/plans/selenium-5.md

@diemol diemol left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this. Making the deferred work explicit is useful, and I agree with the direction.

The PR description covers more than the diff. These items are in the description tables but missing from "Out of scope":

  • screencast
  • web extensions
  • new locators (accessibility, inner text)
  • full-page and clipped screenshots
  • cookies in other contexts
  • network extra headers, offline, and cache behavior
  • interaction readiness and settledness (#17886)

Should we add them here, or move the full roadmap to a separate doc and link it from the charter?

Comment thread docs/plans/selenium-5.md Resolved
Comment thread docs/plans/selenium-5.md Resolved
Comment thread docs/plans/selenium-5.md Resolved
Comment thread docs/plans/selenium-5.md Resolved
@titusfortner

Copy link
Copy Markdown
Member Author

@diemol yeah, I wanted to describe how I was seeing post-Selenium 5 API for BiDi since we seem to have competing ideas of where we are going. I don't think it all needs to be in this document unless we want to expand what Selenium 5 is. We probably should create a separate roadmap for post-5.

Co-authored-by: David Burns <david.burns@theautomatedtester.co.uk>
@qodo-code-review

qodo-code-review Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

No findings to report

Grey Divider

Tip of the day
💡 Did you know, you can copy the agent prompt from any finding and feed it to your IDE agent

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

⚠️ Qodo did not complete this review — the change was judged trivial and was not reviewed — so this is not a clean bill of health, and approval was withheld.

Grey Divider

Previous reviews

Review updated until commit 1cf9407 ⏭️ Skipped

Results up to commit 75f6a9d ⏭️ Skipped


No changes from previous review

Results up to commit ce82610 ⏭️ Skipped


No changes from previous review

Results up to commit 820ac2e ⏭️ Skipped


No changes from previous review

Results up to commit fc837a4 ⏭️ Skipped


No changes from previous review

Grey Divider

Qodo Logo

@qodo-code-review

Copy link
Copy Markdown
Contributor

Code review by qodo was updated up to the latest commit 820ac2e

@qodo-code-review

Copy link
Copy Markdown
Contributor

Code review by qodo was updated up to the latest commit fc837a4

@diemol

diemol commented Nov 24, 2026

Copy link
Copy Markdown
Member

@titusfortner what is needed to move this one forward?

@selenium-ci

Copy link
Copy Markdown
Member

/agentic_review

@qodo-code-review

Copy link
Copy Markdown
Contributor

Code review by qodo was updated up to the latest commit 1cf9407

@titusfortner

Copy link
Copy Markdown
Member Author

@diemol I made the update David requested, should be ready to approve as is.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants