fix(telemetry): a turn that never sent is not a Discord verdict #803
No reviewers
Labels
No labels
move-to-repo
coilyco-bridge-deploy
move-to-repo
coilyco-flight-deck-agent-compose
move-to-repo
coilyco-gaming-eco-app
move-to-repo
coilysiren-inbox
move-to-repo
unknown
🔒⚠️📦⚠️🔒 SANDBOXED 🔒⚠️📦⚠️🔒
autonomy
async-consult
autonomy
epic
autonomy
headless
autonomy
live-collab
c#
priority
P0
priority
P1
priority
P2
priority
P3
priority
P4
role/ai
role/creator
role/design
role/director
role/engineer
role/exec
role/human
role/ops
role/qa
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
coilyco-gaming/sirens-echo!803
Loading…
Reference in a new issue
No description provided.
Delete branch "aos/claude/aw85-turn-failure-classify"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #802. Slices #292's first acceptance criterion, which the field it added could not meet while the classifier ran on the wrong error.
What changed
The turn event classifies a Discord verdict only where one exists.
deliverOrReportmarks the reply send error as it returns, anddiscord.turn.failedclassifies through that marker instead of through the raw turn error. Everything else reportsdiscord_failure: not_attempted.Nothing else moved.
discordFailureAttrsis untouched, sorest_error,abandoned, andno_responsekeep their meanings and the existing tests pinning them keep passing.discord.reply.failedandturn.reply.undeliveredstill classify the send and the notice at their own call sites, where the error is unwrapped and the verdict was always correct.Why the value is a state rather than an absence
not_attemptedis a distinct value because an absentdiscord_failurealready means something else here: an image older than the field.docs/sirens-echo-indistinguishable-values.mdrecords that exact conflation on this series, so answering it with another absence would have reproduced it.Mutation
Classifying the turn error directly again fails four rows of
TestATurnThatNeverSentIsNotADiscordVerdict, and reproduces the production reading exactly: a model stage failure reportsno_response, a turn that ran out of budget reportsabandoned.Dropping the marker at
deliverOrReportfailsTestASendThatFailedKeepsItsVerdictAtTheTurn, which drives a rejecting turn through the seam rather than asserting about the wrapper.What this does not do
It does not attribute the 31 replies #292 was filed on. Those predate every instrument on the series and cannot be split retroactively. 292 stays open on that criterion, which needs a decision rather than code.
It does not reduce any failure rate. It stops one series describing stage failures as delivery failures, so the delivery rate can be read at all.
ward exec gatepasses on the rebased tree.CI is green. Run 20623:
testsuccess,image-buildsuccess.What was red, and why it was not this change
Run 20603 failed one test:
That is the MCP roster path. This branch touches
agent.go(deliverOrReport),replyfailure.go,replyfailure_test.go, and two docs, and nothing it changes is reachable fromMCPProvider.Open. I read the diff before concluding that rather than inferring it from the file list.What I did
Merged current
maininto the branch rather than rebasing, so another session's branch is not rewritten and no commit is discarded. The merge picks up #805'spyproject.tomlhook excludes.ward gategreen on the merged tree - build, policy-check, vet, test, test-skips, pre-commit - and CI green on the push.I did not just rerun until it passed
The single test at
-count=50, the package six times, the package eight times atGOMAXPROCS=2 -parallel 2, and the package twelve times atGOMAXPROCS=2 -parallel 16 -race. All green, no race warnings. So it is a real intermittent that I could not reproduce, not a break this branch introduced and not something the merge fixed.The reason I could not chase it further is worth its own ticket, and is #809:
Opencollects each unreachable server by name only and discards the error, so the failure cannot say whether it was connection-refused, a backoff, or a failed listing.readyLockedproduces a specific error on every branch and none survives. Same shape as #795. That issue asks for the reason to be carried first, so the next occurrence is self-diagnosing instead of costing another investigation.Merge stays director-gated per the repository's
pull-request-and-mergeworkflow.