flake: TestPromoteChatQueuedMessage
评估
这个 Issue 还没有评估数据。
描述
CI Failure Details
CI Run Link: https://github.com/coder/coder/actions/runs/28843531069
Failed Job: https://github.com/coder/coder/actions/runs/28843531069/job/85542337730 (test-go-pg (macos-latest))
Commit Info:
- SHA:
8b60d1d8777ad65d51341f32672d32b9c9ce7f5a - Author: Ethan
- Date: 2026-07-07T01:44:46Z
- Commit: https://github.com/coder/coder/commit/8b60d1d8777ad65d51341f32672d32b9c9ce7f5a
Failure Output
=== FAIL: coderd TestPromoteChatQueuedMessage/WhileRunning (2.48s)
exp_chats_test.go:9738:
Error: "[]" should have 1 item(s), but has 0
Test: TestPromoteChatQueuedMessage/WhileRunning
Error Analysis
TestPromoteChatQueuedMessage/WhileRunning promotes a queued message while the chat is running and then expects GetChatQueuedMessages to return exactly one queued item (the promoted message) immediately after. In this run, the queued list was empty, indicating the queued message was drained before the assertion. This looks timing-sensitive: the background worker can auto-promote/dequeue the message before the test checks the intermediate queue state.
Root Cause Assessment
Classification: Flaky test (timing-sensitive async queue state)
Data race / crash checks
Scanned the failing job logs around the failure for WARNING: DATA RACE, panic:, and OOM indicators; none found.
Assignment Analysis
Intended blame:
git blame -L 9715,9745 coderd/exp_chats_test.go
Tooling limitation: line-level blame isn’t available here, so I used recent file history as a proxy.
Recent file history:
git log --oneline -10 --follow coderd/exp_chats_test.go- Most recent substantive change:
1eb5d579("fix: unblock manual chat title generation for unowned chats") by Michael Suchacz
- Most recent substantive change:
Assigning to @ibetitsmike as the most recent meaningful modifier of the test file. Please reassign if another owner is more appropriate.
Related Issues
No direct duplicates found after searching for:
- "TestPromoteChatQueuedMessage"
- "TestPromoteChatQueuedMessage/WhileRunning"
- "exp_chats_test.go"
- "should have 1 item(s), but has 0"
- "promote" + "queue" + "chat" in coder/internal
Related but different tests: coder/internal#1529 (chatd promote queued message order), coder/internal#1523 (promote queued while requires action) — different package/tests.
Reproduction (best effort)
go test ./coderd -run TestPromoteChatQueuedMessage -count=1
- 主要语言
- 没有语言数据
- 星标
- 3
- 派生
- 0
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
coder/internal 的其他 Issue
-
flake
难度 2/5 1-3 小时 新手友好度 72/100
-
chore: cleanup http transport debt可能已有人在做 @sreya 于 15 天前认领。 未关闭
-
难度 4/5 3-5 天 新手友好度 45/100
-
flake: TestPubsubCluster/ClusterAuthRequired可能重新可做 @sreya 于 65 天前认领,目前没有进行中的 PR。 未关闭flake
-
flake: TestSnapshotChanged_MultipleConfigFiles (multiple variants)可能重新可做 @Shelnutt2 于 85 天前认领,目前没有进行中的 PR。 未关闭