Skip to content

feat: default-tmux-sessions#88

Draft
satyaborg wants to merge 3 commits into
mainfrom
feat/default-tmux-sessions
Draft

feat: default-tmux-sessions#88
satyaborg wants to merge 3 commits into
mainfrom
feat/default-tmux-sessions

Conversation

@satyaborg

Copy link
Copy Markdown
Owner

Default tmux Sessions

Problem

An interactive devloop currently owns the invoking terminal for its entire coder and reviewer loop. Closing that terminal interrupts the run, detaching the terminal is not possible, and several concurrent devloops are difficult to identify or revisit. This hurts when a long run must continue unattended or when multiple specs are running at once across repositories.

Outcome

devloop <spec> and devloop continue create one unique, human-readable tmux session per interactive run and move the user into it. A user can detach with Ctrl-b d, close the original terminal, list the named sessions, and reattach later while the same devloop keeps running. Launching from an existing tmux client switches to the new session instead of nesting tmux. --no-tmux and non-interactive execution retain the current foreground behavior, while installation and doctor flows treat tmux as a required dependency.

Acceptance Criteria

AC1: An eligible devloop <spec> invocation outside tmux creates a new named tmux session, attaches the current terminal, and starts the loop only inside that session.
AC2: An eligible run invoked inside tmux creates a separate detached session and switches the existing client to it without nesting tmux.
AC3: A run's base session name is the normalized devloop-<repo>-<spec-slug> form, while a continued run uses the track filename as its slug source.
AC4: An occupied base session name produces the first available numeric suffix starting at -2 without attaching to the occupied session.
AC5: Detaching or disconnecting the client leaves the launched devloop running and discoverable under its allocated session name.
AC6: --no-tmux is accepted by explicit run and continue commands and preserves their existing foreground behavior without invoking tmux.
AC7: A run with non-TTY stdin or stdout preserves the existing foreground behavior without invoking tmux.
AC8: A menu-selected run creates one session after selection and passes its resolved run choices to the child without repeating the spec or PR prompts.
AC9: Explicit and menu-selected continue workflows create one new session after resolving the track and resume through the existing run_from_track behavior.
AC10: A missing tmux command makes an eligible launch fail before loop execution with actionable installation guidance.
AC11: Invalid spec or track input returns the existing validation error before any tmux session is created.
AC12: A failed new-session call exits nonzero and never falls back to a second foreground execution.
AC13: The tmux child receives the caller's working directory, current PATH, original arguments as distinct argv values, and exactly one injected --no-tmux recursion guard.
AC14: devloop spec, nightshift, status, clean, reports, doctor, and update do not enter the automatic tmux boundary, and nightshift child loops explicitly pass --no-tmux.
AC15: Both installers treat tmux as a required Homebrew formula, post-install verification checks it, and devloop doctor fails required-dependency readiness when it is absent.
AC16: Plain help, TUI help, README.md, and CONTRIBUTING.md document the tmux default, --no-tmux, required dependency, detach command, and reattach command where appropriate.
AC17: bash scripts/devloop_test.sh passes with every new project function covered and no real tmux side effect.

Review Trail

Review rounds and the final report are posted as PR comments below.


Generated by devloop.sh

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 14, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
devloop f54e584 Commit Preview URL

Branch Preview URL
Jul 15 2026, 02:25 AM

@satyaborg

Copy link
Copy Markdown
Owner Author

Devloop Review Round 1

  • Verdict: ACCEPT

Review 1

Verdict: ACCEPT

Acceptance matrix

Obligation Status Implementation evidence Test evidence
AC1 PASS run_command validates before delegating once to tmux_launch_session (devloop:3016-3024); the outside branch uses attached new-session with the named child (devloop:378-381). The fake-tmux outside launch asserts new-session, -s, no -d, and no foreground execution (scripts/devloop_test.sh:541-562,609-628).
AC2 PASS A nonempty TMUX selects detached new-session -d followed by switch-client, with no nested attach (devloop:364-375). The inside-tmux fixture asserts detached creation, client switching, continue argv, and one recursion guard (scripts/devloop_test.sh:564-574).
AC3 PASS tmux_session_base_name normalizes the repository basename and the supplied spec or track filename (devloop:302-319); continue callers supply the validated track (devloop:1823-1829,1989-2001). Normalization, fallback names, run names, and both explicit and menu continue track arguments are asserted (scripts/devloop_test.sh:495-498,684-696,750-763).
AC4 PASS tmux_allocate_session_name checks exact names and increments from -2 until free (devloop:325-336); launch uses only new-session, never attach-or-create (devloop:364-381). Occupied base and -2 allocate -3; the launcher assertion rejects -A (scripts/devloop_test.sh:531-535,558-560).
AC5 PASS The launcher starts the devloop child as the tmux session command and adds no cleanup or keepalive process (devloop:351-381). The fake launcher verifies a named session and direct child command, while help and README checks verify list, detach, and reattach guidance (scripts/devloop_test.sh:541-562,85-91,116-119).
AC6 PASS run_command and continue_command parse --no-tmux, skip the boundary, and call their existing foreground owners (devloop:1954-2004,2939-3031). Explicit run and continue tests force interactive eligibility and assert zero launcher calls plus foreground delegation (scripts/devloop_test.sh:630-643,698-707).
AC7 PASS devloop_tmux_interactive requires TTY stdin and stdout; otherwise run_command reaches the unchanged foreground path (devloop:298-300,3016-3031). Separate non-TTY stdin and stdout checks reject eligibility, and a false predicate test asserts foreground run with no tmux launch (scripts/devloop_test.sh:499-500,645-657).
AC8 PASS interactive_run_setup resolves PR mode first and serializes TUI, report, strictness, worktree, PR, shell, agents, timeout, spec, and max into one child argv (devloop:1722-1762). The menu fixture asserts one PR prompt, one launch, resolved TUI, agent, timeout, PR, and shell values, and no foreground loop (scripts/devloop_test.sh:720-748).
AC9 PASS Explicit and menu continue validate the track before one launch; the guarded child re-enters continue_command, which delegates to canonical run_from_track (devloop:1806-1831,1953-2004,2843-2878). Explicit and menu-selected continue each assert one boundary call with the resolved track; foreground continue coverage exercises run_from_track (scripts/devloop_test.sh:684-707,750-763,2930-2955,3046-3050).
AC10 PASS tmux_launch_session checks command availability before name allocation or child creation and returns actionable installation guidance (devloop:338-349). The missing-command fixture asserts nonzero status and installer/install guidance (scripts/devloop_test.sh:598-605).
AC11 PASS Runs call validate_spec_for_tmux, and continues call validate_track_for_run, before the launcher (devloop:1748-1762,1823-1829,1989-2004,3016-3024). Missing spec and track cases assert the existing error and an empty launcher log (scripts/devloop_test.sh:672-682,709-718).
AC12 PASS Both new-session branches return nonzero immediately on failure and contain no foreground fallback (devloop:364-381). The fake new-session failure is propagated, does not switch clients, and the run-boundary failure test proves no foreground retry (scripts/devloop_test.sh:576-584,659-670).
AC13 PASS The launcher passes -c "$PWD", an absolute env, PATH=$PATH, the runtime, and array-expanded child arguments, injecting one guard (devloop:338-378). The fake-tmux log asserts cwd, PATH, runtime, spaces, metacharacters, and exactly one --no-tmux (scripts/devloop_test.sh:537-562,564-574).
AC14 PASS Only run and continue entry functions call the launcher; utility dispatch remains direct, and nightshift explicitly adds --no-tmux (devloop:86-165,1722-1768,1806-1831,1953-2004,2331-2342,2921-3031). Existing main-dispatch tests exercise menu, spec, nightshift, update, status, clean, reports, and doctor; nightshift argv explicitly includes --no-tmux (scripts/devloop_test.sh:1542-1572,1349,2028-2155,2542-2615,3044-3052).
AC15 PASS Both installers include tmux in discovery and post-install verification, and doctor includes it in required readiness (scripts/install.sh:49-101, scripts/install.remote.sh:188-224,271-314,405-438, scripts/skill_helpers.sh:343-367). Local and remote bootstrap fixtures assert tmux installation; doctor passes with tmux and fails without it (scripts/devloop_test.sh:1915-1916,2017-2206,2330-2354,2542-2615).
AC16 PASS Plain help, TUI help, README, and CONTRIBUTING document the default, required dependency, override, and applicable detach/reattach workflow (devloop:183-228,231-268, README.md:27-53, CONTRIBUTING.md:11-14). Help, TUI, README, and CONTRIBUTING string assertions cover tmux, --no-tmux, Ctrl-b d, and tmux attach -t (scripts/devloop_test.sh:70-91,113-123,451-468).
AC17 PASS New behavior is isolated in sourceable functions and tmux execution is injectable through PATH and function overrides. bash scripts/devloop_test.sh passed on review, ending with ok - 100% project function coverage; the tmux block uses only a fake executable (scripts/devloop_test.sh:502-529,3354).
F1 PASS Missing tmux returns before building or executing the child (devloop:338-349). Missing-tmux and launch-failure tests assert nonzero status, guidance, and no foreground retry (scripts/devloop_test.sh:598-605,659-670).
F2 PASS Exact-name allocation chooses the first free suffix; no code path uses new-session -A (devloop:325-381). The collision fixture allocates -3 after base and -2, and the launch log asserts absence of -A (scripts/devloop_test.sh:531-535,558-560).
F3 PASS Spec and track validators run before all eligible tmux calls (devloop:1748-1762,1823-1829,1989-2004,3016-3024). Invalid spec and track tests assert validation output and no launcher call (scripts/devloop_test.sh:672-682,709-718).
F4 PASS Failed creation returns immediately from either inside or outside branch, with no retry (devloop:364-381). The injected creation failure returns nonzero, reports the allocated session, skips switching, and the caller test rejects foreground retry (scripts/devloop_test.sh:576-584,659-670).
F5 PASS Switch failure reports the allocated name and manual switch and attach commands, then returns without killing or relaunching (devloop:369-374). The switch-failure fixture asserts all recovery guidance and exactly one new-session (scripts/devloop_test.sh:586-596).
F6 PASS Noninteractive eligibility fails unless both standard streams are TTYs, leaving foreground ownership unchanged (devloop:298-300,3016-3031). Non-TTY stdin, non-TTY stdout, and foreground delegation are covered (scripts/devloop_test.sh:499-500,645-657).
F7 PASS Both parsers consume --no-tmux as control state and exclude it from normal run or track semantics (devloop:1953-2004,2921-3031). Interactive-forced run and continue tests assert no launcher invocation and equivalent foreground arguments (scripts/devloop_test.sh:630-643,698-707).
F8 PASS Devloop launches as the tmux session command and performs no detach cleanup, so tmux owns persistence (devloop:364-381). The named-session argv test plus help and README detach/reattach assertions verify the intended tmux lifecycle contract (scripts/devloop_test.sh:537-562,85-91,116-119).
F9 PASS The parent injects --no-tmux into run or continue child argv, and both child parsers bypass wrapping when it is present (devloop:351-354,1953-2004,2975-3025). Outside and inside launcher logs each contain exactly one guard; separate guarded run and continue tests prove re-entry bypass (scripts/devloop_test.sh:561,574,630-643,698-707).
F10 PASS Child arguments are Bash array elements passed directly after tmux --, without eval or sh -c (devloop:343-378). Arguments containing spaces and shell metacharacters remain distinct in the fake log and do not create the marker file (scripts/devloop_test.sh:540-562).
F11 PASS An absolute env executable sets the caller's current PATH for the direct child command (devloop:357-378). The fake log asserts the exact current PATH assignment and resolved runtime argv (scripts/devloop_test.sh:552-556).
F12 PASS The tmux command ends at the devloop child argv and adds no shell, prompt, sleep, or keepalive (devloop:351-381). The launcher test asserts no shell wrapper; the direct argv layout contains only env, PATH, runtime, guard, and original arguments (scripts/devloop_test.sh:548-562).
F13 PASS nightshift_run_spec always invokes child loops with --plain --no-tmux --no-shell (devloop:2331-2342). Nightshift orchestration asserts all five child invocations include the headless --no-tmux flag set (scripts/devloop_test.sh:1347-1351).
I1 PASS Each eligible caller returns immediately after one tmux_launch_session; that helper issues one new-session for the allocated name (devloop:1748-1762,1823-1829,1989-2004,3016-3024,364-381). Explicit and menu boundaries assert one launch with no foreground loop; switch failure separately asserts one creation (scripts/devloop_test.sh:609-628,684-696,720-764,595).
I2 PASS Allocation never mutates occupied sessions, and launcher operations are limited to listing, fresh creation, and client switching (devloop:325-381). Collision and argv tests prove exact lookup, numeric allocation, and absence of -A; no fake operation attaches to, replaces, or kills an existing session (scripts/devloop_test.sh:531-560).
I3 PASS Automatic wrapping is called only from explicit/menu run and continue; nightshift opts out and utilities keep their prior dispatch (devloop:86-165,1722-1768,1806-1831,1953-2004,2331-2342,2921-3031). Main dispatch coverage plus the nightshift argv assertion exercise the excluded workflows without a tmux boundary (scripts/devloop_test.sh:1349,1542-1572,2028-2155,2542-2615,3044-3052).
I4 PASS The child guard returns execution to the existing run_devloop and run_from_track owners without moving loop, worktree, reporting, or exit logic into tmux helpers (devloop:2843-2878,3027-3031). Guarded foreground run/continue tests and the existing end-to-end loop/continue suite pass (scripts/devloop_test.sh:630-657,698-707,2867-2955,3014-3055).
I5 PASS User-controlled values stay in arrays and are expanded as "${child[@]}"; no assembled shell command is used (devloop:343-378). Space and metacharacter cases remain separate fake-tmux argv entries and are not evaluated (scripts/devloop_test.sh:540-562).
I6 PASS Tmux calls are isolated behind a PATH-resolved command suitable for a fixture. The suite prepends its fake tmux before launcher tests, restores PATH afterward, and the full suite passes without a real-session operation (scripts/devloop_test.sh:502-529,766-768).

Engineering quality matrix

Area Status Evidence
Correctness PASS Validation precedes launch, inside and outside tmux paths are distinct, failures do not fall back, and the full regression suite passes.
Test quality PASS Tests cover naming, collision allocation, direct argv, recursion guards, both tmux contexts, failure recovery, explicit/menu run and continue, installers, doctor, help, documentation, and retain 100% project-function coverage.
Maintainability PASS Tmux behavior is concentrated in small helpers, while entry points only validate, serialize resolved choices, and delegate.
Architecture boundaries PASS Existing run_devloop, run_from_track, menu selection, nightshift, installer, and doctor ownership remains intact across the new process boundary.
Simplicity PASS The solution uses one public recursion flag and direct tmux commands without polling, PID state, generated scripts, cleanup orchestration, or compatibility layers.
Security PASS Paths and user arguments remain distinct argv entries, session names are normalized, and no shell interpolation, eval, or sh -c is introduced.
Operational safety PASS Fresh names avoid session reuse, creation and switch failures are recoverable, existing sessions are never killed, and tests cannot reach a real tmux server through the fixture path.

Review flags

  • Silent decision: absent - Session lifetime, interactive eligibility, naming sources, prompt timing, collision races, and direct argv choices are recorded in the spec and track.
  • Scope drift: absent - Every changed runtime, installer, doctor, documentation, and test file is named by the implementation map and supports a listed obligation.
  • Missing test: absent - Changed behavior has targeted fake-tmux, boundary, installer, doctor, help, documentation, and full-suite regression evidence.

Findings

None

Missing tests

  • None

Fix instructions

None

Notes

  • The prior review path named in the request was absent before this review, so there were no earlier findings to compare.
  • Review verification passed: bash scripts/devloop_test.sh, Bash syntax checks, ShellCheck, and git diff --check main...HEAD.
  • Real attach and detach are intentionally proven through tmux's documented command contract and fake argv assertions, preserving invariant I6.

@satyaborg

Copy link
Copy Markdown
Owner Author

Devloop Final Report

Field Value
Final status accepted
Pass count 1 / 5
Final verdict ACCEPT
PR URL #88
Branch feat/default-tmux-sessions

Acceptance Matrix Summary

Acceptance matrix

Obligation Status Implementation evidence Test evidence
AC1 PASS run_command validates before delegating once to tmux_launch_session (devloop:3016-3024); the outside branch uses attached new-session with the named child (devloop:378-381). The fake-tmux outside launch asserts new-session, -s, no -d, and no foreground execution (scripts/devloop_test.sh:541-562,609-628).
AC2 PASS A nonempty TMUX selects detached new-session -d followed by switch-client, with no nested attach (devloop:364-375). The inside-tmux fixture asserts detached creation, client switching, continue argv, and one recursion guard (scripts/devloop_test.sh:564-574).
AC3 PASS tmux_session_base_name normalizes the repository basename and the supplied spec or track filename (devloop:302-319); continue callers supply the validated track (devloop:1823-1829,1989-2001). Normalization, fallback names, run names, and both explicit and menu continue track arguments are asserted (scripts/devloop_test.sh:495-498,684-696,750-763).
AC4 PASS tmux_allocate_session_name checks exact names and increments from -2 until free (devloop:325-336); launch uses only new-session, never attach-or-create (devloop:364-381). Occupied base and -2 allocate -3; the launcher assertion rejects -A (scripts/devloop_test.sh:531-535,558-560).
AC5 PASS The launcher starts the devloop child as the tmux session command and adds no cleanup or keepalive process (devloop:351-381). The fake launcher verifies a named session and direct child command, while help and README checks verify list, detach, and reattach guidance (scripts/devloop_test.sh:541-562,85-91,116-119).
AC6 PASS run_command and continue_command parse --no-tmux, skip the boundary, and call their existing foreground owners (devloop:1954-2004,2939-3031). Explicit run and continue tests force interactive eligibility and assert zero launcher calls plus foreground delegation (scripts/devloop_test.sh:630-643,698-707).
AC7 PASS devloop_tmux_interactive requires TTY stdin and stdout; otherwise run_command reaches the unchanged foreground path (devloop:298-300,3016-3031). Separate non-TTY stdin and stdout checks reject eligibility, and a false predicate test asserts foreground run with no tmux launch (scripts/devloop_test.sh:499-500,645-657).
AC8 PASS interactive_run_setup resolves PR mode first and serializes TUI, report, strictness, worktree, PR, shell, agents, timeout, spec, and max into one child argv (devloop:1722-1762). The menu fixture asserts one PR prompt, one launch, resolved TUI, agent, timeout, PR, and shell values, and no foreground loop (scripts/devloop_test.sh:720-748).
AC9 PASS Explicit and menu continue validate the track before one launch; the guarded child re-enters continue_command, which delegates to canonical run_from_track (devloop:1806-1831,1953-2004,2843-2878). Explicit and menu-selected continue each assert one boundary call with the resolved track; foreground continue coverage exercises run_from_track (scripts/devloop_test.sh:684-707,750-763,2930-2955,3046-3050).
AC10 PASS tmux_launch_session checks command availability before name allocation or child creation and returns actionable installation guidance (devloop:338-349). The missing-command fixture asserts nonzero status and installer/install guidance (scripts/devloop_test.sh:598-605).
AC11 PASS Runs call validate_spec_for_tmux, and continues call validate_track_for_run, before the launcher (devloop:1748-1762,1823-1829,1989-2004,3016-3024). Missing spec and track cases assert the existing error and an empty launcher log (scripts/devloop_test.sh:672-682,709-718).
AC12 PASS Both new-session branches return nonzero immediately on failure and contain no foreground fallback (devloop:364-381). The fake new-session failure is propagated, does not switch clients, and the run-boundary failure test proves no foreground retry (scripts/devloop_test.sh:576-584,659-670).
AC13 PASS The launcher passes -c "$PWD", an absolute env, PATH=$PATH, the runtime, and array-expanded child arguments, injecting one guard (devloop:338-378). The fake-tmux log asserts cwd, PATH, runtime, spaces, metacharacters, and exactly one --no-tmux (scripts/devloop_test.sh:537-562,564-574).
AC14 PASS Only run and continue entry functions call the launcher; utility dispatch remains direct, and nightshift explicitly adds --no-tmux (devloop:86-165,1722-1768,1806-1831,1953-2004,2331-2342,2921-3031). Existing main-dispatch tests exercise menu, spec, nightshift, update, status, clean, reports, and doctor; nightshift argv explicitly includes --no-tmux (scripts/devloop_test.sh:1542-1572,1349,2028-2155,2542-2615,3044-3052).
AC15 PASS Both installers include tmux in discovery and post-install verification, and doctor includes it in required readiness (scripts/install.sh:49-101, scripts/install.remote.sh:188-224,271-314,405-438, scripts/skill_helpers.sh:343-367). Local and remote bootstrap fixtures assert tmux installation; doctor passes with tmux and fails without it (scripts/devloop_test.sh:1915-1916,2017-2206,2330-2354,2542-2615).
AC16 PASS Plain help, TUI help, README, and CONTRIBUTING document the default, required dependency, override, and applicable detach/reattach workflow (devloop:183-228,231-268, README.md:27-53, CONTRIBUTING.md:11-14). Help, TUI, README, and CONTRIBUTING string assertions cover tmux, --no-tmux, Ctrl-b d, and tmux attach -t (scripts/devloop_test.sh:70-91,113-123,451-468).
AC17 PASS New behavior is isolated in sourceable functions and tmux execution is injectable through PATH and function overrides. bash scripts/devloop_test.sh passed on review, ending with ok - 100% project function coverage; the tmux block uses only a fake executable (scripts/devloop_test.sh:502-529,3354).
F1 PASS Missing tmux returns before building or executing the child (devloop:338-349). Missing-tmux and launch-failure tests assert nonzero status, guidance, and no foreground retry (scripts/devloop_test.sh:598-605,659-670).
F2 PASS Exact-name allocation chooses the first free suffix; no code path uses new-session -A (devloop:325-381). The collision fixture allocates -3 after base and -2, and the launch log asserts absence of -A (scripts/devloop_test.sh:531-535,558-560).
F3 PASS Spec and track validators run before all eligible tmux calls (devloop:1748-1762,1823-1829,1989-2004,3016-3024). Invalid spec and track tests assert validation output and no launcher call (scripts/devloop_test.sh:672-682,709-718).
F4 PASS Failed creation returns immediately from either inside or outside branch, with no retry (devloop:364-381). The injected creation failure returns nonzero, reports the allocated session, skips switching, and the caller test rejects foreground retry (scripts/devloop_test.sh:576-584,659-670).
F5 PASS Switch failure reports the allocated name and manual switch and attach commands, then returns without killing or relaunching (devloop:369-374). The switch-failure fixture asserts all recovery guidance and exactly one new-session (scripts/devloop_test.sh:586-596).
F6 PASS Noninteractive eligibility fails unless both standard streams are TTYs, leaving foreground ownership unchanged (devloop:298-300,3016-3031). Non-TTY stdin, non-TTY stdout, and foreground delegation are covered (scripts/devloop_test.sh:499-500,645-657).
F7 PASS Both parsers consume --no-tmux as control state and exclude it from normal run or track semantics (devloop:1953-2004,2921-3031). Interactive-forced run and continue tests assert no launcher invocation and equivalent foreground arguments (scripts/devloop_test.sh:630-643,698-707).
F8 PASS Devloop launches as the tmux session command and performs no detach cleanup, so tmux owns persistence (devloop:364-381). The named-session argv test plus help and README detach/reattach assertions verify the intended tmux lifecycle contract (scripts/devloop_test.sh:537-562,85-91,116-119).
F9 PASS The parent injects --no-tmux into run or continue child argv, and both child parsers bypass wrapping when it is present (devloop:351-354,1953-2004,2975-3025). Outside and inside launcher logs each contain exactly one guard; separate guarded run and continue tests prove re-entry bypass (scripts/devloop_test.sh:561,574,630-643,698-707).
F10 PASS Child arguments are Bash array elements passed directly after tmux --, without eval or sh -c (devloop:343-378). Arguments containing spaces and shell metacharacters remain distinct in the fake log and do not create the marker file (scripts/devloop_test.sh:540-562).
F11 PASS An absolute env executable sets the caller's current PATH for the direct child command (devloop:357-378). The fake log asserts the exact current PATH assignment and resolved runtime argv (scripts/devloop_test.sh:552-556).
F12 PASS The tmux command ends at the devloop child argv and adds no shell, prompt, sleep, or keepalive (devloop:351-381). The launcher test asserts no shell wrapper; the direct argv layout contains only env, PATH, runtime, guard, and original arguments (scripts/devloop_test.sh:548-562).
F13 PASS nightshift_run_spec always invokes child loops with --plain --no-tmux --no-shell (devloop:2331-2342). Nightshift orchestration asserts all five child invocations include the headless --no-tmux flag set (scripts/devloop_test.sh:1347-1351).
I1 PASS Each eligible caller returns immediately after one tmux_launch_session; that helper issues one new-session for the allocated name (devloop:1748-1762,1823-1829,1989-2004,3016-3024,364-381). Explicit and menu boundaries assert one launch with no foreground loop; switch failure separately asserts one creation (scripts/devloop_test.sh:609-628,684-696,720-764,595).
I2 PASS Allocation never mutates occupied sessions, and launcher operations are limited to listing, fresh creation, and client switching (devloop:325-381). Collision and argv tests prove exact lookup, numeric allocation, and absence of -A; no fake operation attaches to, replaces, or kills an existing session (scripts/devloop_test.sh:531-560).
I3 PASS Automatic wrapping is called only from explicit/menu run and continue; nightshift opts out and utilities keep their prior dispatch (devloop:86-165,1722-1768,1806-1831,1953-2004,2331-2342,2921-3031). Main dispatch coverage plus the nightshift argv assertion exercise the excluded workflows without a tmux boundary (scripts/devloop_test.sh:1349,1542-1572,2028-2155,2542-2615,3044-3052).
I4 PASS The child guard returns execution to the existing run_devloop and run_from_track owners without moving loop, worktree, reporting, or exit logic into tmux helpers (devloop:2843-2878,3027-3031). Guarded foreground run/continue tests and the existing end-to-end loop/continue suite pass (scripts/devloop_test.sh:630-657,698-707,2867-2955,3014-3055).
I5 PASS User-controlled values stay in arrays and are expanded as "${child[@]}"; no assembled shell command is used (devloop:343-378). Space and metacharacter cases remain separate fake-tmux argv entries and are not evaluated (scripts/devloop_test.sh:540-562).
I6 PASS Tmux calls are isolated behind a PATH-resolved command suitable for a fixture. The suite prepends its fake tmux before launcher tests, restores PATH afterward, and the full suite passes without a real-session operation (scripts/devloop_test.sh:502-529,766-768).

Engineering Quality Summary

Engineering quality matrix

Area Status Evidence
Correctness PASS Validation precedes launch, inside and outside tmux paths are distinct, failures do not fall back, and the full regression suite passes.
Test quality PASS Tests cover naming, collision allocation, direct argv, recursion guards, both tmux contexts, failure recovery, explicit/menu run and continue, installers, doctor, help, documentation, and retain 100% project-function coverage.
Maintainability PASS Tmux behavior is concentrated in small helpers, while entry points only validate, serialize resolved choices, and delegate.
Architecture boundaries PASS Existing run_devloop, run_from_track, menu selection, nightshift, installer, and doctor ownership remains intact across the new process boundary.
Simplicity PASS The solution uses one public recursion flag and direct tmux commands without polling, PID state, generated scripts, cleanup orchestration, or compatibility layers.
Security PASS Paths and user arguments remain distinct argv entries, session names are normalized, and no shell interpolation, eval, or sh -c is introduced.
Operational safety PASS Fresh names avoid session reuse, creation and switch failures are recoverable, existing sessions are never killed, and tests cannot reach a real tmux server through the fixture path.

Implementation Summary

  • Final branch: feat/default-tmux-sessions
  • Final commit: 7632883
  • Commit message: feat: default-tmux-sessions

Commit References

  • pass 1 7632883 feat: default-tmux-sessions (CONTRIBUTING.md, README.md, devloop, scripts/devloop_test.sh, scripts/install.remote.sh, scripts/install.sh, scripts/skill_helpers.sh)

Tests Run

  • Verification hook log: not configured
  • Review test evidence: see the acceptance matrix summary above.

Residual Risk

  • No blocking residual risk was recorded by the final review.

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