@wjarka/cezarion 0.17.0-dev.3070 → 0.17.0-nightly.20261028.57

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/README.md CHANGED
@@ -1445,7 +1445,7 @@ itself remains selectable.
1445
1445
 
1446
1446
  Run data (`runs.db` and its `-wal`/`-shm` files, the `runs.json.pre-sqlite*.bak`
1447
1447
  backups, NDJSON event logs, worktrees, `todos.json`) is git-ignored
1448
- automatically; your workflows and skills stay committable.
1448
+ automatically; your workflows and skills stay committable. See [run history recovery](https://github.com/hearsay-tools/cezarion/blob/main/docs/run-history-recovery.md) for backup and repair steps.
1449
1449
 
1450
1450
  Settings that belong to *you* rather than to a repo — the parallel cap
1451
1451
  (`maxParallel`, default **2**), the per-task memory ceiling and the checkout
@@ -453,13 +453,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
453
453
  "/api/v1/tools/preview-stop": {
454
454
  $post: {
455
455
  output: {
456
- ok: boolean;
457
- code: "adopted" | "approval_required" | "headless" | "invalid_input" | "not_registered" | "port_held" | "port_in_use" | "preview_disabled" | "restarted" | "stopped" | "unavailable" | "worktree_missing";
456
+ code: 'capability_revoked';
458
457
  message: string;
459
- hint: string;
460
458
  };
461
459
  outputFormat: "json";
462
- status: import("hono/utils/http-status").ContentfulStatusCode;
460
+ status: 401;
463
461
  input: {
464
462
  json: {
465
463
  port: number;
@@ -468,11 +466,13 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
468
466
  };
469
467
  } | {
470
468
  output: {
471
- code: 'capability_revoked';
469
+ ok: boolean;
470
+ code: "adopted" | "approval_required" | "headless" | "invalid_input" | "not_registered" | "port_held" | "port_in_use" | "preview_disabled" | "restarted" | "stopped" | "unavailable" | "worktree_missing";
472
471
  message: string;
472
+ hint: string;
473
473
  };
474
474
  outputFormat: "json";
475
- status: 401;
475
+ status: import("hono/utils/http-status").ContentfulStatusCode;
476
476
  input: {
477
477
  json: {
478
478
  port: number;
@@ -485,13 +485,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
485
485
  "/api/v1/tools/preview-serve": {
486
486
  $post: {
487
487
  output: {
488
- ok: boolean;
489
- code: "cezar_port" | "cwd_outside_worktree" | "headless" | "invalid_input" | "port_held" | "preview_disabled" | "registered" | "replaced" | "too_many" | "unavailable" | "worktree_missing";
488
+ code: 'capability_revoked';
490
489
  message: string;
491
- hint: string;
492
490
  };
493
491
  outputFormat: "json";
494
- status: import("hono/utils/http-status").ContentfulStatusCode;
492
+ status: 401;
495
493
  input: {
496
494
  json: {
497
495
  command: string;
@@ -503,11 +501,13 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
503
501
  };
504
502
  } | {
505
503
  output: {
506
- code: 'capability_revoked';
504
+ ok: boolean;
505
+ code: "cezar_port" | "cwd_outside_worktree" | "headless" | "invalid_input" | "port_held" | "preview_disabled" | "registered" | "replaced" | "too_many" | "unavailable" | "worktree_missing";
507
506
  message: string;
507
+ hint: string;
508
508
  };
509
509
  outputFormat: "json";
510
- status: 401;
510
+ status: import("hono/utils/http-status").ContentfulStatusCode;
511
511
  input: {
512
512
  json: {
513
513
  command: string;
@@ -523,12 +523,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
523
523
  "/api/v1/tools/schedule-task": {
524
524
  $post: {
525
525
  output: {
526
- ok: false;
527
- code: import('../contract/index.js').ScheduledTaskRefusalCode;
526
+ code: 'capability_revoked';
528
527
  message: string;
529
528
  };
530
529
  outputFormat: "json";
531
- status: import("hono/utils/http-status").ContentfulStatusCode;
530
+ status: 401;
532
531
  input: {
533
532
  json: {
534
533
  at?: string | undefined;
@@ -546,11 +545,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
546
545
  };
547
546
  } | {
548
547
  output: {
549
- code: 'capability_revoked';
548
+ ok: false;
549
+ code: import('../contract/index.js').ScheduledTaskRefusalCode;
550
550
  message: string;
551
551
  };
552
552
  outputFormat: "json";
553
- status: 401;
553
+ status: import("hono/utils/http-status").ContentfulStatusCode;
554
554
  input: {
555
555
  json: {
556
556
  at?: string | undefined;
@@ -609,12 +609,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
609
609
  "/api/v1/tools/scheduled-tasks": {
610
610
  $post: {
611
611
  output: {
612
- ok: false;
613
- code: import('../contract/index.js').ScheduledTaskRefusalCode;
612
+ code: 'capability_revoked';
614
613
  message: string;
615
614
  };
616
615
  outputFormat: "json";
617
- status: import("hono/utils/http-status").ContentfulStatusCode;
616
+ status: 401;
618
617
  input: {
619
618
  json: {
620
619
  at?: string | undefined;
@@ -648,11 +647,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
648
647
  };
649
648
  } | {
650
649
  output: {
651
- code: 'capability_revoked';
650
+ ok: false;
651
+ code: import('../contract/index.js').ScheduledTaskRefusalCode;
652
652
  message: string;
653
653
  };
654
654
  outputFormat: "json";
655
- status: 401;
655
+ status: import("hono/utils/http-status").ContentfulStatusCode;
656
656
  input: {
657
657
  json: {
658
658
  at?: string | undefined;
@@ -13,7 +13,7 @@ import { z } from 'zod';
13
13
  * One line of a run transcript.
14
14
  *
15
15
  * Open by design: `type` is a plain string and unknown keys pass through, because the event
16
- * vocabulary is an APPEND-ONLY on-disk format (BACKWARD_COMPATIBILITY.md §7) that old NDJSON
16
+ * vocabulary is an APPEND-ONLY on-disk format (BACKWARD_COMPATIBILITY.md) that old NDJSON
17
17
  * recordings must keep replaying forever. Closing this schema would make a recording written by
18
18
  * a newer cezar unreadable by an older one — the opposite of what the format promises.
19
19
  */
@@ -1,9 +1,9 @@
1
1
  import { z } from 'zod';
2
2
  /**
3
3
  * One issue or pull request, flattened for the cockpit (`ForgeItem` server-side).
4
- * A protected shape — BACKWARD_COMPATIBILITY.md §2 forbids reshaping it outside a documented
5
- * deprecation. `body` is in one (hearsay-tools/cezarion#1183): optional, still sent by list
6
- * routes, and hydrated from `detail.body` on the comments route by new consumers.
4
+ * A protected shape — changes require an explanation and migration path. The `body` field is
5
+ * deprecated (hearsay-tools/cezarion#1183): optional, still sent by list routes, and hydrated
6
+ * from `detail.body` on the comments route by new consumers.
7
7
  */
8
8
  export declare const githubItemSchema: z.ZodObject<{
9
9
  kind: z.ZodEnum<{
@@ -52,7 +52,7 @@ export declare const capabilitiesSchema: z.ZodObject<{
52
52
  }, z.core.$strip>;
53
53
  export type Capabilities = z.infer<typeof capabilitiesSchema>;
54
54
  /**
55
- * `GET /api/v1/health` — the CORS-open discovery endpoint (BACKWARD_COMPATIBILITY.md §2).
55
+ * `GET /api/v1/health` — the CORS-open discovery endpoint (BACKWARD_COMPATIBILITY.md).
56
56
  *
57
57
  * Additive fields only: this is the most externally-depended-on JSON in the app.
58
58
  */
@@ -123,7 +123,7 @@ export declare function normalizeSidebarLimits(value: unknown): Required<Sidebar
123
123
  /**
124
124
  * `GET/PUT /api/v1/ui-state` — the per-repo GUI prefs in `.ai/cezar/ui-state.json`.
125
125
  *
126
- * An OPEN bag on purpose (BACKWARD_COMPATIBILITY.md §3): unknown keys round-trip untouched, so a
126
+ * An OPEN bag on purpose (BACKWARD_COMPATIBILITY.md): unknown keys round-trip untouched, so a
127
127
  * newer cockpit's prefs survive an older server and a future pref needs no server change. Hence
128
128
  * `z.looseObject`, not a closed object — the keys below are the ones the server's schema *names*,
129
129
  * never the ones it *permits*. The write side caps the TOP-LEVEL key count at 200 (#429); that cap
@@ -27,6 +27,18 @@ export declare function delegationFailure(error: unknown): {
27
27
  export declare function createDelegationRoutes(service: DelegationService, credentials: CredentialRegistry): import("hono/hono-base").HonoBase<Env, {
28
28
  "/list": {
29
29
  $get: {
30
+ output: {
31
+ error: string;
32
+ code?: "invalid_input" | undefined;
33
+ };
34
+ outputFormat: "json";
35
+ status: 400;
36
+ input: {
37
+ query: {
38
+ offset?: string | undefined;
39
+ };
40
+ };
41
+ } | {
30
42
  output: {
31
43
  workers: {
32
44
  workerId: string;
@@ -64,18 +76,6 @@ export declare function createDelegationRoutes(service: DelegationService, crede
64
76
  offset?: string | undefined;
65
77
  };
66
78
  };
67
- } | {
68
- output: {
69
- error: string;
70
- code?: "invalid_input" | undefined;
71
- };
72
- outputFormat: "json";
73
- status: 400;
74
- input: {
75
- query: {
76
- offset?: string | undefined;
77
- };
78
- };
79
79
  };
80
80
  };
81
81
  } & {
@@ -556,6 +556,18 @@ export declare function createDelegationRoutes(service: DelegationService, crede
556
556
  } & {
557
557
  "/:workerId": {
558
558
  $get: {
559
+ output: {
560
+ error: string;
561
+ code?: "invalid_input" | undefined;
562
+ };
563
+ outputFormat: "json";
564
+ status: 400;
565
+ input: {
566
+ param: {
567
+ workerId: string;
568
+ };
569
+ };
570
+ } | {
559
571
  output: {
560
572
  workerId: string;
561
573
  parentRunId: string;
@@ -659,7 +671,11 @@ export declare function createDelegationRoutes(service: DelegationService, crede
659
671
  workerId: string;
660
672
  };
661
673
  };
662
- } | {
674
+ };
675
+ };
676
+ } & {
677
+ "/:workerId/collect": {
678
+ $post: {
663
679
  output: {
664
680
  error: string;
665
681
  code?: "invalid_input" | undefined;
@@ -670,12 +686,10 @@ export declare function createDelegationRoutes(service: DelegationService, crede
670
686
  param: {
671
687
  workerId: string;
672
688
  };
689
+ } & {
690
+ json: Record<string, never>;
673
691
  };
674
- };
675
- };
676
- } & {
677
- "/:workerId/collect": {
678
- $post: {
692
+ } | {
679
693
  output: {
680
694
  workerId: string;
681
695
  parentRunId: string;
@@ -777,7 +791,11 @@ export declare function createDelegationRoutes(service: DelegationService, crede
777
791
  } & {
778
792
  json: Record<string, never>;
779
793
  };
780
- } | {
794
+ };
795
+ };
796
+ } & {
797
+ "/:workerId/steer": {
798
+ $post: {
781
799
  output: {
782
800
  error: string;
783
801
  code?: "invalid_input" | undefined;
@@ -789,13 +807,11 @@ export declare function createDelegationRoutes(service: DelegationService, crede
789
807
  workerId: string;
790
808
  };
791
809
  } & {
792
- json: Record<string, never>;
810
+ json: {
811
+ text: string;
812
+ };
793
813
  };
794
- };
795
- };
796
- } & {
797
- "/:workerId/steer": {
798
- $post: {
814
+ } | {
799
815
  output: {
800
816
  workerId: string;
801
817
  state: "delivered" | "queued";
@@ -811,7 +827,11 @@ export declare function createDelegationRoutes(service: DelegationService, crede
811
827
  text: string;
812
828
  };
813
829
  };
814
- } | {
830
+ };
831
+ };
832
+ } & {
833
+ "/:workerId/stop": {
834
+ $post: {
815
835
  output: {
816
836
  error: string;
817
837
  code?: "invalid_input" | undefined;
@@ -823,15 +843,9 @@ export declare function createDelegationRoutes(service: DelegationService, crede
823
843
  workerId: string;
824
844
  };
825
845
  } & {
826
- json: {
827
- text: string;
828
- };
846
+ json: Record<string, never>;
829
847
  };
830
- };
831
- };
832
- } & {
833
- "/:workerId/stop": {
834
- $post: {
848
+ } | {
835
849
  output: {
836
850
  workerId: string;
837
851
  state: "stopping" | "terminated";
@@ -845,7 +859,11 @@ export declare function createDelegationRoutes(service: DelegationService, crede
845
859
  } & {
846
860
  json: Record<string, never>;
847
861
  };
848
- } | {
862
+ };
863
+ };
864
+ } & {
865
+ "/:workerId/destroy": {
866
+ $post: {
849
867
  output: {
850
868
  error: string;
851
869
  code?: "invalid_input" | undefined;
@@ -859,11 +877,7 @@ export declare function createDelegationRoutes(service: DelegationService, crede
859
877
  } & {
860
878
  json: Record<string, never>;
861
879
  };
862
- };
863
- };
864
- } & {
865
- "/:workerId/destroy": {
866
- $post: {
880
+ } | {
867
881
  output: {
868
882
  workerId: string;
869
883
  state: "complete" | "incomplete";
@@ -886,20 +900,6 @@ export declare function createDelegationRoutes(service: DelegationService, crede
886
900
  } & {
887
901
  json: Record<string, never>;
888
902
  };
889
- } | {
890
- output: {
891
- error: string;
892
- code?: "invalid_input" | undefined;
893
- };
894
- outputFormat: "json";
895
- status: 400;
896
- input: {
897
- param: {
898
- workerId: string;
899
- };
900
- } & {
901
- json: Record<string, never>;
902
- };
903
903
  } | {
904
904
  output: {
905
905
  workerId: string;
@@ -929,13 +929,11 @@ export declare function createDelegationRoutes(service: DelegationService, crede
929
929
  "/:workerId/diff": {
930
930
  $get: {
931
931
  output: {
932
- workerId: string;
933
- baselineSha: string;
934
- diff: string;
935
- truncated: boolean;
932
+ error: string;
933
+ code?: "invalid_input" | undefined;
936
934
  };
937
935
  outputFormat: "json";
938
- status: 200;
936
+ status: 400;
939
937
  input: {
940
938
  param: {
941
939
  workerId: string;
@@ -943,11 +941,13 @@ export declare function createDelegationRoutes(service: DelegationService, crede
943
941
  };
944
942
  } | {
945
943
  output: {
946
- error: string;
947
- code?: "invalid_input" | undefined;
944
+ workerId: string;
945
+ baselineSha: string;
946
+ diff: string;
947
+ truncated: boolean;
948
948
  };
949
949
  outputFormat: "json";
950
- status: 400;
950
+ status: 200;
951
951
  input: {
952
952
  param: {
953
953
  workerId: string;
@@ -2,18 +2,6 @@ import type { DelegationRoutes } from './routes.ts';
2
2
  export declare function createDelegationApp(routes: DelegationRoutes): import("hono/hono-base").HonoBase<import("hono/types").BlankEnv, import("hono/types").BlankSchema | import("hono/types").MergeSchemaPath<{
3
3
  "/list": {
4
4
  $get: {
5
- output: {
6
- error: string;
7
- code?: "invalid_input" | undefined;
8
- };
9
- outputFormat: "json";
10
- status: 400;
11
- input: {
12
- query: {
13
- offset?: string | undefined;
14
- };
15
- };
16
- } | {
17
5
  output: {
18
6
  workers: {
19
7
  workerId: string;
@@ -51,6 +39,18 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
51
39
  offset?: string | undefined;
52
40
  };
53
41
  };
42
+ } | {
43
+ output: {
44
+ error: string;
45
+ code?: "invalid_input" | undefined;
46
+ };
47
+ outputFormat: "json";
48
+ status: 400;
49
+ input: {
50
+ query: {
51
+ offset?: string | undefined;
52
+ };
53
+ };
54
54
  };
55
55
  };
56
56
  } & {
@@ -531,18 +531,6 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
531
531
  } & {
532
532
  "/:workerId": {
533
533
  $get: {
534
- output: {
535
- error: string;
536
- code?: "invalid_input" | undefined;
537
- };
538
- outputFormat: "json";
539
- status: 400;
540
- input: {
541
- param: {
542
- workerId: string;
543
- };
544
- };
545
- } | {
546
534
  output: {
547
535
  workerId: string;
548
536
  parentRunId: string;
@@ -646,11 +634,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
646
634
  workerId: string;
647
635
  };
648
636
  };
649
- };
650
- };
651
- } & {
652
- "/:workerId/collect": {
653
- $post: {
637
+ } | {
654
638
  output: {
655
639
  error: string;
656
640
  code?: "invalid_input" | undefined;
@@ -661,10 +645,12 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
661
645
  param: {
662
646
  workerId: string;
663
647
  };
664
- } & {
665
- json: Record<string, never>;
666
648
  };
667
- } | {
649
+ };
650
+ };
651
+ } & {
652
+ "/:workerId/collect": {
653
+ $post: {
668
654
  output: {
669
655
  workerId: string;
670
656
  parentRunId: string;
@@ -766,11 +752,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
766
752
  } & {
767
753
  json: Record<string, never>;
768
754
  };
769
- };
770
- };
771
- } & {
772
- "/:workerId/steer": {
773
- $post: {
755
+ } | {
774
756
  output: {
775
757
  error: string;
776
758
  code?: "invalid_input" | undefined;
@@ -782,11 +764,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
782
764
  workerId: string;
783
765
  };
784
766
  } & {
785
- json: {
786
- text: string;
787
- };
767
+ json: Record<string, never>;
788
768
  };
789
- } | {
769
+ };
770
+ };
771
+ } & {
772
+ "/:workerId/steer": {
773
+ $post: {
790
774
  output: {
791
775
  workerId: string;
792
776
  state: "delivered" | "queued";
@@ -802,11 +786,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
802
786
  text: string;
803
787
  };
804
788
  };
805
- };
806
- };
807
- } & {
808
- "/:workerId/stop": {
809
- $post: {
789
+ } | {
810
790
  output: {
811
791
  error: string;
812
792
  code?: "invalid_input" | undefined;
@@ -818,9 +798,15 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
818
798
  workerId: string;
819
799
  };
820
800
  } & {
821
- json: Record<string, never>;
801
+ json: {
802
+ text: string;
803
+ };
822
804
  };
823
- } | {
805
+ };
806
+ };
807
+ } & {
808
+ "/:workerId/stop": {
809
+ $post: {
824
810
  output: {
825
811
  workerId: string;
826
812
  state: "stopping" | "terminated";
@@ -834,11 +820,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
834
820
  } & {
835
821
  json: Record<string, never>;
836
822
  };
837
- };
838
- };
839
- } & {
840
- "/:workerId/destroy": {
841
- $post: {
823
+ } | {
842
824
  output: {
843
825
  error: string;
844
826
  code?: "invalid_input" | undefined;
@@ -852,7 +834,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
852
834
  } & {
853
835
  json: Record<string, never>;
854
836
  };
855
- } | {
837
+ };
838
+ };
839
+ } & {
840
+ "/:workerId/destroy": {
841
+ $post: {
856
842
  output: {
857
843
  workerId: string;
858
844
  state: "complete" | "incomplete";
@@ -875,6 +861,20 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
875
861
  } & {
876
862
  json: Record<string, never>;
877
863
  };
864
+ } | {
865
+ output: {
866
+ error: string;
867
+ code?: "invalid_input" | undefined;
868
+ };
869
+ outputFormat: "json";
870
+ status: 400;
871
+ input: {
872
+ param: {
873
+ workerId: string;
874
+ };
875
+ } & {
876
+ json: Record<string, never>;
877
+ };
878
878
  } | {
879
879
  output: {
880
880
  workerId: string;
@@ -904,11 +904,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
904
904
  "/:workerId/diff": {
905
905
  $get: {
906
906
  output: {
907
- error: string;
908
- code?: "invalid_input" | undefined;
907
+ workerId: string;
908
+ baselineSha: string;
909
+ diff: string;
910
+ truncated: boolean;
909
911
  };
910
912
  outputFormat: "json";
911
- status: 400;
913
+ status: 200;
912
914
  input: {
913
915
  param: {
914
916
  workerId: string;
@@ -916,13 +918,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
916
918
  };
917
919
  } | {
918
920
  output: {
919
- workerId: string;
920
- baselineSha: string;
921
- diff: string;
922
- truncated: boolean;
921
+ error: string;
922
+ code?: "invalid_input" | undefined;
923
923
  };
924
924
  outputFormat: "json";
925
- status: 200;
925
+ status: 400;
926
926
  input: {
927
927
  param: {
928
928
  workerId: string;
@@ -41,7 +41,7 @@ export function toRunStoreOpenError(error, path, opts = {}) {
41
41
  const kind = error instanceof RunDatabaseError ? error.kind : errnoKind(error) ?? 'other';
42
42
  switch (kind) {
43
43
  case 'corrupt':
44
- return new RunStoreOpenError(kind, path, `${path} is damaged (${detail}). cezar left it and its -wal and -shm files exactly as they are: restore them from a backup, or rebuild them from runs.json.pre-sqlite.bak as BACKWARD_COMPATIBILITY.md §3 "Recovering run history" describes, then restart cezar.`, cause);
44
+ return new RunStoreOpenError(kind, path, `${path} is damaged (${detail}). cezar left it and its -wal and -shm files exactly as they are: restore them from a backup, or rebuild them from runs.json.pre-sqlite.bak as https://github.com/hearsay-tools/cezarion/blob/main/docs/run-history-recovery.md describes, then restart cezar.`, cause);
45
45
  case 'busy': {
46
46
  const held = opts.waitedMs ? ` for over ${(opts.waitedMs / 1000).toFixed(1)} s` : '';
47
47
  return new RunStoreOpenError(kind, path, `${path} is busy: another cezar process has held its write lock${held}. Wait for it to finish, then restart cezar.`, cause);
@@ -1 +1 @@
1
- {"version":3,"file":"store-open-error.js","sourceRoot":"","sources":["../../src/runs/store-open-error.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAE,gBAAgB,EAAE,iCAAiC,EAA6B,MAAM,mBAAmB,CAAC;AAKnH;;;;;GAKG;AACH,MAAM,OAAO,iBAAkB,SAAQ,KAAK;IACjC,IAAI,CAAwB;IACrC,yCAAyC;IAChC,IAAI,CAAS;IAEtB,YAAY,IAA2B,EAAE,IAAY,EAAE,OAAe,EAAE,OAAO,GAAwB,EAAE;QACvG,KAAK,CAA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GAAG,IAAI,gCAAgC,MAAM,8CAA8C,EAAE,KAAK,CAAC,CAAC;QAC/I,CAAC;QACD;YACE,OAAO,IAAI,iBAAiB,CAAC,OAAO,EAAE,IAAI,EAAE,GAAG,IAAI,yBAAyB,MAAM,gCAAgC,EAAE,KAAK,CAAC,CAAC;IAC/H,CAAC;AACH,CAAC"}
@@ -47,11 +47,10 @@ import { claimOwnerLive, closeClaimSession, openClaimSession } from './run-claim
47
47
  * ids the rest of cezar speaks (#547).
48
48
  *
49
49
  * `claude-cli` is the legacy spelling of `claude` — still a member of
50
- * `AgentBackend` and still accepted by `createRunner`, and named by
51
- * `BACKWARD_COMPATIBILITY.md` §3 as an id `runs.json` keeps parseable. The enum
52
- * here did not accept it, so that promise was false: the loader `safeParse`s the
50
+ * `AgentBackend` and still accepted by `createRunner`, and accepted in `runs.json`. The enum
51
+ * here once failed to accept it: the loader `safeParse`s the
53
52
  * WHOLE array, so one record carrying it would have dropped every run in the
54
- * file — the exact failure mode §3 exists to warn about.
53
+ * file.
55
54
  *
56
55
  * Parse-and-fold rather than widen: the legacy id is accepted on the way in and
57
56
  * collapsed to `claude`, so no consumer, wire type or contract schema ever sees
@@ -962,7 +961,7 @@ function importLegacyIndex(db, dataDir) {
962
961
  // Told once, by the import that committed: the marker means no later open reads runs.json again.
963
962
  if (commit.skipped || backup === undefined)
964
963
  return;
965
- const kept = `Its exact bytes are kept in ${join(dataDir, backup)}; BACKWARD_COMPATIBILITY.md §3 says how to import it after a repair.`;
964
+ const kept = `Its exact bytes are kept in ${join(dataDir, backup)}; https://github.com/hearsay-tools/cezarion/blob/main/docs/run-history-recovery.md says how to import it after a repair.`;
966
965
  if (!parsed)
967
966
  console.warn(`[cez] ${LEGACY_INDEX_FILE} could not be read; no run was imported, and this project starts with an empty history. ${kept}`);
968
967
  else if (skipped > 0)