You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Chromium reuses the initial empty document's window, and its browser interface pipe, for an iframe's first same-origin navigation. Tools registered while parsing race the navigation commit in the browser process and are sometimes lost, with getTools() never resolving in that frame.
The three iframe tests now reload the frame once on first load, so the second document registers its tools reliably.
1 failed
❌ [firefox] › mcp/idle-timeout.spec.ts:19 › closes the browser after the idle timeout and relaunches it on the next call @mcp-windows-latest-firefox
🟢 The one failure is a pre-existing flake — this PR is clear
Hi, I'm the Playwright bot and I triaged the failing CI run.
[firefox] › mcp/idle-timeout.spec.ts:19 is a known flake on the mcp-windows-latest-firefox bot: it has failed 6 of 229 runs (2.6%) in the aggregated CI results, on five other PRs with the same error. This PR only edits tests/mcp/cli-webmcp.spec.ts, so it can't reach it.
Details
This PR changes a single test file — tests/mcp/cli-webmcp.spec.ts, +9/-3 — with no product code touched. Nothing it changes is shared with mcp/idle-timeout.spec.ts, and everything else in the report is green (8704 passed, 1474 skipped).
Pre-existing flake / infra
[firefox] › mcp/idle-timeout.spec.ts:19 › closes the browser after the idle timeout and relaunches it on the next call (@mcp-windows-latest-firefox) — the same (project, file, title) on the same bot failed on five unrelated PRs, all with the identical signature:
It's Windows-Firefox only — 0 failures across the other 12 MCP bots (mcp-ubuntu-latest-firefox 0/236, mcp-macos-latest-firefox 0/232), so this is bot-specific, not something a test-file edit would produce.
The failure is the relaunch after the idle timeout losing the race with the browser teardown:
- ObjectContaining { "snapshot": StringContaining "Hello, world!" }
+ Object { "snapshot": undefined }
### Error
Error: browserBackend.callTool: Target page, context or browser has been closed
The second browser_navigate lands while the --idle-timeout=500 shutdown is still tearing the Firefox instance down, so it errors instead of relaunching. Worth a look under #42548, the issue this test already annotates — but it's independent of this PR.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
getTools()never resolving in that frame.Fixes #42869