fix: include short viewport output in recent reads - #3448
Conversation
|
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)
Included review availability: Your plan provides up to 10 included reviews per hour; 8 remain after this review. 📝 WalkthroughWalkthroughAdded the public Suggested reviewers: Merge Risk: ⚪ Minimal · up to This change makes short recent terminal reads include visible command output while preserving alternate-screen behavior. No actionable merge-blocking risk remains after normal checks and review. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 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 |
|
@coderabbitai review |
|
✅ Action performedReview finished.
|
Greptile SummaryThis PR adjusts primary-screen recent reads to end at the last textual content row or cursor row, preventing unused viewport rows from hiding short output.
Confidence Score: 5/5The PR appears safe to merge, with no concrete blocking or non-blocking defects identified. The cursor and screen coordinates are converted consistently into absolute grid rows, alternate-screen behavior is preserved, and the new regression tests cover the intended fresh-viewport behavior.
|
| Filename | Overview |
|---|---|
| src/ghostty/mod.rs | Adds a typed accessor for Ghostty's zero-indexed cursor row within the active area. |
| src/pane/terminal.rs | Corrects recent-read bounds on primary screens and adds regression coverage without introducing an actionable defect. |
Reviews (1): Last reviewed commit: "fix: include short viewport output in re..." | Re-trigger Greptile
7c814dd to
67c7c7c
Compare
Issue
A short command is visible in a fresh pane, but
pane readreturns no text fromrecentorrecent-unwrappedwhen the requested line count is smaller than the viewport.Problem
The recent range ended at the physical bottom of the terminal. Unused blank rows after the prompt could consume the entire line limit before trailing blanks were removed.
How did we fix it?
Herdr now ends primary-screen recent reads at the last content row or cursor row. A completely blank viewport and alternate screens keep their previous behavior. Wrapped and unwrapped reads use the same corrected range.
Verification
A focused test and the exact clean-session reproduction failed before the change. Both recent sources now return the short command before scrollback exists, and scrollback tail reads still work. Focused regression checks pass. Local
just checkpassed 3541 of 3542 tests; an unrelated live-handoff replacement-process test failed locally. PR CI passes on Linux, macOS, and Windows.refs #3444