Skip to content

Fix terminal history, prompt routing, and state edge cases - #63

Merged
Raeedzz merged 3 commits into
mainfrom
Raeedzz/fix-scrollbacl
Jul 15, 2026
Merged

Fix terminal history, prompt routing, and state edge cases#63
Raeedzz merged 3 commits into
mainfrom
Raeedzz/fix-scrollbacl

Conversation

@Raeedzz

@Raeedzz Raeedzz commented Jul 15, 2026

Copy link
Copy Markdown
Owner

What changed

  • Restore the complete persisted terminal transcript instead of truncating loaded history to the newest 500 blocks.
  • Route password and token prompts directly to the PTY when terminal echo is disabled, including canonical no-echo prompts.
  • Distinguish new shell commands from stdin intended for a foreground prompt, and clear stale passthrough state after PTY exit.
  • Deduplicate projects by normalized path and ignore stale customization actions for projects that have already been removed.
  • Preserve balanced closing parentheses in detected URLs while trimming only punctuation that belongs to surrounding prose.
  • Sanitize generated branch prefixes to a conservative Git-safe character set.
  • Add regression coverage for terminal input-mode decisions, reducer behavior, URL matching, and branch-prefix generation.

Why

Several independent edge cases could lose visible terminal history, send sensitive prompt input through the wrong editor, leave a hidden terminal input active after process exit, or create inconsistent project and branch state. The fixes address the underlying state and terminal-mode decisions rather than masking their UI symptoms.

Impact

Users retain their full saved terminal history, password and token prompts behave correctly, project lists remain stable across equivalent paths and delayed actions, URLs open intact, and generated branch prefixes avoid unsafe punctuation.

Validation

  • Frontend test suite: 333 tests passed
  • Rust test suite: 323 tests passed
  • Production frontend build passed
  • git diff --check passed
  • Native Tauri smoke test passed, including switching the target worktree without runtime errors

Notes

cargo clippy -- -D warnings still reports existing style lints and vendored macOS deprecation warnings unrelated to this change.

Raeedzz added 3 commits July 15, 2026 12:11
- persistence: drop the 500-block load window; `load_blocks` now
  restores the entire transcript, relying on the renderer to
  virtualize deep history instead of truncating it on disk read.
- term/warp_term/frontend: `raw_input` now also fires when ECHO is
  cleared (not just ICANON), so password/token prompts that keep
  canonical line buffering still route straight to the PTY instead of
  the visible block editor.
- inputModeDecision: add `classifyPromptSubmission` to distinguish a
  new shell command from stdin for a still-running foreground prompt.
Add regression tests covering these state/reducer and lib fixes.
# Conflicts:
#	src-tauri/src/term.rs
#	src/terminal/BlockTerminal.tsx
@Raeedzz
Raeedzz marked this pull request as ready for review July 15, 2026 20:21
@Raeedzz
Raeedzz merged commit 285efc7 into main Jul 15, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant