Skip to content

Commit ee7c252

Browse files
committed
docs(plan): finish the flake taxonomy — four classes, two opposite fixes
Chasing this to the end turned one problem into four, and two of them take opposite treatment: Bun runtime crash upstream, not ours external binary in test removed the dependency (sidebar/gh) wasted setup in a test merged four harnesses into one budget below real work raised it (tray, claude ping) The test for which treatment applies is whether the wait is intrinsic to the assertion. Sidebar spawned gh to prove route reachability, so the spawn was incidental and got deleted. The tray test launches PowerShell, then Bun, then rebinds the port to prove the child never inherited the socket -- the processes are the proof, so it gets a budget instead. The tray number came from arithmetic, not taste: production allows PowerShell 15s while the test allowed 5s, and a contended runner falls between. Observed failure was 5159ms. Also records the condition that keeps this from reading as permission to silence flakes: raising a budget requires the ablation to still fail. Otherwise it is just silence, which is the fault 020 criticizes.
1 parent 7093459 commit ee7c252

1 file changed

Lines changed: 38 additions & 0 deletions

File tree

devlog/_plan/260731_pr_issue_triage_round/050_windows_ci_flake_rca.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,3 +122,41 @@ Windows CI가 빨갈 때 **테스트 이름부터 보지 말고 로그 끝을
122122
`panic(thread N): Internal assertion failure`가 있으면 그 테스트는 무죄다.
123123
Bun 업스트림 이슈이고, 우리 쪽에서 고칠 수 있는 게 아니다. 크래시 리포트 링크가
124124
로그에 함께 찍힌다.
125+
126+
## 마무리 — 네 가지 클래스였다
127+
128+
끝까지 가보니 "Windows CI 플레이크"는 하나가 아니라 넷이었다. 구분을 못 하면
129+
엉뚱한 걸 고치거나, 고칠 수 없는 걸 붙잡고 있게 된다.
130+
131+
| 클래스 | 증상 | 처분 |
132+
|---|---|---|
133+
| Bun 런타임 크래시 | 테스트 실패 0건 + `panic(thread N)` | 업스트림. 우리가 못 고친다 |
134+
| 외부 바이너리 의존 | sidebar가 진짜 `gh`를 띄움 | **의존을 제거**했다 |
135+
| 테스트 내부 자원 낭비 | server-auth가 하니스를 4번 세움 | 하나로 합쳤다 |
136+
| 예산이 실제 작업보다 짧음 | tray, claude 핑 | **예산을 늘렸다** |
137+
138+
2번과 4번이 정반대 처방인 게 핵심이다. 판단 기준은 하나다:
139+
**그 기다림이 주장(assertion)에 본질적인가.**
140+
141+
- sidebar는 아니었다. 라우트 도달 가능성과 비밀 미직렬화를 증명하는 데 `gh`
142+
프로세스는 부수적이다. → 제거.
143+
- tray는 본질적이다. PowerShell이 Bun 자식을 띄우고 포트를 다시 bind해서
144+
**소켓을 상속하지 않았다는 걸 증명**한다. 프로세스가 곧 주장이다. → 예산.
145+
146+
tray 수치도 추측이 아니라 산수였다. 프로덕션이 PowerShell에 15초를 주는데
147+
(`src/tray/windows.ts:476`) 테스트 예산은 5초였다. 부하 걸린 러너는 그 사이에
148+
떨어진다. 관측된 실패가 5159ms.
149+
150+
macOS의 claude 핑 테스트도 같은 계열이다. 90ms 침묵에 25ms 핑 간격이면 여유가
151+
3.6배인데 `>=3`을 요구했다. 타이머 하나가 뭉치면 깨진다. 300ms로 늘렸고
152+
**assertion은 그대로다** — ablation으로 핑 분기를 죽여보니 여전히 실패한다.
153+
154+
### 예산을 늘려도 되는 조건
155+
156+
이 문서가 "빨간색은 예산 늘리면 된다"로 읽히면 안 된다. 조건은 둘 다 참일 때다:
157+
158+
1. 그 기다림이 테스트가 증명하려는 것에 본질적이다.
159+
2. **ablation이 여전히 실패한다** — 즉 예산을 늘려도 테스트가 진짜 결함을 잡는다.
160+
161+
2번을 확인 안 하면 그냥 침묵이다. `020`에서 무력한 테스트 세 건을 지적해놓고
162+
같은 짓을 하는 셈이 된다.

0 commit comments

Comments
 (0)