Skip to content

TPI) Agent Host Copilot terminal command decorations reflect shell exit status #324419

Description

@anthonykim1

Refs: #322163, #323922

Complexity: 2

Create Issue


Verify that terminal command decorations in Agent Host Copilot chat reflect the real exit status of shell commands when the custom terminal tool is disabled (SDK shell tool path).

Background: This only reproduced with the custom terminal tool disabled, where the agent relies on the shell tool from Copilot CLI. With that path, command decorations were previously not reflective of the command's exit status. The decoration should now be driven by the SDK shell exit code: 0 shows success, non-zero shows error, and missing exit metadata shows unknown.

Prerequisites:

  • Use the latest VS Code Insiders
  • Sign in to GitHub Copilot
  • Enable chat.agentHost.enabled (this test is for Agent Host Copilot)
  • Set chat.agentHost.customTerminalTool.enabled to false (custom terminal tool disabled, so the SDK shell tool is used)

Part 1: Successful command shows a success decoration

  • Start an Agent Host Copilot chat
  • Ask Copilot to run a command that succeeds, for example echo hello or ls
  • Confirm the terminal command row in chat shows a success (non-error) decoration marker
  • Confirm the decoration matches the actual 0 exit code

Part 2: Failing command shows an error decoration

  • Ask Copilot to run a command that exits non-zero, for example ls /path/that/does/not/exist or a script that exits with a non-zero code
  • Confirm the terminal command row shows an error decoration marker
  • Confirm the decoration reflects the non-zero exit status (not shown as success)

Part 3: Mixed sequence

  • Ask Copilot to run several commands in a row that mix success and failure
  • Confirm each command's decoration independently reflects its own exit status
  • Confirm a failing command does not cause a following successful command to show as failed, and vice versa

Part 4: Exploratory

  • Try a variety of commands (long-running, quoted args, commands writing files, commands with stderr output) and note any cases where:
    • a successful command shows an error decoration
    • a failing command shows a success decoration
    • the decoration is missing when it should reflect a known exit status
    • the decoration state differs from what the command actually returned

Metadata

Metadata

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions