Skip to content

Conversation

@daniel-lxs
Copy link
Member

@daniel-lxs daniel-lxs commented Jun 19, 2025

Description

This PR fixes an issue where reasoning blocks were being rendered multiple times instead of updating in place during streaming responses.

Problem

When the AI streams reasoning content, the ReasoningBlock component was rendering multiple instances instead of updating a single instance. This was caused by a race condition in the Task.ts file where updateClineMessage was being called without awaiting its completion.

Solution

Added await to all updateClineMessage calls in Task.ts to ensure that message updates complete before proceeding with the next update. This prevents the race condition that was causing duplicate rendering.

Changes

  • Added await to 4 updateClineMessage calls in src/core/task/Task.ts

Testing

The fix ensures that:

  • Reasoning blocks update in place during streaming
  • No duplicate reasoning blocks are created
  • Message updates are properly synchronized

Fixes the issue where reasoning blocks were rendered multiple times during streaming responses.


Important

Fixes race condition in Task.ts by adding await to updateClineMessage calls, preventing duplicate reasoning blocks during streaming responses.

  • Behavior:
    • Fixes race condition in Task.ts by adding await to updateClineMessage calls, ensuring message updates complete before proceeding.
    • Prevents duplicate reasoning blocks during streaming responses.
  • Changes:
    • Added await to 4 updateClineMessage calls in Task.ts.

This description was created by Ellipsis for 639cb78. You can customize this summary. It will automatically update as commits are pushed.

…ocks

- Add await to all updateClineMessage calls in Task.ts
- Fixes race condition where reasoning blocks were rendered multiple times
- Ensures message updates complete before proceeding with next update
@daniel-lxs daniel-lxs requested review from cte, jr and mrubens as code owners June 19, 2025 18:03
@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. bug Something isn't working labels Jun 19, 2025
@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Jun 19, 2025
@daniel-lxs daniel-lxs moved this from Triage to PR [Draft / In Progress] in Roo Code Roadmap Jun 19, 2025
@hannesrudolph hannesrudolph added PR - Draft / In Progress and removed Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. labels Jun 19, 2025
@daniel-lxs
Copy link
Member Author

Closing for now since the issue wasn't reproducible.

@daniel-lxs daniel-lxs closed this Jun 24, 2025
@github-project-automation github-project-automation bot moved this from PR [Draft / In Progress] to Done in Roo Code Roadmap Jun 24, 2025
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Jun 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working PR - Draft / In Progress size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants