Skip to content

fix(web): name Mcode thread tools and approvals in plain words - #2274

Merged
chuks-qua merged 2 commits into
mainfrom
fix/issue-2270-mcode-tool-labels
Oct 21, 2026
Merged

chuks-qua merged 2 commits into
mainfrom
fix/issue-2270-mcode-tool-labels

Conversation

@chuks-qua

@chuks-qua chuks-qua commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

What

Mcode thread tools used to show their raw names in the timeline, such as thread_target_list. A call with no arguments also showed {} beside the name. A decided tool approval read "Allowed once mcp__mcode__thread_target_list".

Now each thread tool row has a plain label, such as "Listed targets". This holds for running, finished, failed, and grouped rows. A row whose input is empty shows no detail. A tool approval receipt names the tool the same way its row does, both live and after reload.

I verified it with a real supervised Claude turn in Electron that called thread_target_list. The captures below show the same thread on the old and new renderer. Targeted web tests pass (105 files, 1099 tests), and typecheck and oxlint are clean. The new tests failed on the old code (54 failures).

Closes #2270

Why

People who direct agents read these rows to follow what the agent did. Raw MCP names and a stray {} make that harder to read, and the receipt disagreed with the row above it.

UI Changes

Before. The row shows the raw name and {}, the group reads "1 thread_target_list call", and the receipt shows the prefixed name.

After. The row reads "Listed targets", the group reads "Listed targets 1 time", and the receipt reads "Allowed once Listed targets".

The running row also reads "Listed targets" while it waits for approval.

Review Notes

  • The pending approval card still shows the exact tool name and input. That card is where the user decides, so the precise name matters there.
  • thread_create_batch gets no label. Only the legacy external transport exposes it.
  • A tool with no usable input detail no longer falls back to showing its own name as the detail. One existing test pinned that fallback, and it now expects the label alone.

before-thread-target-list

after-thread-target-list

after-running-row


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

Rows for workspace, worktree, target, and thread tools now use plain labels
in finished, failed, running, and grouped states. A call with no arguments
shows no detail instead of {} or its raw tool name. Tool approval receipts
name the tool the way its row does.
@chuks-qua
chuks-qua merged commit 09967c6 into main Oct 21, 2026
11 checks passed
@chuks-qua
chuks-qua deleted the fix/issue-2270-mcode-tool-labels branch October 21, 2026 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Mcode tool rows show raw names and empty {} input

1 participant