Repository navigation
Fix paired remote terminal parse backpressure - #9683
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughAdds shared deferred terminal-delivery credit tracking with nested restoration and idempotent settlement. PTY acknowledgment handling, remote terminal output delivery, and reattach live-data queues now use the shared mechanism, releasing credits for consumed, discarded, skipped, and disposed data. Adds inspection helpers for processed PTY character totals and tests for nested credits, replay deferral, disposal, and remote output backpressure. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
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 |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: e8293b6a-fa0b-48f8-a403-4e20d5348cc8
📒 Files selected for processing (7)
src/renderer/src/components/terminal-pane/pty-connection.test.tssrc/renderer/src/components/terminal-pane/pty-connection.tssrc/renderer/src/components/terminal-pane/terminal-pty-ack-gate.tssrc/renderer/src/lib/pane-manager/terminal-delivery-credit.test.tssrc/renderer/src/lib/pane-manager/terminal-delivery-credit.tssrc/renderer/src/runtime/remote-runtime-terminal-multiplexer.tssrc/renderer/src/runtime/remote-runtime-terminal-parse-backpressure.test.ts
* fix(terminal): defer remote output ACKs until parse * test(terminal): document synchronous credit claims --------- Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
Summary
The affected live Windows-hosted terminal remained responsive through the canonical stream while the paired Mac renderer diverged. The root cause was client-side receipt-time ACK, not the Windows PTY or the AttachConsole work in #9638.
Screenshots
No visual change. This is a terminal stream convergence and backpressure fix.
Testing
pnpm lint— ordinary oxlint passed; the repository-wide switch-exhaustiveness phase is blocked by two unrelated existing errors inskill-freshness-group.tsxanddaemon-server.ts.pnpm typecheckpnpm test— full repository suite not run; focused suites below passed.pnpm build— the Electron E2E global setup completedelectron-vite build --mode e2e; the standalone production build was not run.Focused evidence:
git diff --checkpassed.AI Review Report
Ran two adversarial review/fix passes anchored to
origin/main, with the internal elegance, performance, and terminal-session-reliability contracts.The review checked:
ClaimViewportremains the desktop driver policy with legacyResizefallback.Findings addressed:
finally. Disposal now settles those credits explicitly.terminal-delivery-credit.ts, leaving the local IPC gate as a thin adapter.The second review found no remaining in-scope issues.
Security Audit
Notes