Skip to content

Run the browser suite on one worker - #13

Merged
randroid88 merged 1 commit into
mainfrom
fix/e2e-serial-workers
Aug 3, 2026
Merged

Run the browser suite on one worker#13
randroid88 merged 1 commit into
mainfrom
fix/e2e-serial-workers

Conversation

@randroid88

Copy link
Copy Markdown
Contributor

CI on main went red immediately after #12 merged, on a flaky e2e test that had passed on the identical commit in the PR run.

Diagnosis

fullyParallel: false only serializes tests within a file. Playwright still runs files concurrently, and the worker count varies with the host — one worker locally on Windows, three on Linux, two on a GitHub runner. The suite measures real layout geometry and drives timing-sensitive launcher transitions, some with waits as short as 1500 ms.

Three different tests failed across three runs of the same code, each passing on repeat:

Run Workers Failing test
Linux, local 3 universal search traps focus, scrolls, activates, and restores its opener
CI Windows 2 launcher Search activates the offline Obstacle package and recovers at 720p
CI Windows rerun 2 triggered motion shell actions navigate and safely leave unassigned progress

Every failure was an element that never appeared — the signature of contention, not a product defect. A different test each time rules out a deterministic Windows bug. With retries: 0, any one of them fails the whole run.

Fix

Pin workers: 1. This matches the intent already declared by fullyParallel: false and retries: 0, and makes the suite deterministic across platforms.

It costs wall clock: 5.0m on Linux against 2.3m, and 2.5m on Windows. For a suite whose job is recording exact geometry evidence, determinism is worth that.

Verification

80/80 serially on both platforms.

Limit

This does not prove the application is free of the underlying race. It removes the load that exposes it. A race-free suite would be needed before raising the worker count again, and the comment in the config says so.

🤖 Generated with Claude Code

CI on main went red on a flaky e2e test that passed on the identical commit
in the pull request run.

`fullyParallel: false` only serializes tests within a file. Playwright still
runs files concurrently, and the worker count varies with the host: one worker
locally on Windows, three on Linux, two on a GitHub runner. The suite measures
real layout geometry and drives timing-sensitive launcher transitions, some
with waits as short as 1500 ms, so concurrent load makes it racy in a way that
depends on the machine it happens to run on.

Three different tests failed across three runs of the same code, each passing
on repeat:

- Linux, three workers: universal search traps focus, scrolls, activates, and
  restores its opener
- CI Windows, two workers: launcher Search activates the offline Obstacle
  package and recovers at 720p
- CI Windows rerun, two workers: triggered motion shell actions navigate and
  safely leave unassigned progress

Every failure was an element that never appeared, which is the signature of
contention rather than a product defect. With `retries: 0` any one of them
fails the whole run.

Pinning one worker makes the suite deterministic across platforms and matches
the intent already declared by `fullyParallel: false` and `retries: 0`. It
costs wall clock: 5.0m on Linux against 2.3m, and 2.5m on Windows. Verified
80/80 on both platforms serially.

This does not prove the application is free of the underlying race. It removes
the load that exposes it; a race-free suite would be needed before raising the
worker count again.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Aug 3, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: d3fd2f8a-2e07-4e6c-8471-74e76e3aa7fd

📥 Commits

Reviewing files that changed from the base of the PR and between e513f09 and 76078ac.

📒 Files selected for processing (1)
  • apps/console-lab/playwright.config.ts
📜 Recent review details
⏰ Context from checks skipped due to timeout. (7)
  • GitHub Check: pi bring-up script
  • GitHub Check: native / ubuntu-latest
  • GitHub Check: native / windows-latest
  • GitHub Check: node / ubuntu-latest
  • GitHub Check: e2e / windows-latest
  • GitHub Check: node / windows-latest
  • GitHub Check: e2e / ubuntu-latest
🔇 Additional comments (1)
apps/console-lab/playwright.config.ts (1)

8-17: LGTM!


📝 Walkthrough

Walkthrough

The Playwright configuration sets workers: 1 for the console-lab test suite. Comments explain the relationship to fullyParallel, retries, and host-dependent flakiness in geometry- and timing-sensitive tests.

Changes

Console-lab test execution

Layer / File(s) Summary
Worker serialization
apps/console-lab/playwright.config.ts
Playwright runs with one worker. Comments document the determinism rationale and related settings.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Poem

A rabbit set the worker to one,
So timing tests hop in the sun.
No racing feet,
The runs stay neat,
And flaky geometry comes undone.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly states the main change: running the browser suite with one worker.
Description check ✅ Passed The description directly explains the flaky tests, the one-worker fix, its tradeoff, and verification results.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/e2e-serial-workers
✨ Simplify code
  • Create PR with simplified code
  • Commit simplified code in branch fix/e2e-serial-workers

Comment @coderabbitai help to get the list of available commands.

@randroid88
randroid88 merged commit 2c7dded into main Aug 3, 2026
13 of 15 checks passed
@randroid88
randroid88 deleted the fix/e2e-serial-workers branch August 3, 2026 02:32
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.

1 participant