Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

APIs relying on focus checks are now failing in wpt.fyi. #50622

Open
arskama opened this issue Feb 11, 2025 · 0 comments
Open

APIs relying on focus checks are now failing in wpt.fyi. #50622

arskama opened this issue Feb 11, 2025 · 0 comments

Comments

@arskama
Copy link
Contributor

arskama commented Feb 11, 2025

Since 20.10.2024 all the CP pressure tests are failing on wpt.fyi

It can be also reproduced locally with:
third_party/blink/tools/run_wpt_tests.py --target=Release --product=chrome external/wpt/compute-pressure/compute_pressure_observe_idempotent.https.window.js

First analysis:

The tests are ran on GlobalScope: window and dedicatedWorkers

bef892c489 ended up introducing this regression which also affects the Generic Sensor web tests (and any other API that depends on focus checks).

The issue's the

To consolidate calls that reset state, refactor the WebDriver executor's testharness window management to align with #45735.

part of the change.

When we call https://w3c.github.io/webdriver/#new-window to create a new tab with about:blank, we hit this part of the Chromium code that focuses the address bar instead of the page. This can also be checked by manually typing "about:blank" in the address bar and pressing Alt+Enter -- the new tab will have the address bar focuses, while any other URL will focus the page itself.

The rest of the code never switches focus to the page even though navigation later sets should_focus_location_bar_by_default_ back to false.

It's not clear if this needs to be fixed in WebDriver, ChromeDriver, Chrome or devtools. Any hints?

A similar issue was reported to crbug with no answer yet.

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

No branches or pull requests

1 participant