feat(acp): surface error-class outcomes to the activity feed only, never the channel#1010
Merged
Merged
Conversation
9d8e32a to
0550ddd
Compare
Death/timeout notices are debugging signals that belong in the activity feed (emit_turn_error/observer), not as regular channel messages. Remove all publish_death_notice calls from handle_prompt_result — the observer path already fires for every error outcome and routes to the activity panel. Removes the thread_root extraction that was only consumed by these calls. Co-authored-by: Will Pfleger <pfleger.will@gmail.com> Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
After the channel-notice call sites were removed, publish_death_notice and build_death_notice in relay.rs had zero callers — dead public API that left a path for re-introducing channel notices. Remove them, their EventBuild error variant, and the three builder unit tests. Add error_outcome_emission_tests pinning the policy that error-class outcomes surface only to the activity feed: handle_prompt_result takes no relay handle (channel silence is structural — re-adding a notice would have to re-add the parameter), and each error branch must emit exactly one turn_error observer event (asserted at runtime, red if any branch drops emit_turn_error). Co-authored-by: Will Pfleger <pfleger.will@gmail.com> Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
62b97ba to
05f17da
Compare
This was referenced Jun 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Error-class turn outcomes — agent exits, timeouts, transport errors, and application errors — surface to the agent/observer activity feed and never post a channel message.
Policy
handle_prompt_resultno longer takes a relay handle, so it has no way to send one — re-introducing a channel notice would require re-adding that parameter, which the new test's construction refuses to compile against. Channel silence is enforced structurally, not by assertion.turn_errorobserver event viaemit_turn_error, routed to the activity panel.Changes
crates/buzz-acp/src/lib.rs: drop the relay parameter fromhandle_prompt_resultand its call site. Adderror_outcome_emission_testscovering all error branches —AgentExited,Timeout, a transport-classError(AcpError::Io), and an application-classError(AcpError::IdleTimeout) — each asserting exactly one feed event. The runtime assertion goes red if any branch drops itsemit_turn_errorcall.crates/buzz-acp/src/relay.rs: removepublish_death_noticeandbuild_death_notice(zero callers after the channel-notice call sites were removed), the now-unusedRelayError::EventBuildvariant, and the three builder unit tests plus theirmake_test_relayhelper.publish_death_noticeandbuild_death_noticeno longer exist anywhere in the tree.