From 7ff81de2b6f20b3e5c66e87025c1ee0d9f5b5f97 Mon Sep 17 00:00:00 2001 From: Ilia Denisov Date: Fri, 15 May 2026 08:39:22 +0200 Subject: [PATCH] ui/frontend: cap Playwright at 4 workers, retry 4 times Under host-mode runner the default 6 workers + 1 retry consistently land on ~7 flakies and an occasional hard fail per ui-test run (ui-test #59 most recently). Workers share CPU and the host Docker daemon with gitea, the long-lived dev stack, and the user's host Caddy; the extra wall time from contention pushes individual expectations past their timeouts. Lower the worker cap to 4 to keep parallelism but give each worker real CPU headroom, and raise retries to 4 so the rare slow page is absorbed without surfacing as failure. Co-Authored-By: Claude Opus 4.7 (1M context) --- ui/frontend/playwright.config.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ui/frontend/playwright.config.ts b/ui/frontend/playwright.config.ts index 9cc4531..f2d664c 100644 --- a/ui/frontend/playwright.config.ts +++ b/ui/frontend/playwright.config.ts @@ -5,7 +5,13 @@ export default defineConfig({ testDir: "tests/e2e", fullyParallel: true, forbidOnly: !!process.env.CI, - retries: process.env.CI ? 1 : 0, + // host-mode CI runner shares CPU/IO with the long-lived dev stack, + // gitea, and the user's host Caddy. The default 6 workers + 1 + // retry produced ~7 flakies + 1 hard fail per ui-test run; cap at + // 4 workers (still parallel) and allow 4 retries to ride out + // transient timing hiccups without inflating wall time. + workers: 4, + retries: process.env.CI ? 4 : 0, reporter: [["list"], ["html", { open: "never" }]], use: { baseURL: "http://localhost:5173",