fix: suppress exec stderr warnings from covering channel replies (#94360)#94374
Closed
joelnishanth wants to merge 1 commit into
Closed
fix: suppress exec stderr warnings from covering channel replies (#94360)#94374joelnishanth wants to merge 1 commit into
joelnishanth wants to merge 1 commit into
Conversation
Contributor
|
Superseded by #94428, landed as 7cca3d4. The landed Feishu-owned fix preserves committed answer text, appends independent error finals, handles cumulative snapshots, and retains the existing size fallback. Thank you @joelnishanth for investigating #94360 and contributing a fix. |
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.
Summary
⚠️ 🛠️ Exec failed) are sent as user-visible reply messages to all channels (Feishu, Telegram, Discord, etc.), covering the agent's actual response.resolveToolErrorWarningPolicy, exec tools are caught by the mutating-tool branch (line 202) before reaching the exec-specific suppression (line 210), making that suppression dead code forexec/bashtools.verbose: fullis on, the command timed out, or it is a middleware error.Linked context
Closes #94360
Related #93251 (same bug class — Telegram tool-failure message leak)
Real behavior proof (required for external PRs)
Copy-Item ... failed) sent as a visible⚠️reply in Feishu, covering the agent's actual response.pnpm test -- src/agents/embedded-agent-runner/run/payloads.errors.test.ts src/agents/embedded-agent-runner/run/payloads.test.tsbuildEmbeddedRunPayloadsreturns only the assistant text payload (no⚠️warning) for exec errors when the assistant already has a visible reply.Tests and validation
pnpm test -- src/agents/embedded-agent-runner/run/payloads.errors.test.ts— 56 passedpnpm test -- src/agents/embedded-agent-runner/run/payloads.test.ts— 36 passedRisk checklist
Yes— exec tool failure warnings are no longer sent to external channels when the assistant already replied (unless verbose, timeout, or middleware error).NoNoverbose: fullto see all details.Current review state
— Joel Nishanth · offlyn.AI
Made with Cursor