Repository navigation
Commit f841782
committed
Fix TUI text truncation during streaming (anomalyco#5006)
Replace reconcile() with produce() for TextPart updates during streaming to prevent race conditions where text-end events overwrite accumulated text from text-delta events.
- Use produce() for incremental text updates instead of full object replacement
- Preserve streaming context and prevent mid-sentence truncation
- Maintain backward compatibility for non-text parts with fallback to reconcile()
- Fix race condition in sync.tsx that caused intermittent truncation1 parent 9188bc5 commit f841782
1 file changed
Lines changed: 26 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
218 | 244 | | |
219 | 245 | | |
220 | 246 | | |
| |||
0 commit comments