Repository navigation
Conversation
## ELI5 When two rapidly sent prompts become one transcript line, Native Chat should remove both temporary queued bubbles. It previously handled only prompts joined with no separator, so a retained space could leave both bubbles stuck below newer replies forever. ## What Changed - Match glued pending sends with or without one normalized whitespace separator at each send boundary. - Keep exact full-text matching so unrelated prefixes do not retire pending sends. - Added coverage for retained separators, mixed separator boundaries, repeated prompts, and partial-prefix rejection. ## Why The send path preserves the raw trailing space on the PTY, while pending-text normalization trims it. A rapid second send can therefore produce a transcript row such as tell me a joke continue, but the old matcher only tried tell me a jokecontinue. Since transcript matching is the retirement path for successful optimistic sends, both queued echoes remained pinned. ## Linked Issue Fixes stablyai#14262 ## Visual Proof N/A — this fixes renderer reconciliation state. The deterministic string-level regression reproduces the same transcript and pending-send state without requiring a timing-dependent live agent race. ## Testing - [x] I manually tested these changes locally - [x] Automated tests added/updated, or explained why not below Verified on macOS with Node 24.18.0: - pnpm lint — passed - pnpm typecheck — passed - pnpm test — passed - pnpm build — passed - focused pending reconciliation tests — 53 passed - focused oxlint and oxfmt checks — passed - git diff --check — passed The full suite used the isolated Orca contribution environment: OpenClaw CODEX variables unset, TMPDIR=/tmp, umask 0027, and ORCA_CROSS_VERSION_BASELINE_REF=v1.4.180. ## AI Disclosure OpenAI Codex GPT-5 was used to verify the issue against current main, implement the bounded matcher change, add regression and boundary tests, and review the diff. All commands above were run locally and the final diff was manually reviewed. ## Review - Security: no authentication, secret handling, command execution, or permission behavior changed. - Cross-platform: the matcher is platform-independent pure renderer string logic. - SSH/remote: reconciliation consumes normalized transcript text identically for local and remote sessions. - Backwards compatibility: separator-less glue and exact single-send occurrence matching retain their existing behavior. - Performance: pending sends are capped at eight. Candidate prefixes are pruned at every boundary and exact matching remains bounded by that cache. - Correctness boundaries: mixed separators and repeated prompts match; incomplete longer transcript prefixes do not. ## Checklist - [x] This PR is small and focused - [x] I explained what changed and why including ELI5 - [x] Before/after screenshots or videos attached for UI changes, or N/A with reason - [x] Self-reviewed for correctness, security, and performance - [x] Cross-platform, SSH/remote, and path/shortcut impact considered or N/A - [x] pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass or CI will cover; local preferred All four commands were executed locally and passed. ## Author - X / Twitter: N/A
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughThe pending text matcher now supports direct concatenation and single-space separators between pending sends. It tracks candidate combinations while validating transcript prefixes and returns a count only for exact matches. Regression tests cover whitespace-separated sends, mixed separators, repeated prompts, and transcript text that extends beyond the combined pending text. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
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. Comment |
|
Superseded by #14663, which preserves this fix and adds the send-boundary protection needed to avoid matching older transcript rows. Thanks for carrying this through and for the attribution. |
ELI5
When two rapidly sent prompts become one transcript line, Native Chat should remove both temporary queued bubbles. It previously handled only prompts joined with no separator, so a retained space could leave both bubbles stuck below newer replies forever.
What Changed
Why
The send path preserves the raw trailing space on the PTY, while pending-text normalization trims it. A rapid second send can therefore produce a transcript row such as tell me a joke continue, but the old matcher only tried tell me a jokecontinue. Since transcript matching is the retirement path for successful optimistic sends, both queued echoes remained pinned.
Prior Work
#14263 addressed the same separator-glued defect, but its author closed it after determining that the broader drift they were investigating had a separate
queued_commandcause. The closing comment explicitly left #14262 open as a standalone report. This PR carries that standalone fix forward with additional mixed-boundary, repeated-prompt, and prefix-rejection coverage.Linked Issue
Fixes #14262
Visual Proof
N/A — this fixes renderer reconciliation state. The deterministic string-level regression reproduces the same transcript and pending-send state without requiring a timing-dependent live agent race.
Testing
Verified on macOS with Node 24.18.0:
The full suite used the isolated Orca contribution environment: OpenClaw CODEX variables unset, TMPDIR=/tmp, umask 0027, and ORCA_CROSS_VERSION_BASELINE_REF=v1.4.180.
AI Disclosure
OpenAI Codex GPT-5 was used to verify the issue against current main, implement the bounded matcher change, add regression and boundary tests, and review the diff. All commands above were run locally and the final diff was manually reviewed.
Review
Checklist
All four commands were executed locally and passed.
Author