Skip to content
This repository was archived by the owner on Sep 28, 2026. It is now read-only.

Name a pane's live identity, not an earlier signed-out one - #15

Merged
m4ttheweric merged 1 commit into
mainfrom
status-live-row
Sep 27, 2026
Merged

m4ttheweric merged 1 commit into
mainfrom
status-live-row

Conversation

@m4ttheweric

@m4ttheweric m4ttheweric commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

After a session in a pane is cleared and a new one signs in, status and the launcher header named the earlier, signed-out identity. rt now gives every chat session its own identity, so the old signed-out row can still name the pane beside the live one, and the lookup took whichever row came first in the buddy list.

What changed

  • rt::buddy_in_pane picks a pane's buddy: a signed-in row first, then the most recent signedInAt
  • Buddy reads signedInAt from rt chat buddies
  • status, the launcher header and the launcher's room lookup all go through it

Verification

A pane holding a signed-out ida and a live tony.ncu0: the installed build answered ida, offline; this branch answers tony, signed in. 176 tests, fmt, clippy -D warnings and repo-purity pass.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Bug Fixes
    • Pane-specific status, details, and actions now use the most relevant matching buddy identity. Active identities are preferred; when all matching identities are offline, the latest sign-in is selected.
    • This avoids displaying or acting on an outdated identity when multiple buddy identities are associated with the same pane. If no identity matches a pane, no buddy is selected.

Every chat session is its own identity now, so an earlier session's signed-out row can still name the pane beside the live one. Pick a signed-in row first, then the most recent sign-in.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Sep 27, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: 7ffde751-f0ee-468d-8c38-9b99e7200527

📥 Commits

Reviewing files that changed from the base of the PR and between fa6bffc and 1801b9f.

📒 Files selected for processing (4)
  • src/cmd/launcher.rs
  • src/cmd/peek.rs
  • src/cmd/quick_send.rs
  • src/rt.rs

Included review availability: This review used your included allowance. 0 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour.


📝 Walkthrough

Walkthrough

Buddy records now include an optional sign-in timestamp. Pane lookups prefer non-offline buddies, then the latest sign-in timestamp. Launcher commands use this lookup, and tests and fixtures cover the updated behavior and data shape.

Changes

Pane buddy selection

Layer / File(s) Summary
Buddy data and selection
src/rt.rs
Buddy gains an optional signed_in_at field deserialized from signedInAt. buddy_in_pane selects a matching buddy by status and sign-in timestamp, or returns None when no buddy matches. A test covers offline selection by timestamp and an unknown pane.
Launcher lookup integration
src/cmd/launcher.rs, src/cmd/peek.rs, src/cmd/quick_send.rs
origin_status, status_json, and run use buddy_in_pane. Tests check live and latest-offline identity selection. Buddy test fixtures initialize signed_in_at to None.

Priority: ➖ Normal

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Merge Risk: ⚪ Minimal · up to 1801b

No confirmed issue prevents merging the pane identity change.

Security Architecture Review

Security architecture risk: 🔵 Low · up to 1801b

The launcher now prefers a live identity for the same pane instead of an earlier signed-out one. The inspected paths keep room lookup tied to that selected session; no new authorization path was identified.

Retained concerns
No architecture-level concerns identified.

Security review details

Security Blast Radius

  • inferred — The observed change in exposure is which same-pane identity is displayed and which of its sessions supplies room metadata; the selector has no cross-pane fallback.

Trust Boundaries and Controls

  • observed — The launcher relies on pane, status, and session fields returned by rt chat buddies. Its local controls require an exact pane match and a non-offline row with a session ID before fetching rooms.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: selecting a pane's live identity instead of an earlier signed-out identity.
Docstring Coverage ✅ Passed Docstring coverage is 82.35% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 17 functions across 4 files.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Comment @coderabbitai help to get the list of available commands.

@m4ttheweric
m4ttheweric merged commit 532ae47 into main Sep 27, 2026
2 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant