Repository navigation
fix: make tool progress live-only - #38217
Merged
Merged
Conversation
kitlangton
force-pushed
the
tool-progress-live
branch
from
July 22, 2026 13:04
4f253c8 to
bd9d07c
Compare
This was referenced Jul 22, 2026
jinhuang712
pushed a commit
to jinhuang712/opencode
that referenced
this pull request
Sep 26, 2026
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
Make running tool progress a live replacement snapshot instead of durable session history, suppress unchanged shell snapshots, and preserve useful partial output when a tool fails.
The deterministic shell fixture (
printf steady; sleep 3.4) improves from:This proves deterministic work removal; it does not claim an exact CPU-time reduction.
Before / After
Before
session.tool.progress.1row and was projected, synchronized, and replayed.After
contentand progressmetadata; both fields are omitted when no progress occurred.metadatainto the currentstate.structuredfield, so replayed and reconnected failures retain useful partial state.How
packages/schema/src/session-event.tsmakesSessionEvent.Tool.Progressephemeral.packages/schema/src/session-event.tsgives failures optional non-emptycontentand optional progressmetadatawithout changing the terminalerroroutcome.packages/core/src/session/runner/publish-llm-event.tsretains the latest snapshot in memory and attaches it to each failure path when present.packages/core/src/tool/shell.tssuppresses exact duplicate{ output, truncated }snapshots.packages/core/src/database/migration/20260722011141_delete_tool_progress_events.tsdeletes obsoletesession.tool.progress.1rows and deliberately leavesevent_sequenceunchanged.packages/client/src/promise/generated/types.tsis regenerated from the current protocol.Scope
result, rename projected state, or redesign void output.Testing
cd packages/core && bun test test/database-migration.test.ts test/session-runner-tool-events.test.ts test/session-runner.test.ts test/session-tool-progress.test.ts test/tool-shell.test.ts --only-failures(passed)cd packages/tui && bun test test/mini/stream-v2.transport.test.ts test/cli/tui/data.test.tsx --only-failures(87 passed)cd packages/cli && bun test test/acp/event-behavior.test.ts test/run/noninteractive.test.ts --only-failures(18 passed)cd packages/client && bun run test(43 passed)cd packages/schema && bun test test/event-manifest.test.ts --only-failures(6 passed)cd packages/core && bun run script/migration.ts --check(passed)bun turbo typecheck --concurrency=3passed in all 33 applicable packages.git diff --checkpassed.bun run lintexits nonzero on repository-wide baseline warnings; no changed production file introduced a lint diagnostic.Flow