Repository navigation
fix(telemetry): stop reporting user-stopped tools as tool errors - #1620
altimate-software-factory[bot] wants to merge 1 commit into
Conversation
Factory lane: altimate_code. Agent-Authored-By: altimate-factory
|
Important Review skippedBot user detected. To trigger a single review, invoke the
|
|
This PR doesn't fully meet our contributing guidelines and PR template. What needs to be fixed:
Please edit this PR description to address the above within 2 hours, or it will be automatically closed. If you believe this was flagged incorrectly, please let a maintainer know. |
|
Thanks for your contribution! This PR doesn't have a linked issue. All PRs must reference an existing issue. Please:
See CONTRIBUTING.md for details. |
|
👋 This PR was automatically closed by our quality checks. Common reasons:
If you believe this was a mistake, please open an issue explaining your intended contribution and a maintainer will help you. |
Summary
Automated fix proposed by the Altimate software factory; a maintainer reviews every change.
The problem, fix and criteria below are the agent's own account; check them against the diff.
Problem
When the user stops a session while a tool is pending or running, the processor closes the tool part with 'Tool execution aborted' and the prompt loop counted that requested cancellation as a tool failure, sending an error_fingerprint event.
Fix
Tools closed with 'Tool execution aborted' after the session's own abort signal fired are no longer sent as error_fingerprint tool errors, while unrequested aborts and other tool errors are still reported.
Acceptance criteria
Changes
4 files changed, 43 lines added, 1 lines removed.
packages/opencode/src/altimate/telemetry/error-detail.tspackages/opencode/src/session/processor.tspackages/opencode/src/session/prompt.tspackages/opencode/test/telemetry/requested-tool-abort.test.tsNew tests
packages/opencode/test/telemetry/requested-tool-abort.test.tsIndependent review: accepted, confidence 0.86
Verification
Summary by cubic
Stops the prompt loop from reporting tools interrupted by the user's own stop action as tool error fingerprints. When the session's abort signal fired and the tool's error is exactly 'Tool execution aborted', the tool part is now skipped; unrequested aborts and other tool errors are still reported as before.
Bug Fixes
TOOL_ABORTED_ERRORconstant used by the processor and the newisRequestedToolAborthelper.Written for commit 05b96b8. Summary will update on new commits.