Comfy-Org / Comfy-Org/Comfy-Desktop
Eliminate flaky E2E tests, starting with cancel-flow teardown
- Dominant language
- TypeScript
- Stars
- 458
- Forks
- 59
- Avg merge
- 22h 18m
- Merged PRs (30d)
- 45
Description
## Problem
Flaky tests are defects. A test that passes only after retry or fails intermittently cannot protect the codebase and blocks unrelated changes.
The immediate failure was the macOS E2E job on #1400:
- Job: https://github.com/Comfy-Org/Comfy-Desktop/actions/runs/31748945915/job/94610014647
- Test: `e2e/cancel-flow.test.ts:161`
- Failure: the `afterAll` hook and worker teardown exceeded 45 seconds after 73 tests passed.
- Playwright classified the test as flaky.
The same stack passed macOS E2E at the adjacent #1399 and #1401 heads, which confirms intermittent behavior rather than a deterministic #1400 code failure.
## Scope
- Identify the root cause of the `cancel-flow.test.ts` teardown race or resource leak on macOS.
- Review recent Comfy-Desktop CI results for other tests reported as flaky or passing only after retry.
- Fix every confirmed flaky test at its narrowest shared lifecycle owner.
- Do not mask failures by adding retries, skipping tests, or increasing timeouts without evidence that the timeout represents valid product behavior.
## Acceptance criteria
- `cancel-flow.test.ts` completes teardown deterministically on macOS.
- Every other confirmed flaky test found during the audit has a root-cause fix or a separately linked issue with an owner and reproduction evidence.
- The affected tests pass repeatedly without retries on each applicable platform.
- The full E2E suite passes on Windows, macOS, and Linux.
- The issue records the failure mechanism and verification evidence before closure.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with e2e/cancel-flow.test.ts:161 and the linked macOS CI job to inspect the afterAll hook and worker teardown failure. Review recent Comfy-Desktop CI results for other flaky or retry-passing tests, then run the affected tests repeatedly and the full E2E suite on Windows, macOS, and Linux. Done means deterministic teardown, root-cause fixes or owned follow-up issues, and verification evidence recorded.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, playwright, typescript
- Domain
- ci-cd, desktop, testing
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100