feat(maestro): register dormant sessions on recovery
A host reboot kills the tmux server, so `SessionManager::recover` iterated an empty list and every session vanished from the API while its sidecar sat untouched on disk. A second recovery pass now reads the sidecars tmux had nothing to adopt and registers each as `SessionStatus::Dormant` — a record of what was running, with no pane and no PTY bridge behind it. `SessionStatus` deserializes leniently now, like `ActivityState`: an unknown spelling reads as `Dead` rather than failing the whole `Session`. Refs #162 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
8325bc6d9a
commit
72644dd564
+4
-1
@@ -6,7 +6,10 @@ import { escapeHtml } from "./html.js";
|
||||
export type Uuid = string;
|
||||
export type IsoTimestamp = string;
|
||||
|
||||
export type SessionStatus = "Running" | "Dead";
|
||||
/** `Dormant` (#162) is a session the daemon knows only from its sidecar —
|
||||
* recovered after the tmux server died under it, so there is no pane behind it
|
||||
* and nothing to attach to. Listed, never live. */
|
||||
export type SessionStatus = "Running" | "Dead" | "Dormant";
|
||||
|
||||
/** Daemon-inferred activity dimension, orthogonal to `SessionStatus` (NAP-340).
|
||||
* Absent on payloads from daemons that predate the field. `Error` is only set
|
||||
|
||||
Reference in New Issue
Block a user