@hearsay-tools/squawk 0.18.0-dev.7960 → 0.18.0-dev.7964
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/ci-wait/controller.d.ts +42 -42
- package/dist/delegation/transport.d.ts +65 -65
- package/dist/runs/transcript-facts-queue.d.ts +5 -1
- package/dist/runs/transcript-facts-queue.js +48 -9
- package/dist/runs/transcript-facts-queue.js.map +1 -1
- package/dist/server/runner-install-routes.d.ts +10 -10
- package/package.json +4 -4
|
@@ -285,12 +285,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
285
285
|
"/api/v1/tools/ask": {
|
|
286
286
|
$post: {
|
|
287
287
|
output: {
|
|
288
|
-
|
|
289
|
-
code: 'unavailable';
|
|
288
|
+
code: 'capability_revoked';
|
|
290
289
|
message: string;
|
|
291
290
|
};
|
|
292
291
|
outputFormat: "json";
|
|
293
|
-
status:
|
|
292
|
+
status: 401;
|
|
294
293
|
input: {
|
|
295
294
|
json: {
|
|
296
295
|
questions: {
|
|
@@ -309,11 +308,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
309
308
|
};
|
|
310
309
|
} | {
|
|
311
310
|
output: {
|
|
312
|
-
|
|
311
|
+
ok: false;
|
|
312
|
+
code: 'unavailable';
|
|
313
313
|
message: string;
|
|
314
314
|
};
|
|
315
315
|
outputFormat: "json";
|
|
316
|
-
status:
|
|
316
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
317
317
|
input: {
|
|
318
318
|
json: {
|
|
319
319
|
questions: {
|
|
@@ -383,12 +383,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
383
383
|
"/api/v1/tools/cancel-wait": {
|
|
384
384
|
$post: {
|
|
385
385
|
output: {
|
|
386
|
-
|
|
387
|
-
code: 'unavailable';
|
|
386
|
+
code: 'capability_revoked';
|
|
388
387
|
message: string;
|
|
389
388
|
};
|
|
390
389
|
outputFormat: "json";
|
|
391
|
-
status:
|
|
390
|
+
status: 401;
|
|
392
391
|
input: {
|
|
393
392
|
json: {
|
|
394
393
|
wait_id: string;
|
|
@@ -396,11 +395,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
396
395
|
};
|
|
397
396
|
} | {
|
|
398
397
|
output: {
|
|
399
|
-
|
|
398
|
+
cancelled: false;
|
|
399
|
+
code: 'unavailable';
|
|
400
400
|
message: string;
|
|
401
401
|
};
|
|
402
402
|
outputFormat: "json";
|
|
403
|
-
status:
|
|
403
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
404
404
|
input: {
|
|
405
405
|
json: {
|
|
406
406
|
wait_id: string;
|
|
@@ -448,12 +448,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
448
448
|
"/api/v1/tools/done": {
|
|
449
449
|
$post: {
|
|
450
450
|
output: {
|
|
451
|
-
|
|
452
|
-
code: 'unavailable';
|
|
451
|
+
code: 'capability_revoked';
|
|
453
452
|
message: string;
|
|
454
453
|
};
|
|
455
454
|
outputFormat: "json";
|
|
456
|
-
status:
|
|
455
|
+
status: 401;
|
|
457
456
|
input: {
|
|
458
457
|
json: {
|
|
459
458
|
summary?: string | undefined;
|
|
@@ -461,11 +460,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
461
460
|
};
|
|
462
461
|
} | {
|
|
463
462
|
output: {
|
|
464
|
-
|
|
463
|
+
ok: false;
|
|
464
|
+
code: 'unavailable';
|
|
465
465
|
message: string;
|
|
466
466
|
};
|
|
467
467
|
outputFormat: "json";
|
|
468
|
-
status:
|
|
468
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
469
469
|
input: {
|
|
470
470
|
json: {
|
|
471
471
|
summary?: string | undefined;
|
|
@@ -548,13 +548,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
548
548
|
"/api/v1/tools/preview-stop": {
|
|
549
549
|
$post: {
|
|
550
550
|
output: {
|
|
551
|
-
|
|
552
|
-
code: "adopted" | "approval_required" | "headless" | "invalid_input" | "not_registered" | "port_held" | "port_in_use" | "preview_disabled" | "restarted" | "stopped" | "unavailable" | "worktree_missing";
|
|
551
|
+
code: 'capability_revoked';
|
|
553
552
|
message: string;
|
|
554
|
-
hint: string;
|
|
555
553
|
};
|
|
556
554
|
outputFormat: "json";
|
|
557
|
-
status:
|
|
555
|
+
status: 401;
|
|
558
556
|
input: {
|
|
559
557
|
json: {
|
|
560
558
|
port: number;
|
|
@@ -563,11 +561,13 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
563
561
|
};
|
|
564
562
|
} | {
|
|
565
563
|
output: {
|
|
566
|
-
|
|
564
|
+
ok: boolean;
|
|
565
|
+
code: "adopted" | "approval_required" | "headless" | "invalid_input" | "not_registered" | "port_held" | "port_in_use" | "preview_disabled" | "restarted" | "stopped" | "unavailable" | "worktree_missing";
|
|
567
566
|
message: string;
|
|
567
|
+
hint: string;
|
|
568
568
|
};
|
|
569
569
|
outputFormat: "json";
|
|
570
|
-
status:
|
|
570
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
571
571
|
input: {
|
|
572
572
|
json: {
|
|
573
573
|
port: number;
|
|
@@ -580,13 +580,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
580
580
|
"/api/v1/tools/preview-serve": {
|
|
581
581
|
$post: {
|
|
582
582
|
output: {
|
|
583
|
-
|
|
584
|
-
code: "cezar_port" | "cwd_outside_worktree" | "headless" | "invalid_input" | "port_held" | "preview_disabled" | "registered" | "replaced" | "too_many" | "unavailable" | "worktree_missing";
|
|
583
|
+
code: 'capability_revoked';
|
|
585
584
|
message: string;
|
|
586
|
-
hint: string;
|
|
587
585
|
};
|
|
588
586
|
outputFormat: "json";
|
|
589
|
-
status:
|
|
587
|
+
status: 401;
|
|
590
588
|
input: {
|
|
591
589
|
json: {
|
|
592
590
|
command: string;
|
|
@@ -598,11 +596,13 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
598
596
|
};
|
|
599
597
|
} | {
|
|
600
598
|
output: {
|
|
601
|
-
|
|
599
|
+
ok: boolean;
|
|
600
|
+
code: "cezar_port" | "cwd_outside_worktree" | "headless" | "invalid_input" | "port_held" | "preview_disabled" | "registered" | "replaced" | "too_many" | "unavailable" | "worktree_missing";
|
|
602
601
|
message: string;
|
|
602
|
+
hint: string;
|
|
603
603
|
};
|
|
604
604
|
outputFormat: "json";
|
|
605
|
-
status:
|
|
605
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
606
606
|
input: {
|
|
607
607
|
json: {
|
|
608
608
|
command: string;
|
|
@@ -618,12 +618,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
618
618
|
"/api/v1/tools/automation": {
|
|
619
619
|
$post: {
|
|
620
620
|
output: {
|
|
621
|
-
|
|
622
|
-
code: import('../contract/index.js').ScheduledTaskRefusalCode;
|
|
621
|
+
code: 'capability_revoked';
|
|
623
622
|
message: string;
|
|
624
623
|
};
|
|
625
624
|
outputFormat: "json";
|
|
626
|
-
status:
|
|
625
|
+
status: 401;
|
|
627
626
|
input: {
|
|
628
627
|
json: {
|
|
629
628
|
action: "create";
|
|
@@ -703,11 +702,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
703
702
|
};
|
|
704
703
|
} | {
|
|
705
704
|
output: {
|
|
706
|
-
|
|
705
|
+
ok: false;
|
|
706
|
+
code: import('../contract/index.js').ScheduledTaskRefusalCode;
|
|
707
707
|
message: string;
|
|
708
708
|
};
|
|
709
709
|
outputFormat: "json";
|
|
710
|
-
status:
|
|
710
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
711
711
|
input: {
|
|
712
712
|
json: {
|
|
713
713
|
action: "create";
|
|
@@ -963,12 +963,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
963
963
|
"/api/v1/tools/schedule-task": {
|
|
964
964
|
$post: {
|
|
965
965
|
output: {
|
|
966
|
-
|
|
967
|
-
code: import('../contract/index.js').ScheduledTaskRefusalCode;
|
|
966
|
+
code: 'capability_revoked';
|
|
968
967
|
message: string;
|
|
969
968
|
};
|
|
970
969
|
outputFormat: "json";
|
|
971
|
-
status:
|
|
970
|
+
status: 401;
|
|
972
971
|
input: {
|
|
973
972
|
json: {
|
|
974
973
|
at?: string | undefined;
|
|
@@ -985,11 +984,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
985
984
|
};
|
|
986
985
|
} | {
|
|
987
986
|
output: {
|
|
988
|
-
|
|
987
|
+
ok: false;
|
|
988
|
+
code: import('../contract/index.js').ScheduledTaskRefusalCode;
|
|
989
989
|
message: string;
|
|
990
990
|
};
|
|
991
991
|
outputFormat: "json";
|
|
992
|
-
status:
|
|
992
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
993
993
|
input: {
|
|
994
994
|
json: {
|
|
995
995
|
at?: string | undefined;
|
|
@@ -1044,12 +1044,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
1044
1044
|
"/api/v1/tools/scheduled-tasks": {
|
|
1045
1045
|
$post: {
|
|
1046
1046
|
output: {
|
|
1047
|
-
|
|
1048
|
-
code: import('../contract/index.js').ScheduledTaskRefusalCode;
|
|
1047
|
+
code: 'capability_revoked';
|
|
1049
1048
|
message: string;
|
|
1050
1049
|
};
|
|
1051
1050
|
outputFormat: "json";
|
|
1052
|
-
status:
|
|
1051
|
+
status: 401;
|
|
1053
1052
|
input: {
|
|
1054
1053
|
json: {
|
|
1055
1054
|
at?: string | undefined;
|
|
@@ -1082,11 +1081,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
|
|
|
1082
1081
|
};
|
|
1083
1082
|
} | {
|
|
1084
1083
|
output: {
|
|
1085
|
-
|
|
1084
|
+
ok: false;
|
|
1085
|
+
code: import('../contract/index.js').ScheduledTaskRefusalCode;
|
|
1086
1086
|
message: string;
|
|
1087
1087
|
};
|
|
1088
1088
|
outputFormat: "json";
|
|
1089
|
-
status:
|
|
1089
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
1090
1090
|
input: {
|
|
1091
1091
|
json: {
|
|
1092
1092
|
at?: string | undefined;
|
|
@@ -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;
|
|
@@ -60,6 +48,18 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
60
48
|
offset?: string | undefined;
|
|
61
49
|
};
|
|
62
50
|
};
|
|
51
|
+
} | {
|
|
52
|
+
output: {
|
|
53
|
+
error: string;
|
|
54
|
+
code?: "invalid_input" | undefined;
|
|
55
|
+
};
|
|
56
|
+
outputFormat: "json";
|
|
57
|
+
status: 400;
|
|
58
|
+
input: {
|
|
59
|
+
query: {
|
|
60
|
+
offset?: string | undefined;
|
|
61
|
+
};
|
|
62
|
+
};
|
|
63
63
|
};
|
|
64
64
|
};
|
|
65
65
|
} & {
|
|
@@ -604,18 +604,6 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
604
604
|
} & {
|
|
605
605
|
"/:workerId": {
|
|
606
606
|
$get: {
|
|
607
|
-
output: {
|
|
608
|
-
error: string;
|
|
609
|
-
code?: "invalid_input" | undefined;
|
|
610
|
-
};
|
|
611
|
-
outputFormat: "json";
|
|
612
|
-
status: 400;
|
|
613
|
-
input: {
|
|
614
|
-
param: {
|
|
615
|
-
workerId: string;
|
|
616
|
-
};
|
|
617
|
-
};
|
|
618
|
-
} | {
|
|
619
607
|
output: {
|
|
620
608
|
workerId: string;
|
|
621
609
|
settled: boolean;
|
|
@@ -733,11 +721,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
733
721
|
workerId: string;
|
|
734
722
|
};
|
|
735
723
|
};
|
|
736
|
-
}
|
|
737
|
-
};
|
|
738
|
-
} & {
|
|
739
|
-
"/:workerId/collect": {
|
|
740
|
-
$post: {
|
|
724
|
+
} | {
|
|
741
725
|
output: {
|
|
742
726
|
error: string;
|
|
743
727
|
code?: "invalid_input" | undefined;
|
|
@@ -748,10 +732,12 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
748
732
|
param: {
|
|
749
733
|
workerId: string;
|
|
750
734
|
};
|
|
751
|
-
} & {
|
|
752
|
-
json: Record<string, never>;
|
|
753
735
|
};
|
|
754
|
-
}
|
|
736
|
+
};
|
|
737
|
+
};
|
|
738
|
+
} & {
|
|
739
|
+
"/:workerId/collect": {
|
|
740
|
+
$post: {
|
|
755
741
|
output: {
|
|
756
742
|
workerId: string;
|
|
757
743
|
parentRunId: string;
|
|
@@ -874,11 +860,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
874
860
|
} & {
|
|
875
861
|
json: Record<string, never>;
|
|
876
862
|
};
|
|
877
|
-
}
|
|
878
|
-
};
|
|
879
|
-
} & {
|
|
880
|
-
"/:workerId/steer": {
|
|
881
|
-
$post: {
|
|
863
|
+
} | {
|
|
882
864
|
output: {
|
|
883
865
|
error: string;
|
|
884
866
|
code?: "invalid_input" | undefined;
|
|
@@ -890,11 +872,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
890
872
|
workerId: string;
|
|
891
873
|
};
|
|
892
874
|
} & {
|
|
893
|
-
json:
|
|
894
|
-
text: string;
|
|
895
|
-
};
|
|
875
|
+
json: Record<string, never>;
|
|
896
876
|
};
|
|
897
|
-
}
|
|
877
|
+
};
|
|
878
|
+
};
|
|
879
|
+
} & {
|
|
880
|
+
"/:workerId/steer": {
|
|
881
|
+
$post: {
|
|
898
882
|
output: {
|
|
899
883
|
workerId: string;
|
|
900
884
|
state: "delivered" | "queued";
|
|
@@ -910,11 +894,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
910
894
|
text: string;
|
|
911
895
|
};
|
|
912
896
|
};
|
|
913
|
-
}
|
|
914
|
-
};
|
|
915
|
-
} & {
|
|
916
|
-
"/:workerId/stop": {
|
|
917
|
-
$post: {
|
|
897
|
+
} | {
|
|
918
898
|
output: {
|
|
919
899
|
error: string;
|
|
920
900
|
code?: "invalid_input" | undefined;
|
|
@@ -926,9 +906,15 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
926
906
|
workerId: string;
|
|
927
907
|
};
|
|
928
908
|
} & {
|
|
929
|
-
json:
|
|
909
|
+
json: {
|
|
910
|
+
text: string;
|
|
911
|
+
};
|
|
930
912
|
};
|
|
931
|
-
}
|
|
913
|
+
};
|
|
914
|
+
};
|
|
915
|
+
} & {
|
|
916
|
+
"/:workerId/stop": {
|
|
917
|
+
$post: {
|
|
932
918
|
output: {
|
|
933
919
|
workerId: string;
|
|
934
920
|
state: "stopping" | "terminated";
|
|
@@ -942,11 +928,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
942
928
|
} & {
|
|
943
929
|
json: Record<string, never>;
|
|
944
930
|
};
|
|
945
|
-
}
|
|
946
|
-
};
|
|
947
|
-
} & {
|
|
948
|
-
"/:workerId/destroy": {
|
|
949
|
-
$post: {
|
|
931
|
+
} | {
|
|
950
932
|
output: {
|
|
951
933
|
error: string;
|
|
952
934
|
code?: "invalid_input" | undefined;
|
|
@@ -958,11 +940,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
958
940
|
workerId: string;
|
|
959
941
|
};
|
|
960
942
|
} & {
|
|
961
|
-
json:
|
|
962
|
-
discardWork?: true | undefined;
|
|
963
|
-
};
|
|
943
|
+
json: Record<string, never>;
|
|
964
944
|
};
|
|
965
|
-
}
|
|
945
|
+
};
|
|
946
|
+
};
|
|
947
|
+
} & {
|
|
948
|
+
"/:workerId/destroy": {
|
|
949
|
+
$post: {
|
|
966
950
|
output: {
|
|
967
951
|
workerId: string;
|
|
968
952
|
state: "complete" | "incomplete";
|
|
@@ -991,6 +975,22 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
991
975
|
discardWork?: true | undefined;
|
|
992
976
|
};
|
|
993
977
|
};
|
|
978
|
+
} | {
|
|
979
|
+
output: {
|
|
980
|
+
error: string;
|
|
981
|
+
code?: "invalid_input" | undefined;
|
|
982
|
+
};
|
|
983
|
+
outputFormat: "json";
|
|
984
|
+
status: 400;
|
|
985
|
+
input: {
|
|
986
|
+
param: {
|
|
987
|
+
workerId: string;
|
|
988
|
+
};
|
|
989
|
+
} & {
|
|
990
|
+
json: {
|
|
991
|
+
discardWork?: true | undefined;
|
|
992
|
+
};
|
|
993
|
+
};
|
|
994
994
|
} | {
|
|
995
995
|
output: {
|
|
996
996
|
workerId: string;
|
|
@@ -1026,11 +1026,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1026
1026
|
"/:workerId/diff": {
|
|
1027
1027
|
$get: {
|
|
1028
1028
|
output: {
|
|
1029
|
-
|
|
1030
|
-
|
|
1029
|
+
workerId: string;
|
|
1030
|
+
baselineSha: string;
|
|
1031
|
+
diff: string;
|
|
1032
|
+
truncated: boolean;
|
|
1031
1033
|
};
|
|
1032
1034
|
outputFormat: "json";
|
|
1033
|
-
status:
|
|
1035
|
+
status: 200;
|
|
1034
1036
|
input: {
|
|
1035
1037
|
param: {
|
|
1036
1038
|
workerId: string;
|
|
@@ -1038,13 +1040,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1038
1040
|
};
|
|
1039
1041
|
} | {
|
|
1040
1042
|
output: {
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
diff: string;
|
|
1044
|
-
truncated: boolean;
|
|
1043
|
+
error: string;
|
|
1044
|
+
code?: "invalid_input" | undefined;
|
|
1045
1045
|
};
|
|
1046
1046
|
outputFormat: "json";
|
|
1047
|
-
status:
|
|
1047
|
+
status: 400;
|
|
1048
1048
|
input: {
|
|
1049
1049
|
param: {
|
|
1050
1050
|
workerId: string;
|
|
@@ -6,7 +6,8 @@ export declare class TranscriptFactsQueue<T> {
|
|
|
6
6
|
private readonly accept;
|
|
7
7
|
private readonly cached?;
|
|
8
8
|
private readonly jobs;
|
|
9
|
-
private
|
|
9
|
+
private pendingHead?;
|
|
10
|
+
private pendingTail?;
|
|
10
11
|
private active?;
|
|
11
12
|
private worker?;
|
|
12
13
|
private workerLifecycle?;
|
|
@@ -19,6 +20,9 @@ export declare class TranscriptFactsQueue<T> {
|
|
|
19
20
|
join(runId: string): T;
|
|
20
21
|
forget(runId: string): void;
|
|
21
22
|
stop(): void;
|
|
23
|
+
private enqueueBack;
|
|
24
|
+
private enqueueFront;
|
|
25
|
+
private removePending;
|
|
22
26
|
private schedule;
|
|
23
27
|
private createWorker;
|
|
24
28
|
private start;
|
|
@@ -9,7 +9,8 @@ export class TranscriptFactsQueue {
|
|
|
9
9
|
accept;
|
|
10
10
|
cached;
|
|
11
11
|
jobs = new Map();
|
|
12
|
-
|
|
12
|
+
pendingHead;
|
|
13
|
+
pendingTail;
|
|
13
14
|
active;
|
|
14
15
|
worker;
|
|
15
16
|
workerLifecycle;
|
|
@@ -29,14 +30,14 @@ export class TranscriptFactsQueue {
|
|
|
29
30
|
let resolve;
|
|
30
31
|
let reject;
|
|
31
32
|
const promise = new Promise((yes, no) => { resolve = yes; reject = no; });
|
|
32
|
-
job = { runId, promise, resolve, reject, attempts: 0 };
|
|
33
|
+
job = { runId, promise, resolve, reject, attempts: 0, queued: false };
|
|
33
34
|
// Synchronous callers may take ownership without ever observing this promise.
|
|
34
35
|
void promise.catch(() => undefined);
|
|
35
36
|
this.jobs.set(runId, job);
|
|
36
|
-
this.
|
|
37
|
+
this.enqueueBack(job);
|
|
37
38
|
}
|
|
38
39
|
if (demand && job !== this.active) {
|
|
39
|
-
this.
|
|
40
|
+
this.enqueueFront(job);
|
|
40
41
|
}
|
|
41
42
|
this.schedule();
|
|
42
43
|
return job.promise;
|
|
@@ -48,7 +49,7 @@ export class TranscriptFactsQueue {
|
|
|
48
49
|
void this.request(runId);
|
|
49
50
|
const job = this.jobs.get(runId);
|
|
50
51
|
if (job !== this.active) {
|
|
51
|
-
this.
|
|
52
|
+
this.removePending(job);
|
|
52
53
|
this.complete(job, { result: loadTranscriptFacts(this.dataDir, runId) });
|
|
53
54
|
}
|
|
54
55
|
const deadline = Date.now() + JOB_TIMEOUT_MS;
|
|
@@ -86,6 +87,44 @@ export class TranscriptFactsQueue {
|
|
|
86
87
|
this.stopped = true;
|
|
87
88
|
this.fail(new Error('Transcript facts queue stopped'));
|
|
88
89
|
}
|
|
90
|
+
enqueueBack(job) {
|
|
91
|
+
if (job.queued)
|
|
92
|
+
return;
|
|
93
|
+
job.prev = this.pendingTail;
|
|
94
|
+
job.next = undefined;
|
|
95
|
+
if (this.pendingTail)
|
|
96
|
+
this.pendingTail.next = job;
|
|
97
|
+
else
|
|
98
|
+
this.pendingHead = job;
|
|
99
|
+
this.pendingTail = job;
|
|
100
|
+
job.queued = true;
|
|
101
|
+
}
|
|
102
|
+
enqueueFront(job) {
|
|
103
|
+
this.removePending(job);
|
|
104
|
+
job.prev = undefined;
|
|
105
|
+
job.next = this.pendingHead;
|
|
106
|
+
if (this.pendingHead)
|
|
107
|
+
this.pendingHead.prev = job;
|
|
108
|
+
else
|
|
109
|
+
this.pendingTail = job;
|
|
110
|
+
this.pendingHead = job;
|
|
111
|
+
job.queued = true;
|
|
112
|
+
}
|
|
113
|
+
removePending(job) {
|
|
114
|
+
if (!job.queued)
|
|
115
|
+
return;
|
|
116
|
+
if (job.prev)
|
|
117
|
+
job.prev.next = job.next;
|
|
118
|
+
else
|
|
119
|
+
this.pendingHead = job.next;
|
|
120
|
+
if (job.next)
|
|
121
|
+
job.next.prev = job.prev;
|
|
122
|
+
else
|
|
123
|
+
this.pendingTail = job.prev;
|
|
124
|
+
job.prev = undefined;
|
|
125
|
+
job.next = undefined;
|
|
126
|
+
job.queued = false;
|
|
127
|
+
}
|
|
89
128
|
schedule() {
|
|
90
129
|
if (this.stopped || this.dispatch)
|
|
91
130
|
return;
|
|
@@ -94,7 +133,7 @@ export class TranscriptFactsQueue {
|
|
|
94
133
|
this.dispatch = undefined;
|
|
95
134
|
if (this.active)
|
|
96
135
|
return;
|
|
97
|
-
const next = this.
|
|
136
|
+
const next = this.pendingHead;
|
|
98
137
|
if (next)
|
|
99
138
|
this.start(next);
|
|
100
139
|
else
|
|
@@ -119,7 +158,7 @@ export class TranscriptFactsQueue {
|
|
|
119
158
|
return worker;
|
|
120
159
|
}
|
|
121
160
|
start(job) {
|
|
122
|
-
this.
|
|
161
|
+
this.removePending(job);
|
|
123
162
|
this.active = job;
|
|
124
163
|
job.attempts++;
|
|
125
164
|
try {
|
|
@@ -162,7 +201,7 @@ export class TranscriptFactsQueue {
|
|
|
162
201
|
this.settle(job, new Error(`Transcript keeps changing for ${job.runId}`));
|
|
163
202
|
}
|
|
164
203
|
else {
|
|
165
|
-
this.
|
|
204
|
+
this.enqueueFront(job);
|
|
166
205
|
this.schedule();
|
|
167
206
|
}
|
|
168
207
|
}
|
|
@@ -184,7 +223,7 @@ export class TranscriptFactsQueue {
|
|
|
184
223
|
settle(job, error, value) {
|
|
185
224
|
this.release(job);
|
|
186
225
|
this.jobs.delete(job.runId);
|
|
187
|
-
this.
|
|
226
|
+
this.removePending(job);
|
|
188
227
|
job.error = error;
|
|
189
228
|
job.value = value;
|
|
190
229
|
if (error)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transcript-facts-queue.js","sourceRoot":"","sources":["../../src/runs/transcript-facts-queue.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,oBAAoB,EAAE,MAAM,EAAoB,MAAM,qBAAqB,CAAC;AACrG,OAAO,EAAE,mBAAmB,EAAwB,MAAM,4BAA4B,CAAC;AAGvF,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,oBAAoB,CAAC,CAAC;AAC1D,MAAM,cAAc,GAAG,MAAM,CAAC;AAC9B,MAAM,YAAY,GAAG,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"transcript-facts-queue.js","sourceRoot":"","sources":["../../src/runs/transcript-facts-queue.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,oBAAoB,EAAE,MAAM,EAAoB,MAAM,qBAAqB,CAAC;AACrG,OAAO,EAAE,mBAAmB,EAAwB,MAAM,4BAA4B,CAAC;AAGvF,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,oBAAoB,CAAC,CAAC;AAC1D,MAAM,cAAc,GAAG,MAAM,CAAC;AAC9B,MAAM,YAAY,GAAG,CAAC,CAAC;AAiBvB,yFAAyF;AACzF,MAAM,OAAO,oBAAoB;IAWZ,OAAO;IACP,MAAM;IACN,MAAM;IAZR,IAAI,GAAG,IAAI,GAAG,EAAkB,CAAC;IAC1C,WAAW,CAAsB;IACjC,WAAW,CAAsB;IACjC,MAAM,CAAsB;IAC5B,MAAM,CAAsB;IAC5B,eAAe,CAA0B;IACzC,QAAQ,CAAgC;IACxC,OAAO,GAAG,KAAK,CAAC;IAExB,YACmB,OAAe,EACf,MAA6G,EAC7G,MAAyC;uBAFzC,OAAO;sBACP,MAAM;sBACN,MAAM;IACtB,CAAC;IAEJ,GAAG,CAAC,KAAa,IAAa,OAAO,IAAI,CAAC,IAAI,C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
supported: boolean;
|
|
55
|
+
installedVersion: string | null;
|
|
56
|
+
latestVersion: string | null;
|
|
57
|
+
updateAvailable: boolean;
|
|
58
|
+
phase: "activating" | "checking" | "downloading" | "extracting" | "failed" | "idle" | "removing" | "verifying";
|
|
59
|
+
error: string | null;
|
|
56
60
|
};
|
|
57
61
|
outputFormat: "json";
|
|
58
|
-
status:
|
|
62
|
+
status: 202;
|
|
59
63
|
input: {
|
|
60
64
|
param: {
|
|
61
65
|
runner: string;
|
|
@@ -67,15 +71,11 @@ export declare function createRunnerInstallRoutes(options: {
|
|
|
67
71
|
};
|
|
68
72
|
} | {
|
|
69
73
|
output: {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
latestVersion: string | null;
|
|
73
|
-
updateAvailable: boolean;
|
|
74
|
-
phase: "activating" | "checking" | "downloading" | "extracting" | "failed" | "idle" | "removing" | "verifying";
|
|
75
|
-
error: string | null;
|
|
74
|
+
error: string;
|
|
75
|
+
code?: "invalid_input" | undefined;
|
|
76
76
|
};
|
|
77
77
|
outputFormat: "json";
|
|
78
|
-
status:
|
|
78
|
+
status: 400;
|
|
79
79
|
input: {
|
|
80
80
|
param: {
|
|
81
81
|
runner: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hearsay-tools/squawk",
|
|
3
|
-
"version": "0.18.0-dev.
|
|
3
|
+
"version": "0.18.0-dev.7964",
|
|
4
4
|
"description": "Local cockpit for running and tracking AI agent tasks in your repo. Uses your logged-in `claude` CLI and `gh` — zero config, zero database.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -63,8 +63,8 @@
|
|
|
63
63
|
"devDependencies": {
|
|
64
64
|
"@babel/parser": "^8.0.8",
|
|
65
65
|
"@babel/types": "^8.0.8",
|
|
66
|
-
"@open-mercato/cezar-api-client": "0.18.0-dev.
|
|
67
|
-
"@open-mercato/cezar-contract": "0.18.0-dev.
|
|
66
|
+
"@open-mercato/cezar-api-client": "0.18.0-dev.7964",
|
|
67
|
+
"@open-mercato/cezar-contract": "0.18.0-dev.7964",
|
|
68
68
|
"@types/node": "^24.19.1",
|
|
69
69
|
"@types/ws": "^8.18.1",
|
|
70
70
|
"esbuild": "^0.28.1",
|
|
@@ -81,5 +81,5 @@
|
|
|
81
81
|
"publishConfig": {
|
|
82
82
|
"access": "public"
|
|
83
83
|
},
|
|
84
|
-
"gitHead": "
|
|
84
|
+
"gitHead": "2ce9328e447753acf7fba1f820d13870f2cfb035"
|
|
85
85
|
}
|