@hearsay-tools/squawk 0.18.0-dev.8239 → 0.18.0-dev.8243

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 (35) hide show
  1. package/dist/automations/tools.d.ts +8 -8
  2. package/dist/ci-wait/controller.d.ts +9 -7
  3. package/dist/ci-wait/controller.js +6 -2
  4. package/dist/ci-wait/controller.js.map +1 -1
  5. package/dist/core/agent-env.js +1 -0
  6. package/dist/core/agent-env.js.map +1 -1
  7. package/dist/core/native-mock.d.ts +6 -0
  8. package/dist/core/native-mock.js +26 -0
  9. package/dist/core/native-mock.js.map +1 -0
  10. package/dist/core/runner-definition.d.ts +6 -1
  11. package/dist/core/runner-definition.js.map +1 -1
  12. package/dist/core/skill-probe.js +2 -2
  13. package/dist/core/skill-probe.js.map +1 -1
  14. package/dist/delegation/routes.d.ts +75 -75
  15. package/dist/delegation/transport.d.ts +14 -14
  16. package/dist/pack-check.d.ts +3 -1
  17. package/dist/pack-check.js +7 -1
  18. package/dist/pack-check.js.map +1 -1
  19. package/dist/plugin/runner-kit.d.ts +1 -0
  20. package/dist/plugin/runner-kit.js +1 -0
  21. package/dist/plugin/runner-kit.js.map +1 -1
  22. package/dist/plugin/runtime.d.ts +1 -0
  23. package/dist/plugin/runtime.js +1 -0
  24. package/dist/plugin/runtime.js.map +1 -1
  25. package/dist/runs/run-decode.d.ts +72 -72
  26. package/dist/server/activity-routes.d.ts +23 -23
  27. package/dist/server/models-routes.d.ts +13 -13
  28. package/dist/server/server.d.ts +6 -6
  29. package/dist/server/workspace-live-routes.d.ts +6 -6
  30. package/dist/workflows/input-acknowledgement.d.ts +24 -24
  31. package/dist/workflows/run/wait-engine.d.ts +72 -72
  32. package/package.json +5 -5
  33. package/scripts/check-pack.mjs +7 -4
  34. package/scripts/copy-runner-assets.d.mts +2 -0
  35. package/scripts/copy-runner-assets.mjs +69 -0
@@ -237,30 +237,6 @@ export declare class WaitEngine {
237
237
  deadline: string;
238
238
  seconds: number;
239
239
  note?: string | undefined;
240
- } | {
241
- id: string;
242
- source: "agent" | "cezar";
243
- via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
244
- registeredAt: string;
245
- phase: "cancelled" | "delivered" | "open" | "resolved";
246
- resolvedAt?: string | undefined;
247
- deliveredAt?: string | undefined;
248
- cancelledAt?: string | undefined;
249
- turnId: string;
250
- kind: "process";
251
- deadline: string;
252
- timeoutSeconds: number;
253
- pid: number;
254
- startToken?: string | undefined;
255
- exitFile?: string | undefined;
256
- note?: string | undefined;
257
- result?: {
258
- outcome: "deadline" | "error" | "exit_file" | "exited";
259
- observedAt: string;
260
- exitCode?: number | undefined;
261
- exitFileNote?: "not-an-exit-code" | undefined;
262
- diagnostic?: string | undefined;
263
- } | undefined;
264
240
  } | {
265
241
  id: string;
266
242
  source: "agent" | "cezar";
@@ -322,6 +298,30 @@ export declare class WaitEngine {
322
298
  reason: "outcome" | "timeout";
323
299
  } | undefined;
324
300
  wakeInputId?: string | undefined;
301
+ } | {
302
+ id: string;
303
+ source: "agent" | "cezar";
304
+ via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
305
+ registeredAt: string;
306
+ phase: "cancelled" | "delivered" | "open" | "resolved";
307
+ resolvedAt?: string | undefined;
308
+ deliveredAt?: string | undefined;
309
+ cancelledAt?: string | undefined;
310
+ turnId: string;
311
+ kind: "process";
312
+ deadline: string;
313
+ timeoutSeconds: number;
314
+ pid: number;
315
+ startToken?: string | undefined;
316
+ exitFile?: string | undefined;
317
+ note?: string | undefined;
318
+ result?: {
319
+ outcome: "deadline" | "error" | "exit_file" | "exited";
320
+ observedAt: string;
321
+ exitCode?: number | undefined;
322
+ exitFileNote?: "not-an-exit-code" | undefined;
323
+ diagnostic?: string | undefined;
324
+ } | undefined;
325
325
  } | {
326
326
  id: string;
327
327
  source: "agent" | "cezar";
@@ -449,30 +449,6 @@ export declare class WaitEngine {
449
449
  deadline: string;
450
450
  seconds: number;
451
451
  note?: string | undefined;
452
- } | {
453
- id: string;
454
- source: "agent" | "cezar";
455
- via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
456
- registeredAt: string;
457
- phase: "cancelled" | "delivered" | "open" | "resolved";
458
- resolvedAt?: string | undefined;
459
- deliveredAt?: string | undefined;
460
- cancelledAt?: string | undefined;
461
- turnId: string;
462
- kind: "process";
463
- deadline: string;
464
- timeoutSeconds: number;
465
- pid: number;
466
- startToken?: string | undefined;
467
- exitFile?: string | undefined;
468
- note?: string | undefined;
469
- result?: {
470
- outcome: "deadline" | "error" | "exit_file" | "exited";
471
- observedAt: string;
472
- exitCode?: number | undefined;
473
- exitFileNote?: "not-an-exit-code" | undefined;
474
- diagnostic?: string | undefined;
475
- } | undefined;
476
452
  } | {
477
453
  id: string;
478
454
  source: "agent" | "cezar";
@@ -534,6 +510,30 @@ export declare class WaitEngine {
534
510
  reason: "outcome" | "timeout";
535
511
  } | undefined;
536
512
  wakeInputId?: string | undefined;
513
+ } | {
514
+ id: string;
515
+ source: "agent" | "cezar";
516
+ via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
517
+ registeredAt: string;
518
+ phase: "cancelled" | "delivered" | "open" | "resolved";
519
+ resolvedAt?: string | undefined;
520
+ deliveredAt?: string | undefined;
521
+ cancelledAt?: string | undefined;
522
+ turnId: string;
523
+ kind: "process";
524
+ deadline: string;
525
+ timeoutSeconds: number;
526
+ pid: number;
527
+ startToken?: string | undefined;
528
+ exitFile?: string | undefined;
529
+ note?: string | undefined;
530
+ result?: {
531
+ outcome: "deadline" | "error" | "exit_file" | "exited";
532
+ observedAt: string;
533
+ exitCode?: number | undefined;
534
+ exitFileNote?: "not-an-exit-code" | undefined;
535
+ diagnostic?: string | undefined;
536
+ } | undefined;
537
537
  } | {
538
538
  id: string;
539
539
  source: "agent" | "cezar";
@@ -660,30 +660,6 @@ export declare class WaitEngine {
660
660
  deadline: string;
661
661
  seconds: number;
662
662
  note?: string | undefined;
663
- } | {
664
- id: string;
665
- source: "agent" | "cezar";
666
- via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
667
- registeredAt: string;
668
- phase: "cancelled" | "delivered" | "open" | "resolved";
669
- resolvedAt?: string | undefined;
670
- deliveredAt?: string | undefined;
671
- cancelledAt?: string | undefined;
672
- turnId: string;
673
- kind: "process";
674
- deadline: string;
675
- timeoutSeconds: number;
676
- pid: number;
677
- startToken?: string | undefined;
678
- exitFile?: string | undefined;
679
- note?: string | undefined;
680
- result?: {
681
- outcome: "deadline" | "error" | "exit_file" | "exited";
682
- observedAt: string;
683
- exitCode?: number | undefined;
684
- exitFileNote?: "not-an-exit-code" | undefined;
685
- diagnostic?: string | undefined;
686
- } | undefined;
687
663
  } | {
688
664
  id: string;
689
665
  source: "agent" | "cezar";
@@ -745,6 +721,30 @@ export declare class WaitEngine {
745
721
  reason: "outcome" | "timeout";
746
722
  } | undefined;
747
723
  wakeInputId?: string | undefined;
724
+ } | {
725
+ id: string;
726
+ source: "agent" | "cezar";
727
+ via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
728
+ registeredAt: string;
729
+ phase: "cancelled" | "delivered" | "open" | "resolved";
730
+ resolvedAt?: string | undefined;
731
+ deliveredAt?: string | undefined;
732
+ cancelledAt?: string | undefined;
733
+ turnId: string;
734
+ kind: "process";
735
+ deadline: string;
736
+ timeoutSeconds: number;
737
+ pid: number;
738
+ startToken?: string | undefined;
739
+ exitFile?: string | undefined;
740
+ note?: string | undefined;
741
+ result?: {
742
+ outcome: "deadline" | "error" | "exit_file" | "exited";
743
+ observedAt: string;
744
+ exitCode?: number | undefined;
745
+ exitFileNote?: "not-an-exit-code" | undefined;
746
+ diagnostic?: string | undefined;
747
+ } | undefined;
748
748
  } | {
749
749
  id: string;
750
750
  source: "agent" | "cezar";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hearsay-tools/squawk",
3
- "version": "0.18.0-dev.8239",
3
+ "version": "0.18.0-dev.8243",
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",
@@ -52,7 +52,7 @@
52
52
  "test:package": "node ../../scripts/test-package.mjs",
53
53
  "typecheck": "tsc --noEmit -p tsconfig.json && tsc --noEmit -p tsconfig.test.json && tsc --noEmit -p tsconfig.scripts.json",
54
54
  "typecheck:package": "tsc --noEmit -p tsconfig.package.json",
55
- "postbuild": "node scripts/inline-contract.mjs",
55
+ "postbuild": "node scripts/inline-contract.mjs && node scripts/copy-runner-assets.mjs",
56
56
  "bench:project-probes": "node --import tsx scripts/benchmark-project-probes.mjs"
57
57
  },
58
58
  "dependencies": {
@@ -68,8 +68,8 @@
68
68
  "devDependencies": {
69
69
  "@babel/parser": "^8.0.8",
70
70
  "@babel/types": "^8.0.8",
71
- "@open-mercato/cezar-api-client": "0.18.0-dev.8239",
72
- "@open-mercato/cezar-contract": "0.18.0-dev.8239",
71
+ "@open-mercato/cezar-api-client": "0.18.0-dev.8243",
72
+ "@open-mercato/cezar-contract": "0.18.0-dev.8243",
73
73
  "@types/node": "^24.19.1",
74
74
  "@types/ws": "^8.18.1",
75
75
  "esbuild": "^0.28.1",
@@ -86,5 +86,5 @@
86
86
  "publishConfig": {
87
87
  "access": "public"
88
88
  },
89
- "gitHead": "12eb72cd42db5df43088105ac06a6e56eb7b95c3"
89
+ "gitHead": "5474d8d330f50cb4159837a6bfca6c55ad28dbfe"
90
90
  }
@@ -16,6 +16,7 @@ import path from 'node:path';
16
16
  import { fileURLToPath } from 'node:url';
17
17
  import { findPackGaps } from '../dist/pack-check.js';
18
18
  import { bundledRunnerIds } from '../dist/plugin/bundled-runners.js';
19
+ import { listRunnerAssets } from './copy-runner-assets.mjs';
19
20
 
20
21
  const repoRoot = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
21
22
 
@@ -38,9 +39,11 @@ if (files.length === 0) {
38
39
  process.exit(1);
39
40
  }
40
41
 
41
- // The bundled runners the source declares: each must ship its built plugin entry.
42
- const runnerIds = bundledRunnerIds(path.join(repoRoot, 'src/runners'));
43
- const gaps = findPackGaps(files, runnerIds);
42
+ // The bundled runners the source declares: each must ship its built plugin entry and copied .mjs assets.
43
+ const srcRunnersDir = path.join(repoRoot, 'src/runners');
44
+ const runnerIds = bundledRunnerIds(srcRunnersDir);
45
+ const runnerAssets = listRunnerAssets(srcRunnersDir, runnerIds).map((rel) => `dist/runners/${rel}`);
46
+ const gaps = findPackGaps(files, runnerIds, runnerAssets);
44
47
  if (gaps.length > 0) {
45
48
  console.error('check:pack: the npm tarball would ship a broken cockpit:');
46
49
  for (const gap of gaps) console.error(` - ${gap}`);
@@ -48,4 +51,4 @@ if (gaps.length > 0) {
48
51
  }
49
52
 
50
53
  const uiFiles = files.filter((f) => f.startsWith('web/dist/')).length;
51
- console.log(`check:pack ok — ${files.length} files, ${uiFiles} under web/dist (shell + assets present), bundled runners ${runnerIds.join(', ')}`);
54
+ console.log(`check:pack ok — ${files.length} files, ${uiFiles} under web/dist (shell + assets present), bundled runners ${runnerIds.join(', ')}, ${runnerAssets.length} runner asset(s)`);
@@ -0,0 +1,2 @@
1
+ export function listRunnerAssets(srcRunnersDir: string, runnerIds?: readonly string[]): string[];
2
+ export function copyRunnerAssets(srcRunnersDir: string, distRunnersDir: string, runnerIds?: readonly string[]): string[];
@@ -0,0 +1,69 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * Copy every non-test `.mjs` asset under `src/runners/<id>/` to the same relative path under
4
+ * `dist/runners/<id>/` (spec 2026-11-25-self-contained-runner-folders, Decision 3). `tsc` copies
5
+ * no `.mjs` files; `postbuild` runs this script after `inline-contract.mjs`, and `check:pack`
6
+ * verifies every copied asset is present in the tarball.
7
+ */
8
+ import { copyFileSync, mkdirSync, readdirSync, statSync } from 'node:fs';
9
+ import { dirname, join, relative, resolve } from 'node:path';
10
+ import { fileURLToPath } from 'node:url';
11
+
12
+ const ENTRY_FILES = ['index.mjs', 'index.js', 'index.ts'];
13
+ const SKIP_DIRS = new Set(['__fixtures__', '__tests__', 'fixtures', 'node_modules']);
14
+ const TEST_MJS = /\.(?:test|testkit|spec)\.mjs$/;
15
+
16
+ function isFile(filePath) {
17
+ try {
18
+ return statSync(filePath).isFile();
19
+ } catch {
20
+ return false;
21
+ }
22
+ }
23
+
24
+ function discoverBundledRunnerIds(srcRunnersDir) {
25
+ return readdirSync(srcRunnersDir, { withFileTypes: true })
26
+ .filter((entry) => entry.isDirectory() && ENTRY_FILES.some((file) => isFile(join(srcRunnersDir, entry.name, file))))
27
+ .map((entry) => entry.name)
28
+ .sort();
29
+ }
30
+
31
+ /**
32
+ * List POSIX paths relative to `srcRunnersDir` (e.g. `pi/extensions/pi-ci-wait.mjs`) for every
33
+ * non-test `.mjs` asset under the bundled runner folders.
34
+ */
35
+ export function listRunnerAssets(srcRunnersDir, runnerIds) {
36
+ const ids = runnerIds ?? discoverBundledRunnerIds(srcRunnersDir);
37
+ const assets = [];
38
+ const walk = (dir) => {
39
+ for (const entry of readdirSync(dir, { withFileTypes: true })) {
40
+ const fullPath = join(dir, entry.name);
41
+ if (entry.isDirectory()) {
42
+ if (!SKIP_DIRS.has(entry.name)) walk(fullPath);
43
+ } else if (entry.isFile() && entry.name.endsWith('.mjs') && !TEST_MJS.test(entry.name)) {
44
+ assets.push(relative(srcRunnersDir, fullPath).replaceAll('\\', '/'));
45
+ }
46
+ }
47
+ };
48
+ for (const id of ids) walk(join(srcRunnersDir, id));
49
+ return assets.sort();
50
+ }
51
+
52
+ /** Copy every listed runner `.mjs` asset from `srcRunnersDir` into `distRunnersDir`. */
53
+ export function copyRunnerAssets(srcRunnersDir, distRunnersDir, runnerIds) {
54
+ const assets = listRunnerAssets(srcRunnersDir, runnerIds);
55
+ for (const rel of assets) {
56
+ const dest = join(distRunnersDir, rel);
57
+ mkdirSync(dirname(dest), { recursive: true });
58
+ copyFileSync(join(srcRunnersDir, rel), dest);
59
+ }
60
+ return assets;
61
+ }
62
+
63
+ if (process.argv[1] && resolve(process.argv[1]) === fileURLToPath(import.meta.url)) {
64
+ const pkgRoot = resolve(dirname(fileURLToPath(import.meta.url)), '..');
65
+ const srcRunnersDir = process.argv[2] ? resolve(process.argv[2]) : join(pkgRoot, 'src', 'runners');
66
+ const distRunnersDir = process.argv[3] ? resolve(process.argv[3]) : join(pkgRoot, 'dist', 'runners');
67
+ const copied = copyRunnerAssets(srcRunnersDir, distRunnersDir);
68
+ console.log(`copy-runner-assets ok — copied ${copied.length} runner asset(s)`);
69
+ }