Skip to content

Conversation

@cte
Copy link
Collaborator

@cte cte commented Mar 6, 2025

Context

One last terminal bug fix for behavior that bugs me.

If you execute a command that either doesn't produce output right away or doesn't flush its output to be visible to VSCode then the task hangs indefinitely. It's preferable to present the "Proceed While Running" action so that you can continue to the task while the command is running in the background.

This issue is easy to reproduce with the following prompt:
"Run the command yes."

Implementation

Screenshots

before after

How to Test

Get in Touch


Important

Add handling for outputless terminal commands by emitting a stream_stalled event when no output is detected within a timeout, allowing tasks to proceed.

  • Behavior:
    • Introduces stream_stalled event in TerminalProcess to detect when no output is received within a specified timeout.
    • In Cline.ts, listens for stream_stalled to allow user to proceed while command runs in background.
  • Implementation:
    • Adds stallTimeout parameter to TerminalProcess constructor, defaulting to 5000ms.
    • Clears stall timer in flushLine() when output is received.
  • Testing:
    • Adds tests in TerminalProcess.test.ts for stream_stalled event emission and stall timer clearing behavior.

This description was created by Ellipsis for 710284c. It will automatically update as commits are pushed.

@changeset-bot
Copy link

changeset-bot bot commented Mar 6, 2025

🦋 Changeset detected

Latest commit: 710284c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
roo-cline Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. bug Something isn't working labels Mar 6, 2025
@cte cte force-pushed the cte/handle-outputless-commands branch from d00554e to 710284c Compare March 6, 2025 05:28
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Mar 6, 2025
@cte cte merged commit aa0e277 into main Mar 6, 2025
11 checks passed
@cte cte deleted the cte/handle-outputless-commands branch March 6, 2025 05:32
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Mar 6, 2025
cte pushed a commit that referenced this pull request Mar 11, 2025
This reverts commit 710284c which has
been superseded by PR #1365.

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

Labels

bug Something isn't working lgtm This PR has been approved by a maintainer size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants