feat(tools): run a clock on a tool that is still going - #25
Merged
Conversation
A running tool's row said `Running…` and nothing else, for as long as it
took. Upstream runs a live clock on it — a shell call reads
`$ <cmd> (6s · 7 lines)` while it works, so a reader can tell a slow
command from a hung one without interrupting to find out.
The line count needs output while the tool is still running, and
deepseek-harness publishes nothing at all between `tool/call` and
`tool/result` — verified by tracing every event on the bus during a
command that prints for eight seconds. So the elapsed half is what can be
told truthfully, and that is what the row now carries:
⏺ Bash(for i in 1 2 3 4 5 6 7 8; do echo line-$i; sleep 1; done)
⎿ Running… (8s)
Held back for the first second, so a call that returns immediately never
flashes a `(0s)`. It rides the ticker that already drives the blinking
bullet, so there is no new timer.
Also adds a `bash_stream` gallery scenario — a command that emits over
time is the only way to see a running row at all.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
What
A running tool's row said
Running…and nothing else, for as long as it took.Claude Code 2.1.235 runs a live clock on it — a shell call reads
$ <cmd> (6s · 7 lines)while it works, so a reader can tell a slow command from a hung one without interrupting to find out.What can't be matched, and why
The line count needs output while the tool is still running, and deepseek-harness publishes nothing at all between
tool/callandtool/result. Traced every event on the bus during a command that prints for eight seconds:So the elapsed half is what can be told truthfully, and that is what the row carries. No progress channel is faked.
Details
Held back for the first second, so a call that returns immediately never flashes a
(0s). It rides the 500 ms ticker that already drives the blinking bullet — no new timer.Test
npm run typecheck,npm test— 150 files / 1950 passingnode scripts/verify-boundary.mjstoolBrief.test.ts: the clock shows at 6s, and never renders(0s)bash_streamgallery scenario — a command that emits over time is the only way to see a running row at all🤖 Generated with Claude Code