WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
323444
[WebDriver] Ensure classic commands on a given session are queued during execution
https://bugs.webkit.org/show_bug.cgi?id=323444
Summary
[WebDriver] Ensure classic commands on a given session are queued during exec...
Lauro Moura
Reported
2026-09-04 09:58:44 PDT
Currently, the code in Source/WebDriver does not explicitly enqueue the incoming WebDriver classic commands for a given session, a behavior required by the spec's processing model[1]:
> Enqueue a task on remote end's request queue to run the following steps: > (steps for session validation, request parsing, etc) > (wait for navigation to complete) > (run actual command) > (error and reply steps)
As we do not enforce such queue, this opens the door to have effectively concurrent commands running at a given time. For example, this happened in a downstream test suite where a regular heartbeat command arrived while a slow/stuck command was still pending. The slow operation widened the window for such race, but this can happen during normal operation too. This should be fixed because running commands in parallel can break a number of invariants within the WebDriver classic implementation. For example, current browsing context tracking within Session.cpp, waitForNavigationToComplete callbacks and timers, etc. These lead to failures like indefinite hangs, often requiring to restart both the driver and the browser. In fact, `waitForNavigationToCompleteOnPage` already has `ASSERT(!m_loadTimer.isActive())` Note that Session-less commands like `/status` and `POST /session` (new session) are free to run unqueued. [1]
https://www.w3.org/TR/webdriver2/#processing-model
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2026-09-11 09:59:13 PDT
<
rdar://problem/187215746
>
Lauro Moura
Comment 2
2026-09-27 21:41:19 PDT
Pull request:
https://github.com/WebKit/WebKit/pull/75103
EWS
Comment 3
2026-10-02 04:48:41 PDT
Committed
322485@main
(87c1e2d36d8e): <
https://commits.webkit.org/322485@main
> Reviewed commits have been landed. Closing PR #75103 and removing active labels.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug