Skip to content

Need to replace input_id when coalescing existing input event to unblock the thread #43136

@yezhizhen

Description

@yezhizhen

Describe the bug:
I've been intensively writing WebDriver input events with duration for past few months.
Sometimes, the test just randomly TIMEOUT.
Previously it is just mousemove, but now it happens for Wheel too, seems to be after ##43074.

The problem is, when we replace existing event,

if let InputEvent::Wheel(ref mut existing_wheel) = existing.event.event {
, we did not replace the input_id.

This is important, because we synchronously block the thread for last event:

fn send_blocking_input_event_to_embedder(&mut self, input_event: InputEvent) {
let (result_sender, result_receiver) = unbounded();
if self
.send_message_to_embedder(WebDriverCommandMsg::InputEvent(
self.verified_webview_id(),
input_event,
Some(result_sender),

Metadata

Metadata

Assignees

Labels

A-content/scriptRelated to the script threadA-webdriverI-raceA race between two concurrent pieces of code.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions