Skip to content

fix(last): say when the folder fallback picked the transcript - #64

Merged
backnotprop merged 1 commit into
mainfrom
fix/last-fallback-visibility
Sep 7, 2026
Merged

fix(last): say when the folder fallback picked the transcript#64
backnotprop merged 1 commit into
mainfrom
fix/last-fallback-visibility

Conversation

@backnotprop

Copy link
Copy Markdown
Contributor

When last cannot identify a transcript exactly, it now says so in the status line instead of silently showing the folder's newest transcript.

Reproduced first

Two Claude transcripts for one project folder, different mtimes, distinct replies, no session id available. Before this change plannotator-tui last --host claude --print printed the newer session's reply with no note, and inside Herdr without a session id the UI was byte-identical to the exact-session path. The same run with --session-id for the older session printed the other reply.

What changed

  • last/fallback.rs: a Discovery value per host, Exact when a path, session id, thread id, or the process's own open rollout named the transcript, Folder for cwd/mtime discovery, Session for Codex's newest-rollout guess.
  • last/locate.rs: Located.discovery; explicit paths and ids are always Exact.
  • last/mod.rs: discovery_note builds the hint. Inside Herdr: "no session id from Herdr, showing the newest transcript for this folder". Outside Herdr: "showing the newest transcript for this folder". Exact produces no note. --print output is unchanged on stdout and stderr.
  • app/draw.rs: the status now leads the footer. The left footer area is narrow, so an appended status was cut off entirely; the status is transient and clears on the next key.
  • README: the Claude integration registers on SessionStart, so only sessions started after herdr integration install claude report an id, and last says when it falls back.

Checks

cargo fmt --all --check, cargo clippy --locked --workspace --all-targets -- -D warnings, cargo test --locked --workspace all pass. Unit tests cover the note wording, the Exact case, a command-line transcript never being reported as a guess, and the status leading the footer on a narrow pane.

refs #57

@backnotprop
backnotprop added this pull request to the merge queue Sep 7, 2026
Merged via the queue into main with commit 2dc4deb Sep 7, 2026
2 checks passed
@backnotprop
backnotprop deleted the fix/last-fallback-visibility branch September 7, 2026 17:35
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.

2 participants