@cleocode/core 2026.10.20 → 2026.10.21-rc.ci.692

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.
Files changed (57) hide show
  1. package/dist/build-provenance.json +2 -2
  2. package/dist/cloud/http.d.ts +10 -0
  3. package/dist/cloud/http.d.ts.map +1 -1
  4. package/dist/cloud/http.js +8 -0
  5. package/dist/cloud/http.js.map +1 -1
  6. package/dist/cloud/nexus-vault.d.ts +20 -0
  7. package/dist/cloud/nexus-vault.d.ts.map +1 -1
  8. package/dist/cloud/nexus-vault.js +100 -15
  9. package/dist/cloud/nexus-vault.js.map +1 -1
  10. package/dist/docs/docs-ops.d.ts.map +1 -1
  11. package/dist/docs/docs-ops.js +7 -3
  12. package/dist/docs/docs-ops.js.map +1 -1
  13. package/dist/resources/admission-ledger.d.ts +1 -1
  14. package/dist/resources/admission-ledger.d.ts.map +1 -1
  15. package/dist/resources/admission-ledger.js +246 -104
  16. package/dist/resources/admission-ledger.js.map +1 -1
  17. package/dist/resources/run-governed.d.ts.map +1 -1
  18. package/dist/resources/run-governed.js +108 -25
  19. package/dist/resources/run-governed.js.map +1 -1
  20. package/dist/store/backup-recover.d.ts.map +1 -1
  21. package/dist/store/backup-recover.js +9 -7
  22. package/dist/store/backup-recover.js.map +1 -1
  23. package/dist/store/backup-verify.d.ts.map +1 -1
  24. package/dist/store/backup-verify.js +5 -2
  25. package/dist/store/backup-verify.js.map +1 -1
  26. package/dist/store/recover-brain-db.d.ts.map +1 -1
  27. package/dist/store/recover-brain-db.js +4 -2
  28. package/dist/store/recover-brain-db.js.map +1 -1
  29. package/dist/store/recover-malformed-db.d.ts +10 -0
  30. package/dist/store/recover-malformed-db.d.ts.map +1 -1
  31. package/dist/store/recover-malformed-db.js +16 -2
  32. package/dist/store/recover-malformed-db.js.map +1 -1
  33. package/dist/store/row-identity-registry.d.ts.map +1 -1
  34. package/dist/store/row-identity-registry.js +4 -8
  35. package/dist/store/row-identity-registry.js.map +1 -1
  36. package/dist/store/sqlite-backup.d.ts +4 -1
  37. package/dist/store/sqlite-backup.d.ts.map +1 -1
  38. package/dist/store/sqlite-backup.js +96 -72
  39. package/dist/store/sqlite-backup.js.map +1 -1
  40. package/dist/store/sync/apply/applier.d.ts.map +1 -1
  41. package/dist/store/sync/apply/applier.js +4 -0
  42. package/dist/store/sync/apply/applier.js.map +1 -1
  43. package/dist/store/sync/apply/frame.d.ts +7 -3
  44. package/dist/store/sync/apply/frame.d.ts.map +1 -1
  45. package/dist/store/sync/apply/frame.js +41 -2
  46. package/dist/store/sync/apply/frame.js.map +1 -1
  47. package/dist/system/backup.d.ts +3 -2
  48. package/dist/system/backup.d.ts.map +1 -1
  49. package/dist/system/backup.js +3 -2
  50. package/dist/system/backup.js.map +1 -1
  51. package/dist/tasks/affected-packages.d.ts.map +1 -1
  52. package/dist/tasks/affected-packages.js +1 -2
  53. package/dist/tasks/affected-packages.js.map +1 -1
  54. package/dist/tasks/gate-runner.d.ts.map +1 -1
  55. package/dist/tasks/gate-runner.js +41 -0
  56. package/dist/tasks/gate-runner.js.map +1 -1
  57. package/package.json +13 -13
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "schema": 1,
3
- "gitHead": "61df8623708aa137827194be3bfb5decfbf27913",
4
- "builtAt": "2026-10-18T03:59:18.365Z",
3
+ "gitHead": "11de064096d9a7ef470818c8c9b7bcb83a29b343",
4
+ "builtAt": "2026-10-22T16:43:46.631Z",
5
5
  "linkedWorktree": null
6
6
  }
@@ -36,6 +36,16 @@ export interface HttpOptions {
36
36
  export declare const MAX_RETRY_AFTER_MS = 30000;
37
37
  /** True for https URLs, and for http URLs on a loopback host. */
38
38
  export declare function isSecureUrl(url: string): boolean;
39
+ /**
40
+ * The header saying this client reads journal (checkpoint/v3) streams (T13867).
41
+ * Cleo Nexus refuses a v3 stream's checkpoint and head reads to a request
42
+ * without it (T13876): such a client reads only snapshots and would report a
43
+ * stale store as current. Released v2026.10.19 does not send it.
44
+ */
45
+ export declare const NEXUS_STREAM_READER_HEADER: {
46
+ readonly name: "x-cleo-stream-reader";
47
+ readonly value: "3";
48
+ };
39
49
  /**
40
50
  * Minimal envelope-aware HTTP client. It retries only failures that are safe to retry. Every API
41
51
  * write is idempotent or lineage-checked, so a retried write either no-ops or is refused explicitly.
@@ -1 +1 @@
1
- {"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../src/cloud/http.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAE3D;;;;GAIG;AACH,MAAM,MAAM,eAAe,GAAG,SAAS,GAAG,WAAW,GAAG,YAAY,CAAC;AAErE,qBAAa,UAAW,SAAQ,KAAK;IAKjC,QAAQ,CAAC,IAAI,EAAE,eAAe;IAE9B,QAAQ,CAAC,MAAM,EAAE,MAAM;IACvB,QAAQ,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI;IACjC,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAR5C,0FAA0F;IAC1F,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;gBAGpB,IAAI,EAAE,eAAe,EAC9B,OAAO,EAAE,MAAM,EACN,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,GAAG,IAAI,EACxB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,YAAA;CAM7C;AAED,MAAM,MAAM,SAAS,GAAG,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAC;AAEjF,kGAAkG;AAClG,MAAM,WAAW,cAAc,CAAC,CAAC;IAC/B,SAAS,CAAC,IAAI,EAAE,OAAO,GAAG;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,IAAI,CAAC,EAAE,CAAC,CAAA;KAAE,CAAC;CAC1D;AAED,MAAM,WAAW,WAAW;IAC1B,uEAAuE;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M,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CACvC;AAID,iGAAiG;AACjG,eAAO,MAAM,kBAAkB,QAAS,CAAC;AAIzC,iEAAiE;AACjE,wBAAgB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAOhD;AAED;;;;;GAKG;AACH,eAAO,MAAM,0BAA0B;;;CAAwD,CAAC;AAEhG;;;;GAIG;AACH,qBAAa,IAAI;IAYH,OAAO,CAAC,QAAQ,CAAC,CAAC;IAX9B,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAY;IAClC,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAgC;IACtD;;;;;;OAMG;IACH,kBAAkB,EAAE,MAAM,GAAG,IAAI,CAAQ;gBAEZ,CAAC,EAAE,WAAW;IAa3C,kHAAkH;IAC5G,OAAO,CAAC,CAAC,EACb,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,cAAc,CAAC,CAAC,CAAC,EACzB,IAAI,CAAC,EAAE,OAAO,GACb,OAAO,CAAC,CAAC,CAAC;IAIb;;;OAGG;IACG,iBAAiB,CAAC,CAAC,EACvB,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,cAAc,CAAC,CAAC,CAAC,EACzB,IAAI,CAAC,EAAE,OAAO,GACb,OAAO,CAAC;QAAE,IAAI,EAAE,CAAC,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC;CA6DxC;AAED,qGAAqG;AACrG,wBAAgB,UAAU,CAAC,UAAU,EAAE,MAAM,GAAG,IAAI,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAM7E"}
@@ -29,6 +29,13 @@ export function isSecureUrl(url) {
29
29
  return false;
30
30
  }
31
31
  }
32
+ /**
33
+ * The header saying this client reads journal (checkpoint/v3) streams (T13867).
34
+ * Cleo Nexus refuses a v3 stream's checkpoint and head reads to a request
35
+ * without it (T13876): such a client reads only snapshots and would report a
36
+ * stale store as current. Released v2026.10.19 does not send it.
37
+ */
38
+ export const NEXUS_STREAM_READER_HEADER = { name: 'x-cleo-stream-reader', value: '3' };
32
39
  /**
33
40
  * Minimal envelope-aware HTTP client. It retries only failures that are safe to retry. Every API
34
41
  * write is idempotent or lineage-checked, so a retried write either no-ops or is refused explicitly.
@@ -71,6 +78,7 @@ export class Http {
71
78
  const headers = { authorization: `Bearer ${this.o.token}` };
72
79
  if (this.o.deviceId)
73
80
  headers['x-cleo-device-id'] = this.o.deviceId;
81
+ headers[NEXUS_STREAM_READER_HEADER.name] = NEXUS_STREAM_READER_HEADER.value;
74
82
  if (body !== undefined)
75
83
  headers['content-type'] = 'application/json';
76
84
  res = await this.fetch(`${this.o.baseUrl}${path}`, {
@@ -1 +1 @@
1
- {"version":3,"file":"http.js","sourceRoot":"","sources":["../../src/cloud/http.ts"],"names":[],"mappings":"AASA,MAAM,OAAO,UAAW,SAAQ,KAAK;IAKxB;IAEA;IACA;IACA;IARX,0FAA0F;IACjF,aAAa,CAAS;IAE/B,YACW,IAAqB,EAC9B,OAAe,EACN,MAAc,EACd,SAAwB,EACxB,OAAiC;QAE1C,KAAK,CAAC,GAAG,IAAI,KAAK,OAAO,GAAG,SAAS,CAAC,CAAC,CAAC,aAAa,SAAS,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;QANjE,SAAI,GAAJ,IAAI,CAAiB;QAErB,WAAM,GAAN,MAAM,CAAQ;QACd,cAAS,GAAT,SAAS,CAAe;QACxB,YAAO,GAAP,OAAO,CAA0B;QAG1C,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;QACzB,IAAI,CAAC,aAAa,GAAG,OAAO,CAAC;IAC/B,CAAC;CACF;AAoBD,MAAM,SAAS,GAAG,IAAI,GAAG,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC,CAAC;AAErD,iGAAiG;AACjG,MAAM,CAAC,MAAM,kBAAk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C,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC;QACxE,CAAC;QACD,MAAM,OAAO,IAAI,IAAI,UAAU,CAAC,WAAW,EAAE,gBAAgB,EAAE,CAAC,EAAE,IAAI,CAAC,CAAC;IAC1E,CAAC;CACF;AAED,qGAAqG;AACrG,MAAM,UAAU,UAAU,CAAC,UAAyB,EAAE,OAAe;IACnE,MAAM,OAAO,GAAG,MAAM,CAAC,UAAU,CAAC,CAAC;IACnC,IAAI,UAAU,KAAK,IAAI,IAAI,UAAU,CAAC,IAAI,EAAE,KAAK,EAAE,IAAI,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,IAAI,OAAO,GAAG,CAAC,EAAE,CAAC;QAC/F,OAAO,IAAI,CAAC,GAAG,CAAC,kBAAkB,EAAE,OAAO,GAAG,IAAI,CAAC,CAAC;IACtD,CAAC;IACD,OAAO,OAAO,CAAC,OAAO,CAAC,CAAC;AAC1B,CAAC;AAED,MAAM,OAAO,GAAG,CAAC,OAAe,EAAE,EAAE,CAClC,IAAI,CAAC,GAAG,CAAC,KAAK,EAAE,GAAG,GAAG,CAAC,IAAI,CAAC,OAAO,GAAG,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,GAAG,CAAC,CAAC"}
@@ -100,6 +100,26 @@ export interface NexusVaultCommandOptions extends NexusVaultOptions {
100
100
  /** `project` (the current project, default) or `global` (this account's global store). */
101
101
  scope?: CloudVaultScope;
102
102
  }
103
+ /**
104
+ * What works on a stream the change journal writes (its head snapshot is
105
+ * checkpoint/v3), for every message that would otherwise say "push" (T13034).
106
+ * A build where `sync.push` is unreleased cannot join the journal, since `cleo sync enable push`
107
+ * refuses there (T13851). While it is unreleased no released CLEO ships it either, so the remedy
108
+ * never sends the user to `cleo self-update`: a pre-release or allowUnreleased build started the
109
+ * journal, and pull, restore and verify keep working (T13856).
110
+ *
111
+ * @param pushReleased - Whether this build ships `sync.push`; defaults to the release state.
112
+ * @returns The remedy clause, naming only commands this build can run.
113
+ */
114
+ export declare function journalStreamRemedy(pushReleased?: boolean): string;
115
+ /**
116
+ * The fix for E_SYNC_DISABLED: turn the journal on where this build can, and otherwise say that no
117
+ * released CLEO can yet (T13856), never naming `cleo sync enable push` where it refuses.
118
+ *
119
+ * @param pushReleased - Whether this build ships `sync.push`; defaults to the release state.
120
+ * @returns The fix text.
121
+ */
122
+ export declare function syncDisabledRemedy(pushReleased?: boolean): string;
103
123
  /**
104
124
  * The rows a parent hashed under an older vault format counted that this
105
125
  * format leaves out (T13808): rows local by row-identity spec. They never
@@ -1 +1 @@
1
- {"version":3,"file":"nexus-vault.d.ts","sourceRoot":"","sources":["../../src/cloud/nexus-vault.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AAQH,OAAO,KAAK,EACV,uBAAuB,EACvB,eAAe,EACf,kBAAkB,EAClB,yBAAyB,EACzB,eAAe,EAGf,eAAe,EAEf,sBAAsB,EAGtB,iBAAiB,EAGlB,MAAM,qBAAqB,CAAC;AAsD7B,OAAO,EACL,KAAK,gBAAgB,EAMtB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAoB,KAAK,gBAAgB,EAAc,MAAM,uBAAuB,CAAC;AAgB5F,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAoChE,OAAO,EACL,KAAK,cAAc,EAKpB,MAAM,sBAAsB,CAAC;AAa9B,OAAO,EAGL,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,EAIvB,MAAM,uBAAuB,CAAC;AAK/B,gGAAgG;AAChG,eAAO,MAAM,6BAA6B,MAAM,CAAC;AAMjD;;;;;;;;GAQG;AACH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;CA6B1B,CAAC;AAkCX,4CAA4C;AAC5C,MAAM,WAAW,wB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pC,IAAI,GAAE,wBAA6B,GAClC,OAAO,CAAC,uBAAuB,CAAC,CAElC"}
@@ -371,8 +371,61 @@ async function replaySegments(journal, cursor, signers) {
371
371
  /**
372
372
  * What works on a stream the change journal writes (its head snapshot is
373
373
  * checkpoint/v3), for every message that would otherwise say "push" (T13034).
374
+ * A build where `sync.push` is unreleased cannot join the journal, since `cleo sync enable push`
375
+ * refuses there (T13851). While it is unreleased no released CLEO ships it either, so the remedy
376
+ * never sends the user to `cleo self-update`: a pre-release or allowUnreleased build started the
377
+ * journal, and pull, restore and verify keep working (T13856).
378
+ *
379
+ * @param pushReleased - Whether this build ships `sync.push`; defaults to the release state.
380
+ * @returns The remedy clause, naming only commands this build can run.
374
381
  */
375
- const JOURNAL_STREAM_REMEDY = 'on this stream local changes travel through the change journal (`sync.push`), and with it on a vault push checkpoints the journal (T12999); a store that has not joined it joins with `cleo sync enable push`, which keeps its own rows and merges them into the stream (T13466); `cleo cloud pull`, `cleo cloud restore` and `cleo cloud verify` still work';
382
+ export function journalStreamRemedy(pushReleased = !UNRELEASED_FLAGS.has('sync.push')) {
383
+ if (pushReleased) {
384
+ return 'on this stream local changes travel through the change journal (`sync.push`), and with it on a vault push checkpoints the journal (T12999); a store that has not joined it joins with `cleo sync enable push`, which keeps its own rows and merges them into the stream (T13466); `cleo cloud pull`, `cleo cloud restore` and `cleo cloud verify` still work';
385
+ }
386
+ return `on this stream local changes travel through the change journal (\`sync.push\`), which checkpoints the stream (T12999) and which this CLEO cannot run: ${SYNC_PUSH_UNRELEASED_CLAUSE}; \`cleo cloud pull\`, \`cleo cloud restore\` and \`cleo cloud verify\` keep working`;
387
+ }
388
+ /** Why no CLEO can push while `sync.push` is unreleased (T13856): no release ships it yet. */
389
+ const SYNC_PUSH_UNRELEASED_CLAUSE = '`sync.push` is not released yet, so a pre-release or allowUnreleased CLEO build started this journal and no released CLEO can push to it yet (T13856)';
390
+ /**
391
+ * The fix for E_SYNC_DISABLED: turn the journal on where this build can, and otherwise say that no
392
+ * released CLEO can yet (T13856), never naming `cleo sync enable push` where it refuses.
393
+ *
394
+ * @param pushReleased - Whether this build ships `sync.push`; defaults to the release state.
395
+ * @returns The fix text.
396
+ */
397
+ export function syncDisabledRemedy(pushReleased = !UNRELEASED_FLAGS.has('sync.push')) {
398
+ if (pushReleased)
399
+ return 'turn the change journal on first: `cleo sync enable push`';
400
+ return `the change journal is off here and this CLEO cannot turn it on: ${SYNC_PUSH_UNRELEASED_CLAUSE}; \`cleo cloud pull\`, \`cleo cloud restore\` and \`cleo cloud verify\` keep working`;
401
+ }
402
+ /** What a store that reads only snapshots does about journal changes past the head (T13867). */
403
+ const JOURNAL_UNREAD_REMEDY = 'join the change journal with `cleo sync enable push` to receive them, or run `cleo cloud push` on a device that writes the journal (its push checkpoints the journal, T12999), then pull again';
404
+ /**
405
+ * The change-journal segments past a checkpoint/v3 head that this store does
406
+ * not hold (T13867): it reads snapshots only, so the head is all it has, and
407
+ * every segment past the head's `coversSeq` is missing from it. A store is on
408
+ * the journal when it holds a genesis cut of the stream AND `sync.push` or
409
+ * `sync.pull` is on: a cut alone, as a restored bundle could carry, does not
410
+ * make it one. 0 for any other head, or a store on the journal.
411
+ */
412
+ async function journalUnread(t, headSeq, headCp) {
413
+ if (!headCp || !isJournalSnapshot(headCp) || headSeq <= headCp.coversSeq)
414
+ return 0;
415
+ if (fs.existsSync(t.dbPath)) {
416
+ const { openNativeDatabase } = await import('../store/sqlite-native.js');
417
+ const db = openNativeDatabase(t.dbPath, { readonly: true, enableWal: false });
418
+ try {
419
+ const on = isSyncFlagOn(db, 'sync.push') || isSyncFlagOn(db, 'sync.pull');
420
+ if (on && genesisCutOf(db, t.streamId) !== undefined)
421
+ return 0;
422
+ }
423
+ finally {
424
+ db.close();
425
+ }
426
+ }
427
+ return headSeq - headCp.coversSeq;
428
+ }
376
429
  /** Whether a snapshot is checkpoint/v3: the change journal writes its stream (T13034). */
377
430
  function isJournalSnapshot(cp) {
378
431
  return cp !== null && cp !== undefined && manifestVersion(cp.manifest) === 3;
@@ -409,7 +462,7 @@ function aheadOfThisCleo(t, schemaVersion, parent) {
409
462
  * orphan.
410
463
  */
411
464
  function journalStreamRefusal(t, parent) {
412
- return streamUpgradedError(`${t.streamId} takes only checkpoint/v3 snapshots: its head snapshot ${parent.checkpointId} is one (the change journal writes this stream), and the server refuses the checkpoint/v2 snapshots this CLEO's vault writes after it`, `nothing was written; ${JOURNAL_STREAM_REMEDY}`);
465
+ return streamUpgradedError(`${t.streamId} takes only checkpoint/v3 snapshots: its head snapshot ${parent.checkpointId} is one (the change journal writes this stream), and the server refuses the checkpoint/v2 snapshots this CLEO's vault writes after it`, `nothing was written; ${journalStreamRemedy()}`);
413
466
  }
414
467
  function streamUpgradedError(message, fix) {
415
468
  return vaultError('E_NEXUS_VAULT_STREAM_UPGRADED', message, fix);
@@ -986,7 +1039,7 @@ async function appendCheckpoint(a) {
986
1039
  // The server's v3 ratchet (reason `stream-v3`). The check above refuses a v3 head before
987
1040
  // anything is written; this maps a server whose head this client did not see as v3.
988
1041
  if (err instanceof NexusError && err.code === 'E_STREAM_VERSION') {
989
- throw streamUpgradedError(`the server refused the snapshot: ${t.streamId} takes only checkpoint/v3 snapshots (${err.message})`, JOURNAL_STREAM_REMEDY);
1042
+ throw streamUpgradedError(`the server refused the snapshot: ${t.streamId} takes only checkpoint/v3 snapshots (${err.message})`, journalStreamRemedy());
990
1043
  }
991
1044
  const countRefusal = err instanceof NexusError && (err.code === 'E_REGRESSION' || err.code === 'E_VALIDATION');
992
1045
  if (countRefusal && attempt === 0)
@@ -1384,7 +1437,7 @@ async function pushNexusVaultImpl(opts = {}) {
1384
1437
  return pushJournalCheckpoint(conn, key, opts, scope, warnings);
1385
1438
  }
1386
1439
  if (cut !== undefined) {
1387
- throw streamUpgradedError(`this store started ${t.streamId}'s change journal (genesis cut at capture ${cut}); its changes are pushed as journal segments, not vault snapshots`, `nothing was written; ${JOURNAL_STREAM_REMEDY}`);
1440
+ throw streamUpgradedError(`this store started ${t.streamId}'s change journal (genesis cut at capture ${cut}); its changes are pushed as journal segments, not vault snapshots`, `nothing was written; ${journalStreamRemedy()}`);
1388
1441
  }
1389
1442
  const force = opts.force === true;
1390
1443
  const journal = journalFor(conn, t);
@@ -1412,7 +1465,7 @@ async function pushNexusVaultImpl(opts = {}) {
1412
1465
  const overUnsynced = head.headCheckpointId !== null && head.headCheckpointId !== synced?.lastCheckpointId;
1413
1466
  if (overUnsynced && !force) {
1414
1467
  throw vaultError('E_NEXUS_VAULT_BEHIND', `another device pushed snapshot ${head.headCheckpointId} after this machine's last sync`, isJournalSnapshot(parent)
1415
- ? `run \`cleo cloud pull\` first (it refuses to overwrite local changes); ${JOURNAL_STREAM_REMEDY}`
1468
+ ? `run \`cleo cloud pull\` first (it refuses to overwrite local changes); ${journalStreamRemedy()}`
1416
1469
  : 'run `cleo cloud pull` first (it refuses to overwrite local changes), or `--force` to push this store as a labelled fork');
1417
1470
  }
1418
1471
  const git = gitTracking(t);
@@ -2582,7 +2635,7 @@ async function cloudSyncImpl(opts = {}) {
2582
2635
  streams.push(await syncOneStream({ conn, key }, opts, scope));
2583
2636
  const worked = streams.filter((r) => r.status !== 'disabled' && r.status !== 'not-attached');
2584
2637
  if (worked.length === 0 && streams.some((r) => r.status === 'disabled')) {
2585
- throw vaultError('E_SYNC_DISABLED', 'no attached stream has sync.push or sync.pull on', 'turn the change journal on first: `cleo sync enable push`');
2638
+ throw vaultError('E_SYNC_DISABLED', 'no attached stream has sync.push or sync.pull on', syncDisabledRemedy());
2586
2639
  }
2587
2640
  return { apiUrl: conn.apiUrl, streams, warnings: [...conn.warnings] };
2588
2641
  }
@@ -2957,6 +3010,13 @@ async function restoreNexusVaultImpl(opts) {
2957
3010
  const names = await deviceNames(conn);
2958
3011
  if (opts.mode === 'pull' && synced?.lastCheckpointId === target && opts.force !== true) {
2959
3012
  const cp = cps.find((c) => c.checkpointId === target) ?? null;
3013
+ const unread = target === head.headCheckpointId
3014
+ ? await journalUnread(t, head.headSeq, trusted.find((c) => c.checkpointId === target))
3015
+ : 0;
3016
+ if (unread > 0) {
3017
+ // @sync-invariant none:local-only a read-only refusal: nothing is written
3018
+ throw vaultError('E_NEXUS_VAULT_BEHIND', `${t.streamId}: the change journal holds ${unread} segment(s) past snapshot ${target}, and this store reads snapshots only, so it is not up to date`, JOURNAL_UNREAD_REMEDY);
3019
+ }
2960
3020
  warnings.push(...conn.state.drainWarnings());
2961
3021
  return {
2962
3022
  apiUrl: conn.apiUrl,
@@ -3030,7 +3090,7 @@ async function restoreNexusVaultImpl(opts) {
3030
3090
  throw vaultError('E_NEXUS_VAULT_LOCAL_CHANGES', last
3031
3091
  ? `this store changed since its last cloud sync (${changed.slice(0, 8).join(', ')}); restoring would overwrite those changes`
3032
3092
  : 'this store holds data that was never synced with this cloud snapshot; restoring would replace it', isJournalSnapshot(targetCp)
3033
- ? `to keep them: ${JOURNAL_STREAM_REMEDY}; or pass --force to restore anyway (a safety backup is taken first)`
3093
+ ? `to keep them: ${journalStreamRemedy()}; or pass --force to restore anyway (a safety backup is taken first)`
3034
3094
  : 'run `cleo cloud push` to keep them (as a fork with --force if another device pushed since), or pass --force to restore anyway (a safety backup is taken first)');
3035
3095
  }
3036
3096
  }
@@ -3235,7 +3295,7 @@ async function restoreNexusVaultImpl(opts) {
3235
3295
  if (keptUnsynced.length > 0) {
3236
3296
  warnings.push({
3237
3297
  code: 'W_NEXUS_VAULT_KEPT_LOCAL',
3238
- message: `kept ${keptUnsynced.length} local file(s) this store never synced with the cloud, in place of the snapshot's copies: ${keptUnsynced.slice(0, 8).join(', ')}${keptUnsynced.length > 8 ? ', …' : ''}; ${isJournalSnapshot(restored.checkpoint) ? `to keep them: ${JOURNAL_STREAM_REMEDY}; or` : 'push to keep them, or'} pull with --force to take the snapshot's`,
3298
+ message: `kept ${keptUnsynced.length} local file(s) this store never synced with the cloud, in place of the snapshot's copies: ${keptUnsynced.slice(0, 8).join(', ')}${keptUnsynced.length > 8 ? ', …' : ''}; ${isJournalSnapshot(restored.checkpoint) ? `to keep them: ${journalStreamRemedy()}; or` : 'push to keep them, or'} pull with --force to take the snapshot's`,
3239
3299
  });
3240
3300
  }
3241
3301
  saveSynced(conn, t, restored.checkpoint, {
@@ -3256,6 +3316,15 @@ async function restoreNexusVaultImpl(opts) {
3256
3316
  });
3257
3317
  }
3258
3318
  }
3319
+ const unread = restored.checkpoint.checkpointId === head.headCheckpointId
3320
+ ? await journalUnread(t, head.headSeq, restored.checkpoint)
3321
+ : 0;
3322
+ if (unread > 0) {
3323
+ warnings.push({
3324
+ code: 'W_NEXUS_VAULT_JOURNAL_UNREAD',
3325
+ message: `the change journal holds ${unread} segment(s) past snapshot ${restored.checkpoint.checkpointId}, which this store does not have: ${JOURNAL_UNREAD_REMEDY}`,
3326
+ });
3327
+ }
3259
3328
  warnings.push(...conn.state.drainWarnings());
3260
3329
  return {
3261
3330
  apiUrl: conn.apiUrl,
@@ -3307,7 +3376,7 @@ async function nexusVaultStatusImpl(opts = {}) {
3307
3376
  if (headCp && isJournalSnapshot(headCp) && pendingChanges.length > 0) {
3308
3377
  warnings.push({
3309
3378
  code: 'W_NEXUS_VAULT_JOURNAL_STREAM',
3310
- message: `${pendingChanges.length} table(s) changed since the last sync, and the newest snapshot ${headCp.checkpointId} is checkpoint/v3 (the change journal writes this stream): ${JOURNAL_STREAM_REMEDY}`,
3379
+ message: `${pendingChanges.length} table(s) changed since the last sync, and the newest snapshot ${headCp.checkpointId} is checkpoint/v3 (the change journal writes this stream): ${journalStreamRemedy()}`,
3311
3380
  });
3312
3381
  }
3313
3382
  return {
@@ -3488,12 +3557,27 @@ async function verifyNexusVaultImpl(opts = {}) {
3488
3557
  return { ...r, cloudRows, match: (r.localRows ?? 0) === cloudRows };
3489
3558
  });
3490
3559
  }
3560
+ // On a journal head, tables only snapshots carry (files, other databases, the
3561
+ // row-identity-exempt tables) hold machine-local state: listed, never the verdict (T13867).
3562
+ const journalHead = isJournalSnapshot(headCp);
3563
+ const snapshotOnly = new Set(Object.keys(ROW_IDENTITY_EXEMPT[tableScopeOf(t)]));
3564
+ const decides = (r) => !journalHead || !(isSnapshotAuthoritativeKey(r.table) || snapshotOnly.has(r.table));
3565
+ const asideDiffer = tables.filter((r) => !r.match && !decides(r)).map((r) => r.table);
3566
+ if (asideDiffer.length > 0) {
3567
+ warnings.push({
3568
+ code: 'W_NEXUS_VAULT_SNAPSHOT_ONLY',
3569
+ message: `${asideDiffer.length} table(s) only snapshots carry differ from the newest snapshot (machine-local, or not checkpointed yet), so they do not decide the verdict: ${asideDiffer.slice(0, 8).join(', ')}`,
3570
+ });
3571
+ }
3572
+ const unread = await journalUnread(t, head.headSeq, headCp);
3491
3573
  let verdict;
3492
3574
  if (headUntrusted)
3493
3575
  verdict = 'untrusted';
3494
3576
  else if (!headCp)
3495
3577
  verdict = 'empty';
3496
- else if (tables.every((x) => x.match))
3578
+ else if (unread > 0)
3579
+ verdict = 'behind';
3580
+ else if (tables.filter(decides).every((x) => x.match))
3497
3581
  verdict = 'match';
3498
3582
  else if (journalSide !== null) {
3499
3583
  const { localChanged, cloudAdvanced } = journalSide;
@@ -3501,7 +3585,7 @@ async function verifyNexusVaultImpl(opts = {}) {
3501
3585
  }
3502
3586
  else {
3503
3587
  const localChanged = last
3504
- ? compareWithSynced(local, last.manifest, git, fileChanges).some((d) => !d.match)
3588
+ ? compareWithSynced(local, last.manifest, git, fileChanges).some((d) => !d.match && decides(d))
3505
3589
  : true;
3506
3590
  const cloudAdvanced = synced?.lastCheckpointId !== headCp.checkpointId;
3507
3591
  verdict = localChanged && cloudAdvanced ? 'diverged' : cloudAdvanced ? 'behind' : 'ahead';
@@ -3557,7 +3641,6 @@ async function verifyNexusVaultImpl(opts = {}) {
3557
3641
  const headFormat = formatWarning(t, headCp);
3558
3642
  if (headFormat)
3559
3643
  warnings.push(headFormat);
3560
- const journalHead = isJournalSnapshot(headCp);
3561
3644
  const remedy = deepFailure !== null
3562
3645
  ? `the cloud copy failed the deep check (${deepFailure}): do not pull it; see which device pushed the newest snapshot with \`cleo cloud vault\` and \`cleo cloud activity\`, then push a fresh snapshot from a machine whose store passes \`cleo cloud verify\``
3563
3646
  : verdict === 'untrusted'
@@ -3565,14 +3648,16 @@ async function verifyNexusVaultImpl(opts = {}) {
3565
3648
  : headCp && vaultManifestFormat(headCp.manifest, hashKeyOf(t.dataKey)) === 'unknown'
3566
3649
  ? `the newest snapshot records a vault manifest format this CLEO does not recognise (this CLEO hashes format ${VAULT_MANIFEST_FORMAT_VERSION}): if a newer CLEO pushed it, upgrade CLEO on this machine, then verify again`
3567
3650
  : verdict === 'behind'
3568
- ? 'run `cleo cloud pull` to bring this machine to the newest snapshot'
3651
+ ? unread > 0
3652
+ ? `the change journal holds ${unread} segment(s) past the newest snapshot, which this store reads snapshots only and does not have: ${JOURNAL_UNREAD_REMEDY}`
3653
+ : 'run `cleo cloud pull` to bring this machine to the newest snapshot'
3569
3654
  : verdict === 'ahead'
3570
3655
  ? journalHead
3571
- ? `this machine changed since the newest snapshot, which is checkpoint/v3 (the change journal writes this stream): ${JOURNAL_STREAM_REMEDY}`
3656
+ ? `this machine changed since the newest snapshot, which is checkpoint/v3 (the change journal writes this stream): ${journalStreamRemedy()}`
3572
3657
  : 'run `cleo cloud push` to back up the local changes'
3573
3658
  : verdict === 'diverged'
3574
3659
  ? journalHead
3575
- ? `both sides changed, and the newest snapshot is checkpoint/v3 (the change journal writes this stream): ${JOURNAL_STREAM_REMEDY}; or \`cleo cloud pull --force\` to take the cloud (a safety backup is taken first)`
3660
+ ? `both sides changed, and the newest snapshot is checkpoint/v3 (the change journal writes this stream): ${journalStreamRemedy()}; or \`cleo cloud pull --force\` to take the cloud (a safety backup is taken first)`
3576
3661
  : 'both sides changed: run `cleo cloud push --force` to keep this machine (a labelled fork), or `cleo cloud pull --force` to take the cloud (a safety backup is taken first)'
3577
3662
  : verdict === 'empty'
3578
3663
  ? 'run `cleo cloud push` to make the first snapshot'