test: TestCloseAllJoinsStandingTickerAndLaterProcessCanStart flakes on TempDir cleanup (directory not empty)
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 72/100
- Issue 類型
- 缺陷
- 描述清晰度
- 基本清楚
- 活躍度
- 活躍
- 技術堆疊
- go
- 領域
- cli, testing-qa
研究方向
Start with TestCloseAllJoinsStandingTickerAndLaterProcessCanStart in cmd/codeaf and run the provided go test command repeatedly. Trace closeAll and the background writer started by v3TestProcess, including the standing ticker, to find what can outlive closeAll. Done means the test passes at -count=200 and no writer touches the test temp tree after closeAll returns.
由索引模型根據 Issue 內容生成。
描述
What happened
touched packages on PR #1438 went red on cmd/codeaf (2026-09-24, CI run 36037211855). The PR's only cmd/codeaf change is one new case in update_test.go; the failing test is elsewhere in the package:
--- FAIL: TestCloseAllJoinsStandingTickerAndLaterProcessCanStart (0.13s)
testing.go:1464: TempDir RemoveAll cleanup: unlinkat /tmp/codeaf-ci/TestCloseAllJoinsStandingTickerAndLaterProcessCanStart1246116880/003: directory not empty
FAIL github.com/Agent-Field/codeaf/cmd/codeaf 98.730s
Every assertion in the test passes. What fails is t.TempDir()'s own cleanup: something writes into one of the test's temp directories while Go is removing it, after closeAll() has returned. So some writer outlives closeAll, either the later process's standing ticker or another background writer v3TestProcess starts.
Replication
Deterministic (no model). On dev@c26ea9c98, with no other change:
go test -count=30 -run '^TestCloseAllJoinsStandingTickerAndLaterProcessCanStart$' ./cmd/codeaf/
This failed 1 time in 30 on a laptop, with the same TempDir RemoveAll cleanup … directory not empty line. Raising -count makes it show up more reliably.
Field (real models). Not applicable.
Acceptance
go test -count=200 -run '^TestCloseAllJoinsStandingTickerAndLaterProcessCanStart$' ./cmd/codeaf/passes. The fix should make whatever writes into the test's temp tree aftercloseAll()returns stop before it returns, rather than retrying the cleanup or skipping the check. The test exists to prove that nothing writes after Close.
- 主要語言
- Go
- 星號
- 115
- 分支
- 14
- 平均合併
- 8 小時 20 分鐘
- 30 天內合併 PR
- 221
環境準備
我們還沒有檢查這個專案的環境設定檔。先看它的 README,通用步驟見我們的新手貢獻指南。
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
Agent-Field/CodeAF 的其他 Issue
-
area:tests bug
難度 2/5 1-3 小時 新手友好度 68/100
Agent-Field/CodeAF#2026 ·
維護者通常 1 天內回覆
-
app: setup says a dead OpenRouter key works可能已有人在做 關聯的 PR 仍在進行中或已合併。 未關閉
難度 2/5 1-3 小時 新手友好度 77/100
Agent-Field/CodeAF#2022 ·
維護者通常 1 天內回覆
-
area:chat bug sev:papercut
難度 2/5 1-3 小時 新手友好度 68/100
Agent-Field/CodeAF#1805 ·
維護者通常 1 天內回覆
-
area:session bug sev:papercut
難度 2/5 1-3 小時 新手友好度 82/100
Agent-Field/CodeAF#1779 ·
維護者通常 1 天內回覆
-
area:session bug sev:papercut
難度 2/5 1-3 小時 新手友好度 78/100
Agent-Field/CodeAF#1768 ·
維護者通常 1 天內回覆
查看 Agent-Field/CodeAF 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 72/100
limitlessprojects/Go-Hybrid#3342 ·
維護者通常 1 天內回覆
-
status/ready type/bug
難度 2/5 1-3 小時 新手友好度 65/100
buildpacks/pack#2733 ·
維護者通常 1 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 72/100
-
kind/bug needs-priority needs-triage
難度 2/5 1-3 小時 新手友好度 72/100
konveyor/tackle2-hub#1166 · 1 則留言 ·
維護者通常 4 天內回覆
-
難度 2/5 1-3 小時 新手友好度 62/100
router-for-me/CLIProxyAPI#7209 ·
維護者通常 1 天內回覆