Skip to content

Don't truncate commands + show running commands#1775

Open
Minigamer42 wants to merge 2 commits intopingdotgg:mainfrom
Minigamer42:feature/preserve-runtime-tool-details
Open

Don't truncate commands + show running commands#1775
Minigamer42 wants to merge 2 commits intopingdotgg:mainfrom
Minigamer42:feature/preserve-runtime-tool-details

Conversation

@Minigamer42
Copy link
Copy Markdown

@Minigamer42 Minigamer42 commented Apr 6, 2026

What Changed

  • Removed the manual truncateDetail call for tool calls send by the agent (the output is still truncated via css ellipsis in the UI, but can be viewed by hovering)
  • Show the command while it is running with optionally a different label

Why

  • Longer commands got truncated in the UI
  • Sometimes the agent would run a command in the background and get stuck (like an interactive binary or something that takes very long to complete). Currently the UI gives no feedback on that until the command exits or you kill it via taskmgr or similar.

UI Changes

  • State before this PR:
truncated title
  • Longer command string visible:
unformatted title
  • Different label while the command is running:
running command
  • Same command with formatting:
formatted title

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • I included before/after screenshots for any UI changes
  • I included a video for animation/interaction changes

Note

Medium Risk
Changes tool lifecycle event payloads and client-side collapsing logic, which could increase event payload size and alter how work-log rows merge/render during active turns.

Overview
Improves tool/command visibility in the timeline by preserving full detail for tool.started/tool.completed events (no server-side truncation) and by attaching itemId to tool lifecycle activity payloads so entries can be reliably correlated end-to-end.

Updates Codex runtime mapping to label command_execution as "Running command" on start, and updates the web work-log derivation to include running command rows while collapsing started/updated/completed events using a stable collapseKey (preferring itemId) so lifecycle rows merge correctly even when events aren’t adjacent.

Reviewed by Cursor Bugbot for commit b042087. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Show running commands in chat and stop truncating command detail

  • tool.started events for command_execution items are now included in the work log (previously all tool.started events were filtered out), displaying a "Running command" title while in progress and "Ran command" on completion.
  • Command detail payloads are no longer truncated in tool.started and tool.completed activities in ProviderRuntimeIngestion.ts.
  • Collapse logic in session-logic.ts is reworked to group lifecycle entries by collapseKey (preferring itemId) across non-adjacent entries, replacing the previous immediate-predecessor-only approach.
  • React keys for work entry rows in MessagesTimeline.tsx now prefer collapseKey over id, which may alter component reuse during updates.
  • Behavioral Change: work log entries now retain collapseKey, and tool.started for non-command items remains filtered out.

Macroscope summarized b042087.

- Stop truncating `detail` when ingesting provider runtime tool events
- carry item IDs and payload data through server ingestion
- collapse tool lifecycle rows by stable item IDs
- keep command start rows visible with clearer labels
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 6, 2026

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 0961bbd2-c5d8-4ae2-b88d-1f1d747ff214

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions github-actions bot added size:M 30-99 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list. labels Apr 6, 2026
Copy link
Copy Markdown
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit b042087. Configure here.

@macroscopeapp
Copy link
Copy Markdown
Contributor

macroscopeapp bot commented Apr 6, 2026

Approvability

Verdict: Needs human review

This PR modifies runtime behavior for command display (removes truncation, adds 'Running' state indication) with non-trivial changes to work log collapsing logic. An open review comment identifies a potential bug where lifecycle-dependent titles could prevent proper collapsing of started/completed entries when itemId is absent.

You can customize Macroscope's approvability policy. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M 30-99 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant