fix(markdown): rebuild table when streaming ends#696
Merged
kommander merged 4 commits intoanomalyco:mainfrom Feb 17, 2026
Merged
fix(markdown): rebuild table when streaming ends#696kommander merged 4 commits intoanomalyco:mainfrom
kommander merged 4 commits intoanomalyco:mainfrom
Conversation
This was referenced Feb 16, 2026
When streaming transitions from true to false, updateBlocks() skips table updates because the token raw hasn't changed. However, the table renderable was created with N-1 rows during streaming (last row is skipped as potentially incomplete). This causes the last table row to be permanently missing after streaming completes. Use clearCache() instead of updateBlocks() when streaming ends to force a full rebuild, ensuring all table rows are rendered.
959f022 to
e22c07c
Compare
@opentui/core
@opentui/react
@opentui/solid
@opentui/core-darwin-arm64
@opentui/core-darwin-x64
@opentui/core-linux-arm64
@opentui/core-linux-x64
@opentui/core-win32-arm64
@opentui/core-win32-x64
commit: |
Streaming mode affects table row visibility even when token raw is unchanged. Force cache invalidation on mode changes and add bidirectional regression coverage for streaming toggles.
Streaming mode changes table row visibility even when token raw is unchanged. Rebuild cached markdown blocks on streaming mode transitions.
simonklee
approved these changes
Feb 16, 2026
Member
simonklee
left a comment
There was a problem hiding this comment.
Thanks for the report.
Added a couple regression and made it so mode-changes simply clear the cache so it's symmetrical (streaming -> non-streaming and visa versa)
Contributor
|
It would be better to fix the bug without clearing the full cache to prevent stutters for big markdown content. Can you try telling your agent to try that @mocksoul? |
Contributor
|
Also in opencode streaming is always set to true right now I think. https://github.com/anomalyco/opencode/blob/bb30e06855fb979b5fd765796a6b7428b9177b91/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx#L1380 |
Member
|
See commits, he already did that. But I changed it to the current version. See regressions.
…On Mon, Feb 16, 2026, at 17:02, Tommy D. Rossi wrote:
*remorses* left a comment (anomalyco/opentui#696) <#696 (comment)>
It would be better to fix the bug without clearing the full cache to prevent stutters for big markdown content. Can you try telling your agent to try that @mocksoul <https://github.com/mocksoul>?
—
Reply to this email directly, view it on GitHub <#696 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AAAM4O7XRVMML62NHVUJRCL4MHSZ7AVCNFSM6AAAAACVJMIFE6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTSMBZGI3TONBSHE>.
You are receiving this because your review was requested.Message ID: ***@***.***>
|
Contributor
|
Ok I am fine with this. Later we can add a method to only rebuild tables to improve performance (I cannot push to PRs) |
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.
Summary
updateBlocks()skips table rebuild when token raw hasn't changed, but the table renderable was created with N-1 rows during streaming (rows.slice(0, -1))clearCache()instead ofupdateBlocks()onstreaming: true→falsetransition to force full rebuild