flake: TestTelemetry (multiple variants, postgres connection refused)
- Dominant language
- No language data
- Stars
- 3
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
CI Run: https://github.com/coder/coder/actions/runs/26866035162
Job: https://github.com/coder/coder/actions/runs/26866035162/job/79229809346
Commit: b49344519bd44dd98db76198ed2410fa0fd09d4c (Spike Curtis)
Failures:
- coderd/telemetry TestTelemetry_BoundaryUsageSummary/IncludedInSnapshot
- coderd/telemetry TestTelemetry/IDPOrgSync
Error evidence:
```
telemetry_test.go:1458: Mock Clock - Set(2026-06-03 05:53:02.256146 +0000 UTC)
...
2026-06-03 05:53:04.252 [erro] unable to create deployment snapshot ...
error= get chat message summaries:
...
- dial tcp 127.0.0.1:5432: connectex: No connection could be made because the target machine actively refused it.
*** slogtest: log detected at level ERROR; TEST FAILURE ***
```
```
2026-06-03 05:53:04.200 [erro] unable to create deployment snapshot ...
error= get chats updated after:
...
- dial tcp 127.0.0.1:5432: connectex: No connection could be made because the target machine actively refused it.
*** slogtest: log detected at level ERROR; TEST FAILURE ***
```
Root cause classification: Infrastructure / embedded Postgres availability. Telemetry snapshot queries failed with a local Postgres connection refused mid-test, suggesting the embedded DB stopped responding.
Race/Panic/OOM evidence: none found in logs (no "WARNING: DATA RACE", "panic:", or OOM indicators).
Assignment analysis:
- git log --oneline -10 --follow coderd/telemetry/telemetry_test.go
- b221632615 "fix: wipe user secrets when user is soft-deleted" (Zach)
- a31e476623 "fix: make boundary usage telemetry collection atomic" (Zach)
- 0611e90dd3 "feat: add time window fields to telemetry boundary usage" (Zach)
Recent changes to telemetry/boundary usage tests are from Zach; assigning for triage.
Related issues searched (none found for this failure mode):
- "BoundaryUsageSummary", "IDPOrgSync", "dial tcp 127.0.0.1:5432", "connectex" in coder/internal
- Closed issues #645 and #678 are IDPOrgSync flakes but with different root causes (timeout/data race)
Reproduction:
- go test ./coderd/telemetry -run "TestTelemetry/IDPOrgSync|TestTelemetry_BoundaryUsageSummary/IncludedInSnapshot" -count=1
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with coderd/telemetry/telemetry_test.go and run the supplied go test command with -count=1. Trace the embedded Postgres setup and the failing TestTelemetry and TestTelemetry_BoundaryUsageSummary variants to determine why 127.0.0.1:5432 stops responding mid-test. Done means the failure is reproducible and its cause is addressed or clearly documented with a regression check.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, postgres
- Domain
- databases, testing
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100