feat(tui): add session picker for /resume + auto session titles#80
Merged
yishuiliunian merged 2 commits intomainfrom Apr 5, 2026
Merged
feat(tui): add session picker for /resume + auto session titles#80yishuiliunian merged 2 commits intomainfrom
yishuiliunian merged 2 commits intomainfrom
Conversation
…te session titles (#79) Replace the text-based session list with a TUI picker subpage when /resume is invoked without arguments. Filter out sub-agent sessions using a global exclusion set so only root sessions are shown. Auto-set session title from the first user message to make the picker useful. Refactor picker key handling: extract generic Esc/Up/Down/Char/Backspace into handle_generic_picker_key to eliminate duplication between model and session pickers. Split rewind picker and session query methods into separate files to stay within the 200-line limit.
yishuiliunian
added a commit
that referenced
this pull request
Apr 5, 2026
…oval for path operations (#80) Sandbox path violations (writes outside cwd, deny_write_globs, deny_read_globs) previously returned hard errors that blocked operations even when the user had already approved the tool. This prevented Loopal from performing legitimate ops tasks like editing /etc/nginx/nginx.conf. Now these "soft denies" flow through the existing permission system: - Bypass mode: auto-allows without prompting - Supervised mode: asks the user with sandbox context - Auto mode: routes to the LLM classifier Hard denies remain for ReadOnly mode and path resolution failures (.. traversal, symlink escape). Key changes: - PathDecision simplified to three-state: Allow / Deny / RequiresApproval - Backend gains approve_path() + check_sandbox_path() for session-scoped approval caching - Runtime pre-checks extract paths from tool input before execution, elevating effective permission to Dangerous when sandbox approval is needed - Execution-time fallback in resolve_checked() handles opaque tools (Bash/Glob/MCP) - 35 new tests across backend, sandbox, and runtime layers
yishuiliunian
added a commit
that referenced
this pull request
Apr 5, 2026
…oval for path operations (#80) (#83) Sandbox path violations (writes outside cwd, deny_write_globs, deny_read_globs) previously returned hard errors that blocked operations even when the user had already approved the tool. This prevented Loopal from performing legitimate ops tasks like editing /etc/nginx/nginx.conf. Now these "soft denies" flow through the existing permission system: - Bypass mode: auto-allows without prompting - Supervised mode: asks the user with sandbox context - Auto mode: routes to the LLM classifier Hard denies remain for ReadOnly mode and path resolution failures (.. traversal, symlink escape). Key changes: - PathDecision simplified to three-state: Allow / Deny / RequiresApproval - Backend gains approve_path() + check_sandbox_path() for session-scoped approval caching - Runtime pre-checks extract paths from tool input before execution, elevating effective permission to Dangerous when sandbox approval is needed - Execution-time fallback in resolve_checked() handles opaque tools (Bash/Glob/MCP) - 35 new tests across backend, sandbox, and runtime layers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/resumewithout args now opens an interactive TUI picker instead of printing a text listChanges
list_root_sessions_for_cwd()scans all sessions to exclude sub-agent IDs; query methods split tosession_query.rsSessionManagerexposes new query;ingest_messageauto-sets title on first non-ephemeral messageSubPage::SessionPicker+SubPageResult::SessionSelected; generic picker key handler extracted (handle_generic_picker_key); rewind picker split tosub_page_rewind.rsTest plan
bazel build //...passesbazel build //... --config=clippyzero warningsbazel test //crates/loopal-storage:loopal-storage_testpassesbazel test //crates/loopal-runtime:loopal-runtime_testpasses