@sentropic/h2a-runtime 0.92.0 → 0.93.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/conv-guard.d.ts +6 -1
- package/dist/conv-guard.d.ts.map +1 -1
- package/dist/conv-guard.js +33 -8
- package/dist/conv-guard.js.map +1 -1
- package/dist/enroll.d.ts.map +1 -1
- package/dist/enroll.js +12 -2
- package/dist/enroll.js.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +743 -97
- package/dist/index.js.map +1 -1
- package/dist/launch-layout.d.ts +74 -0
- package/dist/launch-layout.d.ts.map +1 -0
- package/dist/launch-layout.js +324 -0
- package/dist/launch-layout.js.map +1 -0
- package/dist/native-host.d.ts +146 -0
- package/dist/native-host.d.ts.map +1 -0
- package/dist/native-host.js +456 -0
- package/dist/native-host.js.map +1 -0
- package/dist/native-terminal/host.d.ts +317 -1
- package/dist/native-terminal/host.d.ts.map +1 -1
- package/dist/native-terminal/host.js +696 -3
- package/dist/native-terminal/host.js.map +1 -1
- package/dist/native-terminal/op.d.ts +5 -0
- package/dist/native-terminal/op.d.ts.map +1 -0
- package/dist/native-terminal/op.js +408 -0
- package/dist/native-terminal/op.js.map +1 -0
- package/dist/native-terminal/process.d.ts +2 -0
- package/dist/native-terminal/process.d.ts.map +1 -1
- package/dist/native-terminal/process.js +16 -2
- package/dist/native-terminal/process.js.map +1 -1
- package/dist/native-terminal/server.d.ts.map +1 -1
- package/dist/native-terminal/server.js +6 -2
- package/dist/native-terminal/server.js.map +1 -1
- package/dist/native-terminal/socket-path.d.ts +8 -0
- package/dist/native-terminal/socket-path.d.ts.map +1 -1
- package/dist/native-terminal/socket-path.js +31 -1
- package/dist/native-terminal/socket-path.js.map +1 -1
- package/dist/native-terminal/supervisor.d.ts +13 -0
- package/dist/native-terminal/supervisor.d.ts.map +1 -1
- package/dist/native-terminal/supervisor.js +45 -0
- package/dist/native-terminal/supervisor.js.map +1 -1
- package/dist/pty.d.ts +23 -0
- package/dist/pty.d.ts.map +1 -1
- package/dist/pty.js +35 -0
- package/dist/pty.js.map +1 -1
- package/dist/readiness.d.ts +7 -0
- package/dist/readiness.d.ts.map +1 -1
- package/dist/readiness.js +12 -9
- package/dist/readiness.js.map +1 -1
- package/dist/registry.d.ts +317 -2
- package/dist/registry.d.ts.map +1 -1
- package/dist/registry.js +622 -19
- package/dist/registry.js.map +1 -1
- package/dist/restore.d.ts +91 -32
- package/dist/restore.d.ts.map +1 -1
- package/dist/restore.js +226 -186
- package/dist/restore.js.map +1 -1
- package/dist/tmux.d.ts +2 -1
- package/dist/tmux.d.ts.map +1 -1
- package/dist/tmux.js +1 -1
- package/dist/tmux.js.map +1 -1
- package/package.json +1 -1
package/dist/registry.d.ts
CHANGED
|
@@ -15,7 +15,9 @@
|
|
|
15
15
|
import { type LocalSession } from "./tmux.js";
|
|
16
16
|
import type { SessionClass } from "./session-class.js";
|
|
17
17
|
export type RegistryTool = "claude" | "codex" | "agy";
|
|
18
|
-
export type RegistryKind = "local-tmux" | "local" | "remote";
|
|
18
|
+
export type RegistryKind = "local-tmux" | "local-native" | "local" | "remote";
|
|
19
|
+
/** Managed local interactive session hosted by tmux OR the native PTY host. */
|
|
20
|
+
export declare function isManagedLocalKind(kind: RegistryKind): kind is "local-tmux" | "local-native";
|
|
19
21
|
export type RegistrySource = "run" | "hook" | "scan" | "remote";
|
|
20
22
|
/**
|
|
21
23
|
* Delegated-job extension (P1 of cross-type agent delegation). A job IS a
|
|
@@ -67,6 +69,59 @@ export type RegistryEntry = {
|
|
|
67
69
|
tmuxSession?: string;
|
|
68
70
|
/** Local process id (kind "local"); liveness = process.kill(pid, 0). */
|
|
69
71
|
pid?: number;
|
|
72
|
+
/**
|
|
73
|
+
* Process-group id of a native-terminal PTY session (see
|
|
74
|
+
* native-terminal/host.ts's `persistNativeTerminalPgid`). Persisted at
|
|
75
|
+
* session CREATION time so a host that never knew the session (e.g. a fresh
|
|
76
|
+
* host started after the owning host was killed) can still reap the whole
|
|
77
|
+
* process tree from this durable record — "known at creation" must survive
|
|
78
|
+
* to "known at kill time", which only a durable store (not host memory)
|
|
79
|
+
* can guarantee.
|
|
80
|
+
*/
|
|
81
|
+
pgid?: number;
|
|
82
|
+
/**
|
|
83
|
+
* The process-GROUP-LEADER's own start-time (Linux `/proc/<pgid>/stat`
|
|
84
|
+
* field 22), captured at the SAME moment as `pgid` above (leader pid ==
|
|
85
|
+
* pgid — see `PtyHandle.pgid`'s doc comment in pty.ts). This is the
|
|
86
|
+
* pid-recycling-proof discriminant for the GROUP itself, exactly as
|
|
87
|
+
* `ownerHostStartTime` is for the HOST: a reaper must re-read this pid's
|
|
88
|
+
* CURRENT start-time immediately before `kill(-pgid, sig)` and compare —
|
|
89
|
+
* a match proves the group is still the one this row was written for; a
|
|
90
|
+
* mismatch means the OS recycled `pgid` to an unrelated group since this
|
|
91
|
+
* row was written. See `#killGroupAndConfirmDead` in native-terminal/host.ts,
|
|
92
|
+
* the sole consumer.
|
|
93
|
+
*/
|
|
94
|
+
pgidLeaderStartTime?: number;
|
|
95
|
+
/**
|
|
96
|
+
* A random per-session token, generated at PTY-creation time and injected
|
|
97
|
+
* into the spawned tree's OWN environment (`H2A_SESSION_TOKEN`, inherited
|
|
98
|
+
* by every descendant), persisted on the SAME durable write as `pgid`/
|
|
99
|
+
* `pgidLeaderStartTime`. The GROUP-MEMBERSHIP anchor for the case
|
|
100
|
+
* `pgidLeaderStartTime` cannot cover: the leader (pid==pgid) is gone but
|
|
101
|
+
* the group is still alive (the ORDINARY orphan — a shell that exits
|
|
102
|
+
* normally leaving a backgrounded descendant), so there is no leader left
|
|
103
|
+
* to re-read a start-time from at all. A surviving group member whose own
|
|
104
|
+
* `/proc/<pid>/environ` still carries this exact token is POSITIVE proof
|
|
105
|
+
* of membership in THIS row's group, independent of any leader. See
|
|
106
|
+
* `#verifyGroupLeaderIdentity` in native-terminal/host.ts, the sole
|
|
107
|
+
* consumer, for the full decision order and its declared limits
|
|
108
|
+
* (same-uid-only environ reads; non-adversarial by design).
|
|
109
|
+
*/
|
|
110
|
+
pgidGroupToken?: string;
|
|
111
|
+
/**
|
|
112
|
+
* Owning host attribution for a native-terminal-pty row (see `pgid` above).
|
|
113
|
+
* `ownerHostPid` is the pid of the host process that created this PTY and
|
|
114
|
+
* durably persisted its pgid; `ownerHostStartTime` is that host's own
|
|
115
|
+
* process start-time (Linux `/proc/<pid>/stat` field 22, clock ticks since
|
|
116
|
+
* boot) at the moment of persistence — the discriminant that survives pid
|
|
117
|
+
* recycling. A reaper must prove the HOST is dead (pid gone, or a live pid
|
|
118
|
+
* whose start-time no longer matches — i.e. reused) before touching this
|
|
119
|
+
* row's pgid; a merely-unreachable-but-alive host (e.g. overloaded, a
|
|
120
|
+
* paused process) is NOT proof of death and must never be reaped. See
|
|
121
|
+
* `reconcileDeadHostOrphans` in native-terminal/host.ts, the sole consumer.
|
|
122
|
+
*/
|
|
123
|
+
ownerHostPid?: number;
|
|
124
|
+
ownerHostStartTime?: number;
|
|
70
125
|
enrolledAt: string;
|
|
71
126
|
lastSeenAt: string;
|
|
72
127
|
endedAt?: string;
|
|
@@ -172,6 +227,12 @@ export type EnrollInput = {
|
|
|
172
227
|
/** Injectable liveness probes (tests stay deterministic, no tmux/pid needed). */
|
|
173
228
|
export type LivenessOpts = {
|
|
174
229
|
tmuxHasSession?: (name: string) => boolean;
|
|
230
|
+
/**
|
|
231
|
+
* Injectable native-PTY-host session probe (kind:"local-native"). 3-state
|
|
232
|
+
* (F2): "unknown" is a PROBE FAILURE, never proof of death — isLive treats
|
|
233
|
+
* it as possibly-live so an unprovable session is never pruned/hidden.
|
|
234
|
+
*/
|
|
235
|
+
nativeSessionLiveness?: (name: string) => true | false | "unknown";
|
|
175
236
|
pidAlive?: (pid: number) => boolean;
|
|
176
237
|
/** System boot time (ms epoch). A `kind:"local"` entry last seen before this
|
|
177
238
|
* is dead — its process died in the reboot, so its PID must not be trusted
|
|
@@ -185,7 +246,75 @@ type RegistryOpts = LivenessOpts & {
|
|
|
185
246
|
};
|
|
186
247
|
export declare function resolveRegistryPath(): string;
|
|
187
248
|
export declare function looksLikeConversationUuid(value: string | undefined): boolean;
|
|
188
|
-
|
|
249
|
+
/**
|
|
250
|
+
* 3-state registry READ (F2), extended by the rebase reconciliation (2026-08)
|
|
251
|
+
* to carry PER-ROW unreadable rows instead of silently dropping them. The lie
|
|
252
|
+
* this type removes: a corrupt/unreadable registry FILE used to flatten into
|
|
253
|
+
* `[]` — indistinguishable from "no rows" — which let destructive acts
|
|
254
|
+
* (stop/kill/relaunch) treat an UNPROVABLE local state as PROVEN ABSENCE and
|
|
255
|
+
* fall through to a remote homonym. A SINGLE unreadable ROW inside an
|
|
256
|
+
* otherwise-valid file used to be silently filtered out of "ok" the same
|
|
257
|
+
* way — the same lie, at row granularity: a valid row plus an unreadable
|
|
258
|
+
* TWIN of the same name resolved as if only the valid row existed. The read
|
|
259
|
+
* now says which of the three it is, and the compiler enumerates every
|
|
260
|
+
* caller:
|
|
261
|
+
* - "ok": the FILE was read and validated ("ok" with entries:[] includes the
|
|
262
|
+
* PROVABLY-empty ENOENT case — rows cannot exist without a file).
|
|
263
|
+
* `unreadable` carries every row that failed `isRegistryEntry` verbatim
|
|
264
|
+
* (raw, defensively typed) — absence must be provable BY IDENTITY, so a
|
|
265
|
+
* destructive caller resolving target X must check whether an unreadable
|
|
266
|
+
* row COULD be X, not merely whether the array is non-empty. A rotten
|
|
267
|
+
* legacy row must not disable the WHOLE tool — that would trade a lie for
|
|
268
|
+
* an outage — so a per-row failure never flips the file to "unknown".
|
|
269
|
+
* - "unknown": the FILE itself could not be read/parsed (ENOENT excluded —
|
|
270
|
+
* see "ok" above). Destructive callers MUST refuse; views may degrade but
|
|
271
|
+
* must never assert absence.
|
|
272
|
+
* The unknown branch deliberately carries NO `entries`/`unreadable` fields,
|
|
273
|
+
* so a caller cannot mechanically re-flatten it into an empty collection.
|
|
274
|
+
*/
|
|
275
|
+
export type RegistryReadResult = {
|
|
276
|
+
readonly state: "ok";
|
|
277
|
+
readonly entries: RegistryEntry[];
|
|
278
|
+
/** Raw rows that failed `isRegistryEntry`, preserved verbatim (never dropped). */
|
|
279
|
+
readonly unreadable: readonly RawRow[];
|
|
280
|
+
} | {
|
|
281
|
+
readonly state: "unknown";
|
|
282
|
+
readonly reason: string;
|
|
283
|
+
};
|
|
284
|
+
/** A raw, unvalidated registry row — read DEFENSIVELY (it failed validation). */
|
|
285
|
+
export type RawRow = Record<string, unknown>;
|
|
286
|
+
export declare function loadRegistry(path?: string): RegistryReadResult;
|
|
287
|
+
/**
|
|
288
|
+
* Unreadable rows (from an ALREADY-READ `loadRegistry()` snapshot) that
|
|
289
|
+
* plausibly address `target` under the resolver's identity rules. Pure — no
|
|
290
|
+
* fs — so every caller consults the SAME snapshot instead of re-reading the
|
|
291
|
+
* file (this is what `resolveManagedHost` calls for its per-identity poison
|
|
292
|
+
* check, A2). THE RULE: absence must be provable BY IDENTITY — an unknown by
|
|
293
|
+
* identity for X, never a global unknown that disables every OTHER identity.
|
|
294
|
+
*/
|
|
295
|
+
export declare function unreadableRowsForTarget(target: string, unreadable: readonly RawRow[]): RawRow[];
|
|
296
|
+
/**
|
|
297
|
+
* Path-based convenience wrapper: performs its OWN registry read (a second
|
|
298
|
+
* read when the caller already has one — prefer `unreadableRowsForTarget`
|
|
299
|
+
* with an existing `loadRegistry()` snapshot when one is available, e.g.
|
|
300
|
+
* inside `resolveManagedHost`). Raw rows in the registry FILE that FAIL
|
|
301
|
+
* validation (e.g. `kind` absent or unreadable) but plausibly address
|
|
302
|
+
* `target`. `loadRegistry()` cannot return them as `entries` — but a
|
|
303
|
+
* DESTRUCTIVE caller must know the identity exists in an unreadable state:
|
|
304
|
+
* such a row makes local host state UNKNOWN (fail closed, sol-2), never "no
|
|
305
|
+
* local session" — which would let the act fall through to a REMOTE homonym.
|
|
306
|
+
*
|
|
307
|
+
* B3 — this is itself a RE-READ on a destructive path (a TOCTOU window: the
|
|
308
|
+
* caller's own earlier read may have succeeded, then the registry became
|
|
309
|
+
* unreadable strictly BETWEEN the two reads — another writer, a partial
|
|
310
|
+
* write, disk pressure). A re-read inherits the SAME 3-state contract as the
|
|
311
|
+
* first: a whole-file "unknown" here used to flatten to `[]` — "no
|
|
312
|
+
* unreadable row for this identity" — which is indistinguishable from "the
|
|
313
|
+
* row is fine" and let the caller fall through past this guard. Returns
|
|
314
|
+
* `"unknown"` instead so the caller refuses exactly like any other unknown
|
|
315
|
+
* registry read, never silently re-simplified into an empty collection.
|
|
316
|
+
*/
|
|
317
|
+
export declare function unreadableRegistryRowsForTarget(target: string, path?: string): RawRow[] | "unknown";
|
|
189
318
|
/**
|
|
190
319
|
* Read the registry without collapsing a missing/corrupt file into an empty
|
|
191
320
|
* collection. Operational commands may rebuild their registry; the status
|
|
@@ -196,6 +325,81 @@ export declare function loadRegistryWithDiagnostics(path?: string): {
|
|
|
196
325
|
known: boolean;
|
|
197
326
|
reason?: string;
|
|
198
327
|
};
|
|
328
|
+
/**
|
|
329
|
+
* Persist a native-terminal PTY session's process-group id, durably, at
|
|
330
|
+
* session CREATION time (see native-terminal/host.ts `create()`). Synchronous
|
|
331
|
+
* (the registry write is sync) so a caller can treat a thrown error as "this
|
|
332
|
+
* session's pgid did NOT get durably recorded" and refuse to create an
|
|
333
|
+
* untracked, unreapable session.
|
|
334
|
+
*/
|
|
335
|
+
/** Owning-host attribution captured at PTY-creation time (see `RegistryEntry.ownerHostPid`). */
|
|
336
|
+
export type NativeTerminalPgidOwner = {
|
|
337
|
+
pid: number;
|
|
338
|
+
startTime?: number;
|
|
339
|
+
};
|
|
340
|
+
export declare function persistNativeTerminalPgid(sessionId: string, pgid: number, path?: string, owner?: NativeTerminalPgidOwner, leaderStartTime?: number, groupToken?: string): void;
|
|
341
|
+
/** Result of resolving a native-terminal session's durable pgid. */
|
|
342
|
+
export type NativeTerminalPgidLookup = {
|
|
343
|
+
status: "resolved";
|
|
344
|
+
pgid: number;
|
|
345
|
+
leaderStartTime?: number;
|
|
346
|
+
groupToken?: string;
|
|
347
|
+
} | {
|
|
348
|
+
status: "unresolved";
|
|
349
|
+
reason: string;
|
|
350
|
+
};
|
|
351
|
+
/**
|
|
352
|
+
* Resolve a native-terminal PTY session's durable pgid, for a reap that may
|
|
353
|
+
* come from a host that never knew the session (e.g. a fresh host started
|
|
354
|
+
* after the owning host was killed).
|
|
355
|
+
*
|
|
356
|
+
* Reads via `loadRegistryWithDiagnostics`, NEVER via the plain `loadRegistry`
|
|
357
|
+
* array reader: `loadRegistry` silently flattens a corrupt/unreadable
|
|
358
|
+
* registry to `[]`, which would conflate two very different situations —
|
|
359
|
+
* "this session genuinely has no recorded pgid" vs. "the registry could not
|
|
360
|
+
* be read at all". A reaper must tell those apart: an unreadable registry
|
|
361
|
+
* must NEVER be treated as "nothing to reap" (that recreates the exact
|
|
362
|
+
* invisible-orphan bug this mechanism exists to close), so it is reported as
|
|
363
|
+
* `unresolved` with a diagnostic reason, loudly, by the caller (see
|
|
364
|
+
* `NativeTerminalHost#reapOrphan`), which must never guess a pgid or kill
|
|
365
|
+
* silently on either branch below.
|
|
366
|
+
*
|
|
367
|
+
* (If/when a future 3-state `loadRegistry` lands — `state: "ok" | "unknown"`
|
|
368
|
+
* — the migration is a refinement of the condition below, not a new branch:
|
|
369
|
+
* map `state: "unknown"` to the same `unresolved` result.)
|
|
370
|
+
*/
|
|
371
|
+
export declare function readNativeTerminalPgid(sessionId: string, path?: string): NativeTerminalPgidLookup;
|
|
372
|
+
/** One native-terminal-pty row, decoded from its namespaced registry id. */
|
|
373
|
+
export type NativeTerminalPgidEntry = Readonly<{
|
|
374
|
+
sessionId: string;
|
|
375
|
+
pgid: number;
|
|
376
|
+
owner?: NativeTerminalPgidOwner;
|
|
377
|
+
}>;
|
|
378
|
+
/** Outcome of enumerating every native-terminal-pty row in the registry. */
|
|
379
|
+
export type NativeTerminalPgidSnapshot = {
|
|
380
|
+
known: true;
|
|
381
|
+
entries: ReadonlyArray<NativeTerminalPgidEntry>;
|
|
382
|
+
} | {
|
|
383
|
+
known: false;
|
|
384
|
+
reason: string;
|
|
385
|
+
};
|
|
386
|
+
/**
|
|
387
|
+
* Enumerate every durably-persisted native-terminal PTY session, for a
|
|
388
|
+
* reconcile pass that must decide, PER ENTRY, whether its owning host is
|
|
389
|
+
* proven dead (see `reconcileDeadHostOrphans` in native-terminal/host.ts, the
|
|
390
|
+
* sole consumer). Reads via `loadRegistryWithDiagnostics` for the same reason
|
|
391
|
+
* `readNativeTerminalPgid` does: an unreadable registry must never collapse
|
|
392
|
+
* to "zero entries" — that would silently make a reconcile pass reap
|
|
393
|
+
* (or skip) NOTHING while believing it saw the whole truth.
|
|
394
|
+
*/
|
|
395
|
+
export declare function listNativeTerminalPgidEntries(path?: string): NativeTerminalPgidSnapshot;
|
|
396
|
+
/**
|
|
397
|
+
* Remove a single native-terminal-pty row once its orphan group has been
|
|
398
|
+
* reaped (or it is otherwise confirmed handled). Returns false when the id
|
|
399
|
+
* was not present (already pruned, or never existed) — a no-op, not an
|
|
400
|
+
* error, since a reconcile pass may race a concurrent prune of the same row.
|
|
401
|
+
*/
|
|
402
|
+
export declare function pruneNativeTerminalPgidEntry(sessionId: string, path?: string): boolean;
|
|
199
403
|
/**
|
|
200
404
|
* Run `fn` under the registry lock: load the current entries, let `fn` mutate
|
|
201
405
|
* them (and compute a return value), then persist atomically — all inside ONE
|
|
@@ -277,6 +481,26 @@ export declare function listLive(opts?: RegistryOpts): RegistryEntry[];
|
|
|
277
481
|
* than maxAgeHours. Live entries always stay; recently-dead ones stay too so
|
|
278
482
|
* `restore` can still resume them after a reboot via the scan fallback.
|
|
279
483
|
* Returns the number of removed entries.
|
|
484
|
+
*
|
|
485
|
+
* RECONCILIATION DECISION (2026-08, #199 rebase — restore-pin x FILE-level
|
|
486
|
+
* unknown; architect to re-measure): `shouldPreserveByRestorePin` never
|
|
487
|
+
* observes `loadRegistry()`'s 3-state read directly — it runs INSIDE
|
|
488
|
+
* `withRegistryLock`, over the already-validated `entries` array only. Two
|
|
489
|
+
* unprovable cases both resolve CONSERVATIVE-PRESERVE by construction,
|
|
490
|
+
* neither newly added here:
|
|
491
|
+
* - whole-FILE unknown (corrupt/unreadable registry.json):
|
|
492
|
+
* `withRegistryLock`'s own raw read flattens to `[]` for its write-path
|
|
493
|
+
* contract, so `kept.length === entries.length` (0 === 0) and this prune
|
|
494
|
+
* is a NO-OP (`save:false`, see below) — nothing is read, so nothing a
|
|
495
|
+
* restore pin could have kept is ever written over or lost.
|
|
496
|
+
* - a single restore-pinned row that fails `isRegistryEntry` (per-row
|
|
497
|
+
* unreadable, PART A): it never reaches `entries` here at all (excluded
|
|
498
|
+
* before this callback runs), but `withRegistryLock`/`saveRegistry`
|
|
499
|
+
* re-append every such raw row VERBATIM on every write (sol-2) —
|
|
500
|
+
* `shouldPreserveByRestorePin` cannot prune what it never sees, and the
|
|
501
|
+
* row survives regardless of what this function decides.
|
|
502
|
+
* Neither case is exercised through an explicit `state:"unknown"` branch
|
|
503
|
+
* here (there isn't one to write) — REPORTED, not silently assumed settled.
|
|
280
504
|
*/
|
|
281
505
|
export declare function prune(maxAgeHours: number, opts?: RegistryOpts): number;
|
|
282
506
|
/** Map a CLI profile name to a registry tool (undefined for shell/opencode/…). */
|
|
@@ -289,6 +513,13 @@ export declare function enrollFromRun(args: {
|
|
|
289
513
|
profile: string;
|
|
290
514
|
slug: string;
|
|
291
515
|
tmuxSession: string;
|
|
516
|
+
/**
|
|
517
|
+
* Which local host ACTUALLY runs the session terminal. REQUIRED: the write
|
|
518
|
+
* boundary refuses to guess — an implicit "local-tmux" default mislabeled
|
|
519
|
+
* native sessions and re-routed later destructive acts (F2 family). A
|
|
520
|
+
* missing row is recoverable by discovery; a wrongly-hosted row is not.
|
|
521
|
+
*/
|
|
522
|
+
hostKind: "local-tmux" | "local-native";
|
|
292
523
|
/** Pane pid observed by the structured launcher, if available. */
|
|
293
524
|
pid?: number;
|
|
294
525
|
cwd: string;
|
|
@@ -354,5 +585,89 @@ export declare function resolveLocalTmuxSessionForName(target: string, entries:
|
|
|
354
585
|
* so it can report prefix collisions instead of falling through remotely.
|
|
355
586
|
*/
|
|
356
587
|
export declare function localTmuxSessionForName(target: string, entries: readonly RegistryEntry[]): string | undefined;
|
|
588
|
+
/**
|
|
589
|
+
* DEDICATED resolver for `kind:"local-native"` registry entries — the native
|
|
590
|
+
* twin of the local-tmux target filter in index.ts. That filter stays
|
|
591
|
+
* tmux-scoped on purpose: its second caller iterates LIVE tmux sessions by
|
|
592
|
+
* name inside the destructive relaunch planner, where a broadened match would
|
|
593
|
+
* be a category error. The two resolvers coexist so neither lies about its
|
|
594
|
+
* name.
|
|
595
|
+
*
|
|
596
|
+
* A native entry's PERSISTED identity, as measured on every native write path
|
|
597
|
+
* (`enroll` in startJob and `enrollFromRun` on run/resume/relaunch): `id` and
|
|
598
|
+
* `label` carry the slug, and `tmuxSession` — despite its tmux-era name —
|
|
599
|
+
* carries the native host session name `localSessionName(slug)`, the
|
|
600
|
+
* h2a-<slug> naming contract shared across hosts (native-host.ts). Historical
|
|
601
|
+
* rows without a persisted session name fall back to the managed-name
|
|
602
|
+
* candidates of their id, exactly like `isLive`.
|
|
603
|
+
*
|
|
604
|
+
* NO liveness input exists here by construction: which host a recorded
|
|
605
|
+
* session belongs to is decided by its persisted kind alone — a dead native
|
|
606
|
+
* session stays native. Whether an ACT on it can proceed is the caller's
|
|
607
|
+
* separate liveness gate.
|
|
608
|
+
* (0 local-native entries in the fleet registry as of 2026-08-08; this
|
|
609
|
+
* resolver prepares the re-use paths for the sessions #178 will produce.)
|
|
610
|
+
*/
|
|
611
|
+
export declare function registryEntriesForNativeTarget(target: string, entries: readonly RegistryEntry[]): RegistryEntry[];
|
|
612
|
+
/**
|
|
613
|
+
* The SAME exact-identity filter scoped to persisted `kind:"local-tmux"` rows.
|
|
614
|
+
* It exists so host resolution can consult BOTH persisted kinds symmetrically
|
|
615
|
+
* (`resolveManagedHost`): recognizing only one kind before falling back to a
|
|
616
|
+
* probe was the measured F2 defect — a persisted tmux row plus a homonymous
|
|
617
|
+
* live native process re-routed destructive acts to the wrong host.
|
|
618
|
+
* (The broader index.ts local-tmux target filter stays separate on purpose:
|
|
619
|
+
* it also matches LIVE tmux state for the relaunch planner.)
|
|
620
|
+
*/
|
|
621
|
+
export declare function registryEntriesForLocalTmuxTarget(target: string, entries: readonly RegistryEntry[]): RegistryEntry[];
|
|
622
|
+
/**
|
|
623
|
+
* Three-state host probe result. "unknown" is a PROBE FAILURE — it is never
|
|
624
|
+
* proof of death, and destructive callers must fail closed on it.
|
|
625
|
+
*/
|
|
626
|
+
export type ManagedHostProbeResult = "live" | "dead" | "unknown";
|
|
627
|
+
/** Native probe: an op failure is UNKNOWN, never dead (producer is 3-state). */
|
|
628
|
+
export declare function probeNativeSession(name: string): ManagedHostProbeResult;
|
|
629
|
+
/**
|
|
630
|
+
* Tmux probe. No tmux binary/server means no tmux session CAN exist (a tmux
|
|
631
|
+
* session cannot outlive its server), so that is provable death — only a
|
|
632
|
+
* spawn-level failure of an installed tmux is UNKNOWN.
|
|
633
|
+
*/
|
|
634
|
+
export declare function probeTmuxSession(name: string): ManagedHostProbeResult;
|
|
635
|
+
/**
|
|
636
|
+
* Symmetric managed-host resolution for acts on a local session
|
|
637
|
+
* (attach/stop/resume, and restore consumes the same result).
|
|
638
|
+
*
|
|
639
|
+
* Rules (the F1/F2 remedy):
|
|
640
|
+
* 1. The exact managed identity is matched against BOTH persisted kinds.
|
|
641
|
+
* 2. Exactly one persisted kind wins for acts on the existing process,
|
|
642
|
+
* REGARDLESS of the other host's liveness — liveness gates whether the
|
|
643
|
+
* act can run, never which host serves it.
|
|
644
|
+
* 3. Persisted rows of both kinds for one identity are AMBIGUOUS and the
|
|
645
|
+
* caller must fail closed.
|
|
646
|
+
* 4. Only when no persisted row exists may probes DISCOVER a host (a live
|
|
647
|
+
* session whose registry row was lost). Exactly one positive probe wins;
|
|
648
|
+
* two positives are ambiguous; a probe failure makes the resolution
|
|
649
|
+
* UNKNOWN (fail closed), never "dead on that host".
|
|
650
|
+
*/
|
|
651
|
+
export type ManagedHostResolution = {
|
|
652
|
+
readonly state: "recorded";
|
|
653
|
+
readonly kind: "local-native" | "local-tmux";
|
|
654
|
+
readonly name: string;
|
|
655
|
+
} | {
|
|
656
|
+
readonly state: "discovered";
|
|
657
|
+
readonly kind: "local-native" | "local-tmux";
|
|
658
|
+
readonly name: string;
|
|
659
|
+
} | {
|
|
660
|
+
readonly state: "ambiguous";
|
|
661
|
+
readonly candidates: ReadonlyArray<"local-native" | "local-tmux">;
|
|
662
|
+
} | {
|
|
663
|
+
readonly state: "missing";
|
|
664
|
+
} | {
|
|
665
|
+
readonly state: "unknown";
|
|
666
|
+
readonly reason: string;
|
|
667
|
+
};
|
|
668
|
+
export declare function resolveManagedHost(target: string, entries?: readonly RegistryEntry[] | RegistryReadResult, probes?: {
|
|
669
|
+
readonly native?: (name: string) => ManagedHostProbeResult;
|
|
670
|
+
readonly tmux?: (name: string) => ManagedHostProbeResult;
|
|
671
|
+
}): ManagedHostResolution;
|
|
357
672
|
export {};
|
|
358
673
|
//# sourceMappingURL=registry.d.ts.map
|
package/dist/registry.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../src/registry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAcH,OAAO,EAIL,KAAK,YAAY,EAClB,MAAM,WAAW,CAAC;AACnB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAEvD,MAAM,MAAM,YAAY,GAAG,QAAQ,GAAG,OAAO,GAAG,KAAK,CAAC;AACtD,MAAM,MAAM,YAAY,GAAG,YAAY,GAAG,OAAO,GAAG,QAAQ,CAAC;AAC7D,MAAM,MAAM,cAAc,GAAG,KAAK,GAAG,MAAM,GAAG,MAAM,GAAG,QAAQ,CAAC;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