Skip to content
This repository was archived by the owner on May 20, 2026. It is now read-only.

Show tool outputs for Claude - #3502

Merged
TylerLeonhardt merged 1 commit into
mainfrom
tyler/stiff-unicorn
Feb 6, 2026
Merged

TylerLeonhardt merged 1 commit into
mainfrom
tyler/stiff-unicorn

Conversation

@TylerLeonhardt

Copy link
Copy Markdown
Member

Copilot AI review requested due to automatic review settings February 6, 2026 00:15
@TylerLeonhardt TylerLeonhardt self-assigned this Feb 6, 2026
@vs-code-engineering vs-code-engineering Bot added this to the February 2026 milestone Feb 6, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request adds functionality to display tool outputs for Claude agent tools in the VS Code chat UI by populating toolSpecificData on ChatToolInvocationPart instances.

Changes:

  • Implemented completeToolInvocation() function that populates tool-specific output data based on tool type
  • Added tool-specific completion handlers for bash (terminal output), read/ls (file content), glob/grep (search results), and generic tools
  • Integrated the completion logic into both claudeCodeAgent.ts and claudeChatSessionContentProvider.ts to handle tool results from different code paths

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
src/extension/agents/claude/common/toolInvocationFormatter.ts Added completeToolInvocation() function and tool-specific handlers (bash, read, search, generic) to populate toolSpecificData with formatted output
src/extension/agents/claude/node/claudeCodeAgent.ts Integrated completeToolInvocation() call in processToolResult() to populate tool outputs for real-time streaming
src/extension/chatSessions/vscode-node/claudeChatSessionContentProvider.ts Integrated completeToolInvocation() call in _processToolResults() to populate tool outputs when loading chat sessions from disk
src/extension/agents/claude/common/test/toolInvocationFormatter.spec.ts Added comprehensive tests covering all tool types, edge cases (empty output, content block arrays), and output formatting (exit codes, CRLF conversion)

@TylerLeonhardt
TylerLeonhardt added this pull request to the merge queue Feb 6, 2026
Merged via the queue into main with commit c6a59e5 Feb 6, 2026
25 checks passed
@TylerLeonhardt
TylerLeonhardt deleted the tyler/stiff-unicorn branch February 6, 2026 01:03
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Claude Agent: No way to look at the CLI output

3 participants