Skip to content

Shell UX, Robustness & Reliability Improvements#22

Closed
Shahinyanm wants to merge 7 commits into
masterfrom
feature/shell-ux-and-robustness
Closed

Shell UX, Robustness & Reliability Improvements#22
Shahinyanm wants to merge 7 commits into
masterfrom
feature/shell-ux-and-robustness

Conversation

@Shahinyanm

Copy link
Copy Markdown
Member

This PR implements the planned features and bug fixes under the shell UX and robustness scope:

  • SQLite WAL Mode (aimux-ylh): Configured SQLite database with WAL mode on post-sync for shared Codex database instances to prevent database lockups.
  • Project-to-Profile bindings (aimux-b0i): Configured automatic selection of active profiles based on the directory path of the active project.
  • Self-Healing symlinks (aimux-lpy): Automatically detects and prunes obsolete and orphaned symlinks during version changes.
  • Prompt Indicator (aimux-clc): Implemented CLI prompt command for shell and Starship custom profile indicators.
  • Logs View and Grep (aimux-zaj): Added command to tail and grep transcripts of active and background sessions.
  • Live Session Attachment (aimux-1uu): Added support in TUI and CLI to join a live background session using native claude attach instead of forcing a fork copy.
  • Automatic Rate-Limit Failover (aimux-e1i): Automatically and transparently relocates active sessions to another available subscription profile when rate limits are hit.

@Shahinyanm

Copy link
Copy Markdown
Member Author

Superseded by #23, which shipped as v0.22.0.

Four of the seven features here were sound and are now on master: self-healing symlinks, project→profile bindings, prompt-indicator, and logs. They were rebuilt on current master, fixed where review found problems, given regression tests, and verified against real profiles.

Three were left out, with reasons:

  • SQLite WAL pragma — a no-op. Since 0.21.1 the session-index DB is a symlink to the source DB that codex already keeps in WAL. It also shelled out to an undeclared sqlite3 binary, and because spawnSync returns {error} rather than throwing (and the result was never checked), a missing binary was indistinguishable from success.
  • claude attach — the subcommand does not exist; verified against claude 2.1.217. The TUI made it the default action for Enter on a live background session, so the most common interaction returned exit code 1.
  • Rate-limit auto-failover — it identified a rate limit by substring-matching the model's own reply for "429" / "rate limit" / "overloaded", with no loop bound and no CLI filter on the failover target. A conversation about HTTP 429 handling would bounce the session between subscriptions indefinitely, each hop a billed turn. This needs a redesign against the real stream protocol rather than a patch.

Also worth recording: this branch could not be built. src/core/index.ts exported ./logs.js but logs.ts was never committed — it existed only as an untracked local file, which is why the test run looked green. Those files are included in #23.

Fixes applied to the features that did ship:

  • codex's adapter-managed plugins link was matched by the prune loop but is outside the codex share allowlist, so every sync unlinked and recreated it and doctor reported it as both a conflict and valid. Adapter-managed links are now exempt from both sweeps.
  • Binding patterns were resolved against process.cwd(), so the same config matched different directories depending on where aimux ran. They now anchor to $HOME.
  • prompt-indicator used String.replace, substituting only the first %s and interpreting $& in a profile name. Now replaceAll with a literal replacer.
  • logs was missing from all three shells' completions, and emitted ANSI unconditionally. Fixed both.
  • A binding silently removed the interactive picker from aimux use; added --pick to force it.

Closing in favour of #23 — no work is lost, and the three excluded features are worth revisiting individually.

@Shahinyanm Shahinyanm closed this Jul 22, 2026
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