@cleocode/core 2026.6.7 → 2026.6.8
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/db/index.d.ts +5 -1
- package/dist/db/index.d.ts.map +1 -1
- package/dist/db/index.js +5 -1
- package/dist/db/index.js.map +1 -1
- package/dist/docs/build-provenance-graph.d.ts +12 -0
- package/dist/docs/build-provenance-graph.d.ts.map +1 -1
- package/dist/docs/build-provenance-graph.js +52 -0
- package/dist/docs/build-provenance-graph.js.map +1 -1
- package/dist/docs/docs-read-model.d.ts +40 -0
- package/dist/docs/docs-read-model.d.ts.map +1 -1
- package/dist/docs/docs-read-model.js +29 -0
- package/dist/docs/docs-read-model.js.map +1 -1
- package/dist/docs/export-document.js +897 -730
- package/dist/docs/export-document.js.map +3 -3
- package/dist/docs/index.d.ts +4 -0
- package/dist/docs/index.d.ts.map +1 -1
- package/dist/docs/index.js +2 -0
- package/dist/docs/index.js.map +1 -1
- package/dist/docs/read-doc.d.ts +60 -0
- package/dist/docs/read-doc.d.ts.map +1 -0
- package/dist/docs/read-doc.js +188 -0
- package/dist/docs/read-doc.js.map +1 -0
- package/dist/docs/wikilinks.d.ts +119 -0
- package/dist/docs/wikilinks.d.ts.map +1 -0
- package/dist/docs/wikilinks.js +217 -0
- package/dist/docs/wikilinks.js.map +1 -0
- package/dist/llm/plugin-facade.js +941 -776
- package/dist/llm/plugin-facade.js.map +3 -3
- package/dist/store/dual-scope-db.d.ts +83 -0
- package/dist/store/dual-scope-db.d.ts.map +1 -1
- package/dist/store/dual-scope-db.js +135 -6
- package/dist/store/dual-scope-db.js.map +1 -1
- package/dist/store/exodus/abort-events.d.ts +116 -0
- package/dist/store/exodus/abort-events.d.ts.map +1 -0
- package/dist/store/exodus/abort-events.js +130 -0
- package/dist/store/exodus/abort-events.js.map +1 -0
- package/dist/store/exodus/index.d.ts +1 -0
- package/dist/store/exodus/index.d.ts.map +1 -1
- package/dist/store/exodus/index.js +1 -0
- package/dist/store/exodus/index.js.map +1 -1
- package/dist/store/repair-malformed-dbs.d.ts +87 -0
- package/dist/store/repair-malformed-dbs.d.ts.map +1 -0
- package/dist/store/repair-malformed-dbs.js +188 -0
- package/dist/store/repair-malformed-dbs.js.map +1 -0
- package/dist/store/schema/attachments.d.ts +133 -0
- package/dist/store/schema/attachments.d.ts.map +1 -1
- package/dist/store/schema/attachments.js +63 -0
- package/dist/store/schema/attachments.js.map +1 -1
- package/migrations/drizzle-tasks/20260605000001_t11826-docs-wikilinks/migration.sql +110 -0
- package/package.json +12 -12
|
@@ -50,6 +50,7 @@
|
|
|
50
50
|
* @see packages/core/migrations/drizzle-cleo-global — global migrations
|
|
51
51
|
*/
|
|
52
52
|
import type { NodeSQLiteDatabase } from 'drizzle-orm/node-sqlite';
|
|
53
|
+
import { type ExodusAbortDetail } from './exodus/abort-events.js';
|
|
53
54
|
import type * as CleoGlobalSchemaTypes from './schema/cleo-global/index.js';
|
|
54
55
|
import type * as CleoProjectSchemaTypes from './schema/cleo-project/index.js';
|
|
55
56
|
/**
|
|
@@ -77,6 +78,17 @@ export interface DualScopeDbHandle<TScope extends DualScope = DualScope> {
|
|
|
77
78
|
readonly scope: TScope;
|
|
78
79
|
/** Absolute path to the underlying SQLite file. */
|
|
79
80
|
readonly dbPath: string;
|
|
81
|
+
/**
|
|
82
|
+
* Set ONLY when the exodus-on-open data-continuity gate ABORTED the first-open
|
|
83
|
+
* auto-migration for this scope (T11828 · DHQ-059). When present, the handle is
|
|
84
|
+
* live and the consolidated `cleo.db` is internally consistent but EMPTY — the
|
|
85
|
+
* user's real data is still in the legacy fleet, which was kept as the source
|
|
86
|
+
* of truth. A read-only caller may safely ignore this marker; a MUTATING caller
|
|
87
|
+
* MUST treat its write as not-durable-against-source and react (see
|
|
88
|
+
* {@link assertWriteDurable}). `undefined` on every normal (migrated / skipped /
|
|
89
|
+
* fresh-install) open.
|
|
90
|
+
*/
|
|
91
|
+
readonly exodusAbort?: ExodusAbortDetail;
|
|
80
92
|
/**
|
|
81
93
|
* Close the underlying native handle and evict this entry from the
|
|
82
94
|
* singleton cache. Safe to call multiple times (idempotent).
|
|
@@ -101,6 +113,67 @@ export interface OpenDualScopeAtPathOptions {
|
|
|
101
113
|
*/
|
|
102
114
|
readonly dedicated?: boolean;
|
|
103
115
|
}
|
|
116
|
+
/**
|
|
117
|
+
* Thrown by {@link assertWriteDurable} when a MUTATING caller is about to write
|
|
118
|
+
* through a {@link DualScopeDbHandle} whose first-open exodus auto-migration
|
|
119
|
+
* ABORTED (T11828 · DHQ-059).
|
|
120
|
+
*
|
|
121
|
+
* The consolidated `cleo.db` is internally consistent but EMPTY: the user's real
|
|
122
|
+
* data is still in the legacy fleet (kept as the source of truth). Writing here
|
|
123
|
+
* would land in a DB that does not reflect that data, so the write is NOT durable
|
|
124
|
+
* against the source of truth. Read paths never raise this — they intentionally
|
|
125
|
+
* skip {@link assertWriteDurable} and operate on the empty-but-consistent DB.
|
|
126
|
+
*
|
|
127
|
+
* Self-contained (mirrors `BackupRecoverError`) rather than a `CleoError` subclass
|
|
128
|
+
* so the store layer does not need a new numeric `ExitCode` in `@cleocode/contracts`
|
|
129
|
+
* for a condition that is surfaced structurally on the handle.
|
|
130
|
+
*
|
|
131
|
+
* @task T11828
|
|
132
|
+
* @epic T11833
|
|
133
|
+
* @saga T11242
|
|
134
|
+
* @public
|
|
135
|
+
*/
|
|
136
|
+
export declare class ExodusAbortWriteUnsafeError extends Error {
|
|
137
|
+
/** Stable string error code for envelope `codeName` / log correlation. */
|
|
138
|
+
readonly codeName: "E_EXODUS_ABORT_WRITE_UNSAFE";
|
|
139
|
+
/** The structured abort detail carried by the handle. */
|
|
140
|
+
readonly detail: ExodusAbortDetail;
|
|
141
|
+
/** Remediation hint surfaced to the operator. */
|
|
142
|
+
readonly fix: string;
|
|
143
|
+
/**
|
|
144
|
+
* @param detail - The {@link ExodusAbortDetail} stamped on the handle.
|
|
145
|
+
*/
|
|
146
|
+
constructor(detail: ExodusAbortDetail);
|
|
147
|
+
}
|
|
148
|
+
/**
|
|
149
|
+
* Assert that a {@link DualScopeDbHandle} is safe to WRITE through.
|
|
150
|
+
*
|
|
151
|
+
* Call this at the head of a MUTATING code path (insert/update/delete) that holds
|
|
152
|
+
* a dual-scope handle. If the handle carries an {@link DualScopeDbHandle.exodusAbort}
|
|
153
|
+
* marker — i.e. the first-open auto-migration aborted and the consolidated DB is
|
|
154
|
+
* empty with legacy kept as source — this throws {@link ExodusAbortWriteUnsafeError}
|
|
155
|
+
* so the write is rejected with a non-zero signal rather than silently landing in
|
|
156
|
+
* a DB that does not hold the user's data.
|
|
157
|
+
*
|
|
158
|
+
* READ-only callers MUST NOT call this — they are expected to operate on the
|
|
159
|
+
* empty-but-consistent consolidated DB without error, exactly as before T11828.
|
|
160
|
+
*
|
|
161
|
+
* @param handle - The handle returned by {@link openDualScopeDb}.
|
|
162
|
+
* @throws {ExodusAbortWriteUnsafeError} When `handle.exodusAbort` is set.
|
|
163
|
+
*
|
|
164
|
+
* @example
|
|
165
|
+
* ```ts
|
|
166
|
+
* const h = await openDualScopeDb('project', cwd);
|
|
167
|
+
* assertWriteDurable(h); // throws if a prior exodus-on-open aborted
|
|
168
|
+
* await h.db.insert(table).values(row);
|
|
169
|
+
* ```
|
|
170
|
+
*
|
|
171
|
+
* @task T11828 (DHQ-059)
|
|
172
|
+
* @epic T11833
|
|
173
|
+
* @saga T11242
|
|
174
|
+
* @public
|
|
175
|
+
*/
|
|
176
|
+
export declare function assertWriteDurable(handle: DualScopeDbHandle): void;
|
|
104
177
|
/**
|
|
105
178
|
* Resolve the absolute path to the dual-scope `cleo.db` for the given scope.
|
|
106
179
|
*
|
|
@@ -198,6 +271,11 @@ import type { SQLiteTableWithColumns, TableConfig } from 'drizzle-orm/sqlite-cor
|
|
|
198
271
|
* Pass the column name as a hint for documentation purposes.
|
|
199
272
|
* @returns The number of rows actually inserted (0 or 1).
|
|
200
273
|
*
|
|
274
|
+
* Refuses the write (throws {@link ExodusAbortWriteUnsafeError}) when a prior
|
|
275
|
+
* exodus-on-open aborted in this process (T11828 · DHQ-059) — these helpers are
|
|
276
|
+
* the consolidated-schema MUTATION primitives, so the guard is write-only and
|
|
277
|
+
* never affects read paths.
|
|
278
|
+
*
|
|
201
279
|
* @example
|
|
202
280
|
* ```ts
|
|
203
281
|
* import { tasksTasksTable } from '@cleocode/core/store/schema/cleo-project';
|
|
@@ -205,6 +283,7 @@ import type { SQLiteTableWithColumns, TableConfig } from 'drizzle-orm/sqlite-cor
|
|
|
205
283
|
* ```
|
|
206
284
|
*
|
|
207
285
|
* @task T11513 (E4-T2)
|
|
286
|
+
* @task T11828 (write-side exodus-abort guard)
|
|
208
287
|
* @epic T11247 (E4)
|
|
209
288
|
* @saga T11242
|
|
210
289
|
*/
|
|
@@ -227,6 +306,9 @@ export declare function insertIdempotent<TTable extends SQLiteTableWithColumns<T
|
|
|
227
306
|
* in `row` are used as the update set.
|
|
228
307
|
* @returns The number of rows inserted or updated (always 1).
|
|
229
308
|
*
|
|
309
|
+
* Refuses the write (throws {@link ExodusAbortWriteUnsafeError}) when a prior
|
|
310
|
+
* exodus-on-open aborted in this process (T11828 · DHQ-059) — write-only guard.
|
|
311
|
+
*
|
|
230
312
|
* @example
|
|
231
313
|
* ```ts
|
|
232
314
|
* await upsertIdempotent(db, tasksTasksTable, updatedTask, 'idempotencyKey',
|
|
@@ -234,6 +316,7 @@ export declare function insertIdempotent<TTable extends SQLiteTableWithColumns<T
|
|
|
234
316
|
* ```
|
|
235
317
|
*
|
|
236
318
|
* @task T11513 (E4-T2)
|
|
319
|
+
* @task T11828 (write-side exodus-abort guard)
|
|
237
320
|
* @epic T11247 (E4)
|
|
238
321
|
* @saga T11242
|
|
239
322
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dual-scope-db.d.ts","sourceRoot":"","sources":["../../src/store/dual-scope-db.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;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B,CAAC,QAAQ,CAAC,CAAC,CAAC;AA2MxC;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,sBAAsB,CAAC,KAAK,CAAC,EAAE,SAAS,GAAG,IAAI,CAuB9D;AAID,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AACpD,OAAO,KAAK,EAAE,sBAAsB,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAEnF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAsB,gBAAgB,CAAC,MAAM,SAAS,sBAAsB,CAAC,WAAW,CAAC,EAEvF,EAAE,EAAE,kBAAkB,CAAC,GAAG,CAAC,EAC3B,KAAK,EAAE,MAAM,EACb,GAAG,EAAE,gBAAgB,CAAC,MAAM,CAAC,EAE7B,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC,MAAM,CAAC,CAIjB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAsB,gBAAgB,CAAC,MAAM,SAAS,sBAAsB,CAAC,WAAW,CAAC,EAEvF,EAAE,EAAE,kBAAkB,CAAC,GAAG,CAAC,EAC3B,KAAK,EAAE,MAAM,EACb,GAAG,EAAE,gBAAgB,CAAC,MAAM,CAAC;AAC7B,wEAAwE;AACxE,UAAU,EAAE,MAAM,EAElB,cAAc,EAAE,GAAG,EACnB,GAAG,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,MAAM,CAAC,CAAC,GACtC,OAAO,CAAC,MAAM,CAAC,CAajB"}
|
|
@@ -54,9 +54,105 @@ import { createRequire } from 'node:module';
|
|
|
54
54
|
import { dirname, join } from 'node:path';
|
|
55
55
|
import { getLogger } from '../logger.js';
|
|
56
56
|
import { getCleoHome, resolveCleoDir } from '../paths.js';
|
|
57
|
+
import { getRecordedExodusAbort } from './exodus/abort-events.js';
|
|
57
58
|
import { migrateWithRetry, reconcileJournal } from './migration-manager.js';
|
|
58
59
|
import { resolveCorePackageMigrationsFolder } from './resolve-migrations-folder.js';
|
|
59
60
|
import { applyPerfPragmas } from './sqlite-pragmas.js';
|
|
61
|
+
/**
|
|
62
|
+
* Thrown by {@link assertWriteDurable} when a MUTATING caller is about to write
|
|
63
|
+
* through a {@link DualScopeDbHandle} whose first-open exodus auto-migration
|
|
64
|
+
* ABORTED (T11828 · DHQ-059).
|
|
65
|
+
*
|
|
66
|
+
* The consolidated `cleo.db` is internally consistent but EMPTY: the user's real
|
|
67
|
+
* data is still in the legacy fleet (kept as the source of truth). Writing here
|
|
68
|
+
* would land in a DB that does not reflect that data, so the write is NOT durable
|
|
69
|
+
* against the source of truth. Read paths never raise this — they intentionally
|
|
70
|
+
* skip {@link assertWriteDurable} and operate on the empty-but-consistent DB.
|
|
71
|
+
*
|
|
72
|
+
* Self-contained (mirrors `BackupRecoverError`) rather than a `CleoError` subclass
|
|
73
|
+
* so the store layer does not need a new numeric `ExitCode` in `@cleocode/contracts`
|
|
74
|
+
* for a condition that is surfaced structurally on the handle.
|
|
75
|
+
*
|
|
76
|
+
* @task T11828
|
|
77
|
+
* @epic T11833
|
|
78
|
+
* @saga T11242
|
|
79
|
+
* @public
|
|
80
|
+
*/
|
|
81
|
+
export class ExodusAbortWriteUnsafeError extends Error {
|
|
82
|
+
/** Stable string error code for envelope `codeName` / log correlation. */
|
|
83
|
+
codeName = 'E_EXODUS_ABORT_WRITE_UNSAFE';
|
|
84
|
+
/** The structured abort detail carried by the handle. */
|
|
85
|
+
detail;
|
|
86
|
+
/** Remediation hint surfaced to the operator. */
|
|
87
|
+
fix;
|
|
88
|
+
/**
|
|
89
|
+
* @param detail - The {@link ExodusAbortDetail} stamped on the handle.
|
|
90
|
+
*/
|
|
91
|
+
constructor(detail) {
|
|
92
|
+
super(`Refusing to write to consolidated ${detail.scope} cleo.db — exodus-on-open ABORTED ` +
|
|
93
|
+
`(${detail.reason}). The DB is empty; legacy data is the source of truth. ` +
|
|
94
|
+
`Run \`cleo doctor exodus-health\` then \`cleo exodus migrate\` (or restore via ` +
|
|
95
|
+
`\`cleo doctor repair --role ${detail.scope === 'project' ? 'tasks' : 'nexus'}\`) before writing.`);
|
|
96
|
+
this.name = 'ExodusAbortWriteUnsafeError';
|
|
97
|
+
this.detail = detail;
|
|
98
|
+
this.fix =
|
|
99
|
+
'Resolve the aborted migration (`cleo doctor exodus-health` → `cleo exodus migrate`) ' +
|
|
100
|
+
'so the consolidated cleo.db carries your data before mutating it.';
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Assert that a {@link DualScopeDbHandle} is safe to WRITE through.
|
|
105
|
+
*
|
|
106
|
+
* Call this at the head of a MUTATING code path (insert/update/delete) that holds
|
|
107
|
+
* a dual-scope handle. If the handle carries an {@link DualScopeDbHandle.exodusAbort}
|
|
108
|
+
* marker — i.e. the first-open auto-migration aborted and the consolidated DB is
|
|
109
|
+
* empty with legacy kept as source — this throws {@link ExodusAbortWriteUnsafeError}
|
|
110
|
+
* so the write is rejected with a non-zero signal rather than silently landing in
|
|
111
|
+
* a DB that does not hold the user's data.
|
|
112
|
+
*
|
|
113
|
+
* READ-only callers MUST NOT call this — they are expected to operate on the
|
|
114
|
+
* empty-but-consistent consolidated DB without error, exactly as before T11828.
|
|
115
|
+
*
|
|
116
|
+
* @param handle - The handle returned by {@link openDualScopeDb}.
|
|
117
|
+
* @throws {ExodusAbortWriteUnsafeError} When `handle.exodusAbort` is set.
|
|
118
|
+
*
|
|
119
|
+
* @example
|
|
120
|
+
* ```ts
|
|
121
|
+
* const h = await openDualScopeDb('project', cwd);
|
|
122
|
+
* assertWriteDurable(h); // throws if a prior exodus-on-open aborted
|
|
123
|
+
* await h.db.insert(table).values(row);
|
|
124
|
+
* ```
|
|
125
|
+
*
|
|
126
|
+
* @task T11828 (DHQ-059)
|
|
127
|
+
* @epic T11833
|
|
128
|
+
* @saga T11242
|
|
129
|
+
* @public
|
|
130
|
+
*/
|
|
131
|
+
export function assertWriteDurable(handle) {
|
|
132
|
+
if (handle.exodusAbort) {
|
|
133
|
+
throw new ExodusAbortWriteUnsafeError(handle.exodusAbort);
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Throw {@link ExodusAbortWriteUnsafeError} when ANY exodus-on-open abort is
|
|
138
|
+
* recorded for this process (across either scope).
|
|
139
|
+
*
|
|
140
|
+
* Used by the consolidated-schema MUTATION primitives ({@link insertIdempotent} /
|
|
141
|
+
* {@link upsertIdempotent}) which do not receive the originating
|
|
142
|
+
* {@link DualScopeDbHandle} — they consult the process-local registry recorded by
|
|
143
|
+
* {@link emitExodusAbort} instead. Read paths never call these primitives, so the
|
|
144
|
+
* guard is write-only.
|
|
145
|
+
*
|
|
146
|
+
* @throws {ExodusAbortWriteUnsafeError} When a recorded abort exists.
|
|
147
|
+
* @internal
|
|
148
|
+
* @task T11828
|
|
149
|
+
*/
|
|
150
|
+
function assertNoRecordedExodusAbort() {
|
|
151
|
+
const detail = getRecordedExodusAbort();
|
|
152
|
+
if (detail) {
|
|
153
|
+
throw new ExodusAbortWriteUnsafeError(detail);
|
|
154
|
+
}
|
|
155
|
+
}
|
|
60
156
|
const _cache = new Map();
|
|
61
157
|
/**
|
|
62
158
|
* Build the singleton cache key for a given scope + resolved DB path.
|
|
@@ -315,14 +411,35 @@ exodusCwd, options) {
|
|
|
315
411
|
const { maybeRunExodusOnOpen } = await import('./exodus/on-open.js');
|
|
316
412
|
const result = await maybeRunExodusOnOpen(scope, dbPath, nativeDb, exodusCwd);
|
|
317
413
|
if (result.outcome === 'migrated' || result.outcome === 'aborted') {
|
|
318
|
-
if (result.outcome === 'aborted') {
|
|
319
|
-
log.warn({ scope, reason: result.reason }, 'exodus-on-open aborted; consolidated cleo.db left empty, legacy kept as source');
|
|
320
|
-
}
|
|
321
414
|
// The migrate engine closed our handle — re-open fresh (un-armed) so the
|
|
322
415
|
// caller receives a valid, live handle bound to the now-(de)populated DB.
|
|
323
|
-
|
|
324
|
-
? openDualScopeDbAtPath('project', dbPath)
|
|
325
|
-
: openDualScopeDbAtPath('global', dbPath);
|
|
416
|
+
const reopened = scope === 'project'
|
|
417
|
+
? await openDualScopeDbAtPath('project', dbPath)
|
|
418
|
+
: await openDualScopeDbAtPath('global', dbPath);
|
|
419
|
+
if (result.outcome === 'aborted') {
|
|
420
|
+
// T11828 (DHQ-059): the data-continuity gate aborted — the consolidated
|
|
421
|
+
// DB is empty + consistent, legacy kept as source. Surface this to a
|
|
422
|
+
// MUTATING caller (read-only callers ignore it) by (a) stamping a
|
|
423
|
+
// structured marker on the returned handle and (b) broadcasting a typed
|
|
424
|
+
// event. The non-zero error itself is raised on the write path via
|
|
425
|
+
// `assertWriteDurable(handle)` — NOT here, so read opens never throw.
|
|
426
|
+
const abort = {
|
|
427
|
+
scope,
|
|
428
|
+
dbPath,
|
|
429
|
+
reason: result.reason,
|
|
430
|
+
at: Date.now(),
|
|
431
|
+
};
|
|
432
|
+
log.warn({ scope, reason: result.reason }, 'exodus-on-open aborted; consolidated cleo.db left empty, legacy kept as source — ' +
|
|
433
|
+
'mutating callers must check handle.exodusAbort / call assertWriteDurable (T11828)');
|
|
434
|
+
const { emitExodusAbort } = await import('./exodus/abort-events.js');
|
|
435
|
+
emitExodusAbort(abort);
|
|
436
|
+
return { ...reopened, exodusAbort: abort };
|
|
437
|
+
}
|
|
438
|
+
// A subsequent SUCCESSFUL migration resolves any prior abort recorded
|
|
439
|
+
// for this scope, so writes are no longer rejected (T11828).
|
|
440
|
+
const { clearExodusAborts } = await import('./exodus/abort-events.js');
|
|
441
|
+
clearExodusAborts(scope);
|
|
442
|
+
return reopened;
|
|
326
443
|
}
|
|
327
444
|
}
|
|
328
445
|
catch (err) {
|
|
@@ -408,6 +525,11 @@ export function _resetDualScopeDbCache(scope) {
|
|
|
408
525
|
* Pass the column name as a hint for documentation purposes.
|
|
409
526
|
* @returns The number of rows actually inserted (0 or 1).
|
|
410
527
|
*
|
|
528
|
+
* Refuses the write (throws {@link ExodusAbortWriteUnsafeError}) when a prior
|
|
529
|
+
* exodus-on-open aborted in this process (T11828 · DHQ-059) — these helpers are
|
|
530
|
+
* the consolidated-schema MUTATION primitives, so the guard is write-only and
|
|
531
|
+
* never affects read paths.
|
|
532
|
+
*
|
|
411
533
|
* @example
|
|
412
534
|
* ```ts
|
|
413
535
|
* import { tasksTasksTable } from '@cleocode/core/store/schema/cleo-project';
|
|
@@ -415,6 +537,7 @@ export function _resetDualScopeDbCache(scope) {
|
|
|
415
537
|
* ```
|
|
416
538
|
*
|
|
417
539
|
* @task T11513 (E4-T2)
|
|
540
|
+
* @task T11828 (write-side exodus-abort guard)
|
|
418
541
|
* @epic T11247 (E4)
|
|
419
542
|
* @saga T11242
|
|
420
543
|
*/
|
|
@@ -423,6 +546,7 @@ export async function insertIdempotent(
|
|
|
423
546
|
db, table, row,
|
|
424
547
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
425
548
|
_keyColumn) {
|
|
549
|
+
assertNoRecordedExodusAbort();
|
|
426
550
|
const result = await db.insert(table).values(row).onConflictDoNothing().returning();
|
|
427
551
|
return result.length;
|
|
428
552
|
}
|
|
@@ -444,6 +568,9 @@ _keyColumn) {
|
|
|
444
568
|
* in `row` are used as the update set.
|
|
445
569
|
* @returns The number of rows inserted or updated (always 1).
|
|
446
570
|
*
|
|
571
|
+
* Refuses the write (throws {@link ExodusAbortWriteUnsafeError}) when a prior
|
|
572
|
+
* exodus-on-open aborted in this process (T11828 · DHQ-059) — write-only guard.
|
|
573
|
+
*
|
|
447
574
|
* @example
|
|
448
575
|
* ```ts
|
|
449
576
|
* await upsertIdempotent(db, tasksTasksTable, updatedTask, 'idempotencyKey',
|
|
@@ -451,6 +578,7 @@ _keyColumn) {
|
|
|
451
578
|
* ```
|
|
452
579
|
*
|
|
453
580
|
* @task T11513 (E4-T2)
|
|
581
|
+
* @task T11828 (write-side exodus-abort guard)
|
|
454
582
|
* @epic T11247 (E4)
|
|
455
583
|
* @saga T11242
|
|
456
584
|
*/
|
|
@@ -461,6 +589,7 @@ db, table, row,
|
|
|
461
589
|
_keyColumn,
|
|
462
590
|
// biome-ignore lint/suspicious/noExplicitAny: column reference type varies by table
|
|
463
591
|
conflictTarget, set) {
|
|
592
|
+
assertNoRecordedExodusAbort();
|
|
464
593
|
const updateSet = set ?? row;
|
|
465
594
|
const result = await db
|
|
466
595
|
.insert(table)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dual-scope-db.js","sourceRoot":"","sources":["../../src/store/dual-scope-db.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;AAEH,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAChD,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAG1C,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC1D,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC5E,OAAO,EAAE,kCAAkC,EAAE,MAAM,gCAAgC,CAAC;AAGpF,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAqEvD,MAAM,MAAM,GAAG,IAAI,GAAG,EAAwB,CAAC;AAE/C;;;GAGG;AACH,SAAS,QAAQ,CAAC,KAAgB,EAAE,MAAc;IAChD,OAAO,GAAG,KAAK,KAAK,MAAM,EAAE,CAAC;AAC/B,CAAC;AAED,gFAAgF;AAEhF;;;;;GAKG;AACH,MAAM,UAAU,sBAAsB,CAAC,KAAgB,EAAE,GAAY;IACnE,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;QACxB,OAAO,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,EAAE,SAAS,CAAC,C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,MAAM,CAAC,GAAG,CAAC,CAAC,mBAAmB,EAAE,CAAC,SAAS,EAAE,CAAC;IACpF,OAAO,MAAM,CAAC,MAAM,CAAC;AACvB,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,MAAM,CAAC,KAAK,UAAU,gBAAgB;AACpC,6FAA6F;AAC7F,EAA2B,EAC3B,KAAa,EACb,GAA6B;AAC7B,wEAAwE;AACxE,UAAkB;AAClB,oFAAoF;AACpF,cAAmB,EACnB,GAAuC;IAEvC,2BAA2B,EAAE,CAAC;IAC9B,MAAM,SAAS,GAAG,GAAG,IAAI,GAAG,CAAC;IAC7B,MAAM,MAAM,GAAG,MAAM,EAAE;SACpB,MAAM,CAAC,KAAK,CAAC;SACb,MAAM,CAAC,GAAG,CAAC;SACX,kBAAkB,CAAC;QAClB,MAAM,EAAE,cAAc;QACtB,uGAAuG;QACvG,GAAG,EAAE,SAAgB;KACtB,CAAC;SACD,SAAS,EAAE,CAAC;IACf,OAAO,MAAM,CAAC,MAAM,CAAC;AACvB,CAAC"}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Typed, process-local event channel for exodus-on-open ABORTS (T11828 · DHQ-059).
|
|
3
|
+
*
|
|
4
|
+
* ## Why this exists
|
|
5
|
+
*
|
|
6
|
+
* The exodus-on-open data-continuity gate ({@link maybeRunExodusOnOpen}) can
|
|
7
|
+
* ABORT a first-open auto-migration when the parity verify fails or the copy
|
|
8
|
+
* errors mid-flight. On abort the consolidated `cleo.db` is rolled back to EMPTY
|
|
9
|
+
* and the legacy fleet is kept as the source of truth — so the handle the
|
|
10
|
+
* chokepoint hands back is live and success-shaped, but the data the caller
|
|
11
|
+
* expected is NOT in it.
|
|
12
|
+
*
|
|
13
|
+
* Before T11828 that abort surfaced ONLY as a `log.warn(...)` inside the open
|
|
14
|
+
* chokepoint. A MUTATING caller (e.g. `tasks.add`) therefore had no programmatic
|
|
15
|
+
* signal that its write was about to land in a consolidated DB that does not
|
|
16
|
+
* contain the user's real data — i.e. the write may not be durable against the
|
|
17
|
+
* source of truth. This module is the out-of-band surface: every abort is
|
|
18
|
+
* broadcast here so daemon/session/diagnostic subscribers can react, AND the
|
|
19
|
+
* abort detail is stamped onto the returned {@link DualScopeDbHandle} so a
|
|
20
|
+
* mutation path can detect it synchronously via {@link assertWriteDurable}.
|
|
21
|
+
*
|
|
22
|
+
* Read-only callers ignore the marker entirely — they get a valid handle and the
|
|
23
|
+
* empty-but-consistent consolidated DB, exactly as before.
|
|
24
|
+
*
|
|
25
|
+
* @module
|
|
26
|
+
* @task T11828 (DHQ-059 — surface exodus-on-open abort to mutating callers)
|
|
27
|
+
* @epic T11833
|
|
28
|
+
* @saga T11242 (SG-DB-SUBSTRATE-V2)
|
|
29
|
+
* @see packages/core/src/store/exodus/on-open.ts — where the abort originates
|
|
30
|
+
* @see packages/core/src/store/dual-scope-db.ts — where the marker is stamped + assertWriteDurable
|
|
31
|
+
*/
|
|
32
|
+
import { EventEmitter } from 'node:events';
|
|
33
|
+
import type { DualScope } from '../dual-scope-db.js';
|
|
34
|
+
/**
|
|
35
|
+
* Structured detail of an exodus-on-open abort, stamped onto the returned
|
|
36
|
+
* {@link DualScopeDbHandle} and broadcast on the {@link exodusAbortEvents}
|
|
37
|
+
* channel.
|
|
38
|
+
*
|
|
39
|
+
* @task T11828
|
|
40
|
+
* @public
|
|
41
|
+
*/
|
|
42
|
+
export interface ExodusAbortDetail {
|
|
43
|
+
/** The scope whose first-open auto-migration aborted. */
|
|
44
|
+
readonly scope: DualScope;
|
|
45
|
+
/** Absolute path to the consolidated `cleo.db` for that scope. */
|
|
46
|
+
readonly dbPath: string;
|
|
47
|
+
/** Human-readable abort reason (parity deficit, mid-copy failure, …). */
|
|
48
|
+
readonly reason: string;
|
|
49
|
+
/** Epoch-ms timestamp the abort was observed. */
|
|
50
|
+
readonly at: number;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* Map of event name → listener argument tuple for the exodus-abort channel.
|
|
54
|
+
*
|
|
55
|
+
* @task T11828
|
|
56
|
+
*/
|
|
57
|
+
interface ExodusAbortEventMap {
|
|
58
|
+
/** Emitted once per exodus-on-open abort, after rollback completes. */
|
|
59
|
+
abort: [detail: ExodusAbortDetail];
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Process-local emitter broadcasting every exodus-on-open ABORT.
|
|
63
|
+
*
|
|
64
|
+
* Subscribers (daemon liveness, session lifecycle, `cleo doctor exodus-health`)
|
|
65
|
+
* MAY listen for `'abort'` to react to a degraded first-open without coupling to
|
|
66
|
+
* the store chokepoint. Emission is best-effort and never throws into the open
|
|
67
|
+
* path — listener errors are swallowed by {@link emitExodusAbort}.
|
|
68
|
+
*
|
|
69
|
+
* @task T11828
|
|
70
|
+
* @public
|
|
71
|
+
*/
|
|
72
|
+
export declare const exodusAbortEvents: EventEmitter<ExodusAbortEventMap>;
|
|
73
|
+
/**
|
|
74
|
+
* Broadcast an exodus-on-open abort on the {@link exodusAbortEvents} channel and
|
|
75
|
+
* record it in the process-local per-scope registry.
|
|
76
|
+
*
|
|
77
|
+
* Best-effort: a throwing/synchronous listener must NOT propagate into the DB
|
|
78
|
+
* open path, so emission is wrapped. Returns `true` if at least one listener was
|
|
79
|
+
* notified (matching `EventEmitter.emit` semantics) — informational only.
|
|
80
|
+
*
|
|
81
|
+
* @param detail - The structured abort detail to broadcast.
|
|
82
|
+
* @returns `true` when the event had listeners; `false` otherwise.
|
|
83
|
+
*
|
|
84
|
+
* @task T11828
|
|
85
|
+
* @public
|
|
86
|
+
*/
|
|
87
|
+
export declare function emitExodusAbort(detail: ExodusAbortDetail): boolean;
|
|
88
|
+
/**
|
|
89
|
+
* Return the recorded abort detail for `scope`, or — when `scope` is omitted —
|
|
90
|
+
* the most-recent abort across any scope. `undefined` when no abort is recorded.
|
|
91
|
+
*
|
|
92
|
+
* Used by the write-side guard to reject a mutation that would land in a
|
|
93
|
+
* consolidated DB the exodus-on-open gate left empty.
|
|
94
|
+
*
|
|
95
|
+
* @param scope - Optional scope filter; when omitted, returns any recorded abort.
|
|
96
|
+
* @returns The {@link ExodusAbortDetail}, or `undefined`.
|
|
97
|
+
*
|
|
98
|
+
* @task T11828
|
|
99
|
+
* @public
|
|
100
|
+
*/
|
|
101
|
+
export declare function getRecordedExodusAbort(scope?: DualScope): ExodusAbortDetail | undefined;
|
|
102
|
+
/**
|
|
103
|
+
* Clear recorded aborts — all scopes, or a single `scope`.
|
|
104
|
+
*
|
|
105
|
+
* Call after the aborted migration is resolved (a subsequent successful
|
|
106
|
+
* `cleo exodus migrate` / `cleo doctor repair`) so writes are no longer rejected,
|
|
107
|
+
* and in test teardown to isolate cases.
|
|
108
|
+
*
|
|
109
|
+
* @param scope - Optional scope to clear; when omitted, clears every scope.
|
|
110
|
+
*
|
|
111
|
+
* @task T11828
|
|
112
|
+
* @public
|
|
113
|
+
*/
|
|
114
|
+
export declare function clearExodusAborts(scope?: DualScope): void;
|
|
115
|
+
export {};
|
|
116
|
+
//# sourceMappingURL=abort-events.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"abort-events.d.ts","sourceRoot":"","sources":["../../../src/store/exodus/abort-events.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAErD;;;;;;;GAOG;AACH,MAAM,WAAW,iBAAiB;IAChC,yDAAyD;IACzD,QAAQ,CAAC,KAAK,EAAE,SAAS,CAAC;IAC1B,kEAAkE;IAClE,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,yEAAyE;IACzE,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,iDAAiD;IACjD,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;CACrB;AAED;;;;GAIG;AACH,UAAU,mBAAmB;IAC3B,uEAAuE;IACvE,KAAK,EAAE,CAAC,MAAM,EAAE,iBAAiB,CAAC,CAAC;CACpC;AAED;;;;;;;;;;GAUG;AACH,eAAO,MAAM,iBAAiB,mCAA0C,CAAC;AAsBzE;;;;;;;;;;;;;GAaG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAAE,iBAAiB,GAAG,OAAO,CAQlE;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,sBAAsB,CAAC,KAAK,CAAC,EAAE,SAAS,GAAG,iBAAiB,GAAG,SAAS,CAQvF;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,CAAC,EAAE,SAAS,GAAG,IAAI,CAMzD"}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Typed, process-local event channel for exodus-on-open ABORTS (T11828 · DHQ-059).
|
|
3
|
+
*
|
|
4
|
+
* ## Why this exists
|
|
5
|
+
*
|
|
6
|
+
* The exodus-on-open data-continuity gate ({@link maybeRunExodusOnOpen}) can
|
|
7
|
+
* ABORT a first-open auto-migration when the parity verify fails or the copy
|
|
8
|
+
* errors mid-flight. On abort the consolidated `cleo.db` is rolled back to EMPTY
|
|
9
|
+
* and the legacy fleet is kept as the source of truth — so the handle the
|
|
10
|
+
* chokepoint hands back is live and success-shaped, but the data the caller
|
|
11
|
+
* expected is NOT in it.
|
|
12
|
+
*
|
|
13
|
+
* Before T11828 that abort surfaced ONLY as a `log.warn(...)` inside the open
|
|
14
|
+
* chokepoint. A MUTATING caller (e.g. `tasks.add`) therefore had no programmatic
|
|
15
|
+
* signal that its write was about to land in a consolidated DB that does not
|
|
16
|
+
* contain the user's real data — i.e. the write may not be durable against the
|
|
17
|
+
* source of truth. This module is the out-of-band surface: every abort is
|
|
18
|
+
* broadcast here so daemon/session/diagnostic subscribers can react, AND the
|
|
19
|
+
* abort detail is stamped onto the returned {@link DualScopeDbHandle} so a
|
|
20
|
+
* mutation path can detect it synchronously via {@link assertWriteDurable}.
|
|
21
|
+
*
|
|
22
|
+
* Read-only callers ignore the marker entirely — they get a valid handle and the
|
|
23
|
+
* empty-but-consistent consolidated DB, exactly as before.
|
|
24
|
+
*
|
|
25
|
+
* @module
|
|
26
|
+
* @task T11828 (DHQ-059 — surface exodus-on-open abort to mutating callers)
|
|
27
|
+
* @epic T11833
|
|
28
|
+
* @saga T11242 (SG-DB-SUBSTRATE-V2)
|
|
29
|
+
* @see packages/core/src/store/exodus/on-open.ts — where the abort originates
|
|
30
|
+
* @see packages/core/src/store/dual-scope-db.ts — where the marker is stamped + assertWriteDurable
|
|
31
|
+
*/
|
|
32
|
+
import { EventEmitter } from 'node:events';
|
|
33
|
+
/**
|
|
34
|
+
* Process-local emitter broadcasting every exodus-on-open ABORT.
|
|
35
|
+
*
|
|
36
|
+
* Subscribers (daemon liveness, session lifecycle, `cleo doctor exodus-health`)
|
|
37
|
+
* MAY listen for `'abort'` to react to a degraded first-open without coupling to
|
|
38
|
+
* the store chokepoint. Emission is best-effort and never throws into the open
|
|
39
|
+
* path — listener errors are swallowed by {@link emitExodusAbort}.
|
|
40
|
+
*
|
|
41
|
+
* @task T11828
|
|
42
|
+
* @public
|
|
43
|
+
*/
|
|
44
|
+
export const exodusAbortEvents = new EventEmitter();
|
|
45
|
+
// An aborted first-open install can legitimately have many domain opens fire in
|
|
46
|
+
// one process (tasks, brain, conduit, …); each would re-broadcast. Raise the cap
|
|
47
|
+
// modestly above the default 10 so a busy session does not emit a spurious
|
|
48
|
+
// MaxListenersExceededWarning, while still flagging a genuine listener leak.
|
|
49
|
+
exodusAbortEvents.setMaxListeners(50);
|
|
50
|
+
/**
|
|
51
|
+
/**
|
|
52
|
+
* Process-local registry of the most recent abort detail per scope.
|
|
53
|
+
*
|
|
54
|
+
* Recorded on every {@link emitExodusAbort} so the write-side guard
|
|
55
|
+
* (`assertWriteDurable` via {@link insertIdempotent} / {@link upsertIdempotent})
|
|
56
|
+
* can detect a degraded first-open even when the caller no longer holds the
|
|
57
|
+
* original {@link DualScopeDbHandle} (e.g. domain modules that extract the native
|
|
58
|
+
* handle and discard the wrapper). Cleared by {@link clearExodusAborts} once the
|
|
59
|
+
* underlying migration is resolved (successful `cleo exodus migrate` / recovery)
|
|
60
|
+
* or in test teardown.
|
|
61
|
+
*/
|
|
62
|
+
const _abortedScopes = new Map();
|
|
63
|
+
/**
|
|
64
|
+
* Broadcast an exodus-on-open abort on the {@link exodusAbortEvents} channel and
|
|
65
|
+
* record it in the process-local per-scope registry.
|
|
66
|
+
*
|
|
67
|
+
* Best-effort: a throwing/synchronous listener must NOT propagate into the DB
|
|
68
|
+
* open path, so emission is wrapped. Returns `true` if at least one listener was
|
|
69
|
+
* notified (matching `EventEmitter.emit` semantics) — informational only.
|
|
70
|
+
*
|
|
71
|
+
* @param detail - The structured abort detail to broadcast.
|
|
72
|
+
* @returns `true` when the event had listeners; `false` otherwise.
|
|
73
|
+
*
|
|
74
|
+
* @task T11828
|
|
75
|
+
* @public
|
|
76
|
+
*/
|
|
77
|
+
export function emitExodusAbort(detail) {
|
|
78
|
+
_abortedScopes.set(detail.scope, detail);
|
|
79
|
+
try {
|
|
80
|
+
return exodusAbortEvents.emit('abort', detail);
|
|
81
|
+
}
|
|
82
|
+
catch {
|
|
83
|
+
// A misbehaving listener must never break the open path.
|
|
84
|
+
return false;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Return the recorded abort detail for `scope`, or — when `scope` is omitted —
|
|
89
|
+
* the most-recent abort across any scope. `undefined` when no abort is recorded.
|
|
90
|
+
*
|
|
91
|
+
* Used by the write-side guard to reject a mutation that would land in a
|
|
92
|
+
* consolidated DB the exodus-on-open gate left empty.
|
|
93
|
+
*
|
|
94
|
+
* @param scope - Optional scope filter; when omitted, returns any recorded abort.
|
|
95
|
+
* @returns The {@link ExodusAbortDetail}, or `undefined`.
|
|
96
|
+
*
|
|
97
|
+
* @task T11828
|
|
98
|
+
* @public
|
|
99
|
+
*/
|
|
100
|
+
export function getRecordedExodusAbort(scope) {
|
|
101
|
+
if (scope !== undefined)
|
|
102
|
+
return _abortedScopes.get(scope);
|
|
103
|
+
// Most-recent across scopes (Map preserves insertion order; emit overwrites).
|
|
104
|
+
let latest;
|
|
105
|
+
for (const detail of _abortedScopes.values()) {
|
|
106
|
+
if (!latest || detail.at >= latest.at)
|
|
107
|
+
latest = detail;
|
|
108
|
+
}
|
|
109
|
+
return latest;
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* Clear recorded aborts — all scopes, or a single `scope`.
|
|
113
|
+
*
|
|
114
|
+
* Call after the aborted migration is resolved (a subsequent successful
|
|
115
|
+
* `cleo exodus migrate` / `cleo doctor repair`) so writes are no longer rejected,
|
|
116
|
+
* and in test teardown to isolate cases.
|
|
117
|
+
*
|
|
118
|
+
* @param scope - Optional scope to clear; when omitted, clears every scope.
|
|
119
|
+
*
|
|
120
|
+
* @task T11828
|
|
121
|
+
* @public
|
|
122
|
+
*/
|
|
123
|
+
export function clearExodusAborts(scope) {
|
|
124
|
+
if (scope !== undefined) {
|
|
125
|
+
_abortedScopes.delete(scope);
|
|
126
|
+
return;
|
|
127
|
+
}
|
|
128
|
+
_abortedScopes.clear();
|
|
129
|
+
}
|
|
130
|
+
//# sourceMappingURL=abort-events.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"abort-events.js","sourceRoot":"","sources":["../../../src/store/exodus/abort-events.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAgC3C;;;;;;;;;;GAUG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,IAAI,YAAY,EAAuB,CAAC;AAEzE,gFAAgF;AAChF,iFAAiF;AACjF,2EAA2E;AAC3E,6EAA6E;AAC7E,iBAAiB,CAAC,eAAe,CAAC,EAAE,CAAC,CAAC;AAEtC;;;;;;;;;;;GAWG;AACH,MAAM,cAAc,GAAG,IAAI,GAAG,EAAgC,CAAC;AAE/D;;;;;;;;;;;;;GAaG;AACH,MAAM,UAAU,eAAe,CAAC,MAAyB;IACvD,cAAc,CAAC,GAAG,CAAC,MAAM,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;IACzC,IAAI,CAAC;QACH,OAAO,iBAAiB,CAAC,IAAI,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC;IACjD,CAAC;IAAC,MAAM,CAAC;QACP,yDAAyD;QACzD,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,sBAAsB,CAAC,KAAiB;IACtD,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO,cAAc,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IAC1D,8EAA8E;IAC9E,IAAI,MAAqC,CAAC;IAC1C,KAAK,MAAM,MAAM,IAAI,cAAc,CAAC,MAAM,EAAE,EAAE,CAAC;QAC7C,IAAI,CAAC,MAAM,IAAI,MAAM,CAAC,EAAE,IAAI,MAAM,CAAC,EAAE;YAAE,MAAM,GAAG,MAAM,CAAC;IACzD,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC;AAED;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,iBAAiB,CAAC,KAAiB;IACjD,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;QACxB,cAAc,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;QAC7B,OAAO;IACT,CAAC;IACD,cAAc,CAAC,KAAK,EAAE,CAAC;AACzB,CAAC"}
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
* @task T11248 (E5 · SG-DB-SUBSTRATE-V2)
|
|
9
9
|
* @saga T11242
|
|
10
10
|
*/
|
|
11
|
+
export { clearExodusAborts, type ExodusAbortDetail, emitExodusAbort, exodusAbortEvents, getRecordedExodusAbort, } from './abort-events.js';
|
|
11
12
|
export { type ArchivedSourceResult, type ArchiveMigratedSourcesResult, archiveMigratedSources, archiveSourceDb, archiveStrandedResidue, detectStrandedResidue, type ExodusCompleteMarker, exodusArchiveDir, exodusMarkerPath, hasExodusCompleteMarker, type StrandedResidueEntry, writeExodusCompleteMarker, } from './archive.js';
|
|
12
13
|
export { type CountParityEntry, type CountParityResult, computeCountParity, } from './count-parity.js';
|
|
13
14
|
export { buildExodusHealth, type ExodusHealth, type ExodusScopeHealth, type ExodusScopeState, type ExodusSourceHealth, } from './health.js';
|