@hearsay-tools/squawk 0.18.0-pr4114.7891 → 0.18.0-pr4115.7903

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 (48) hide show
  1. package/dist/ci-wait/controller.d.ts +42 -42
  2. package/dist/cli-dispatch.d.ts +1 -2
  3. package/dist/cli-dispatch.js +7 -3
  4. package/dist/cli-dispatch.js.map +1 -1
  5. package/dist/core/agent-runner.d.ts +2 -2
  6. package/dist/core/runner-definition.d.ts +3 -1
  7. package/dist/core/runner-definition.js.map +1 -1
  8. package/dist/core/secret-redaction.d.ts +2 -0
  9. package/dist/core/secret-redaction.js +11 -3
  10. package/dist/core/secret-redaction.js.map +1 -1
  11. package/dist/delegation/routes.d.ts +81 -81
  12. package/dist/delegation/transport.d.ts +21 -21
  13. package/dist/index.js +42 -36
  14. package/dist/index.js.map +1 -1
  15. package/dist/legacy-runs.d.ts +6 -5
  16. package/dist/legacy-runs.js +16 -3
  17. package/dist/legacy-runs.js.map +1 -1
  18. package/dist/runners/acp/events.d.ts +2 -1
  19. package/dist/runners/acp/events.js +4 -1
  20. package/dist/runners/acp/events.js.map +1 -1
  21. package/dist/runners/acp/session.d.ts +9 -1
  22. package/dist/runners/acp/session.js +35 -7
  23. package/dist/runners/acp/session.js.map +1 -1
  24. package/dist/runners/antigravity/antigravity-session.d.ts +3 -2
  25. package/dist/runners/antigravity/antigravity-session.js +7 -6
  26. package/dist/runners/antigravity/antigravity-session.js.map +1 -1
  27. package/dist/runners/antigravity/facts.js +2 -0
  28. package/dist/runners/antigravity/facts.js.map +1 -1
  29. package/dist/runners/antigravity/mock.d.ts +9 -9
  30. package/dist/runners/antigravity/mock.js +9 -9
  31. package/dist/runners/antigravity/mock.js.map +1 -1
  32. package/dist/runs/run-redaction.d.ts +2 -0
  33. package/dist/runs/run-redaction.js +18 -7
  34. package/dist/runs/run-redaction.js.map +1 -1
  35. package/dist/server/activity-routes.d.ts +23 -23
  36. package/dist/server/live-routes.d.ts +6 -6
  37. package/dist/server/models-routes.d.ts +13 -13
  38. package/dist/server/provider-sign-in-routes.d.ts +2 -2
  39. package/dist/server/reports-api.d.ts +2 -2
  40. package/dist/server/runner-install-routes.d.ts +10 -10
  41. package/dist/server/runners-routes.d.ts +10 -10
  42. package/dist/server/server.d.ts +1613 -1613
  43. package/dist/subcommands.d.ts +2 -0
  44. package/dist/subcommands.js +23 -2
  45. package/dist/subcommands.js.map +1 -1
  46. package/dist/task-cli/cli.js +2 -2
  47. package/dist/task-cli/cli.js.map +1 -1
  48. package/package.json +4 -4
@@ -3,29 +3,40 @@
3
3
  * text before they reach disk or the live wire. `RunStore` keeps one of these as `store.redaction`.
4
4
  */
5
5
  import { productEnv } from '../core/product-env.js';
6
- import { collectSecretValues, redactDeep } from '../core/secret-redaction.js';
6
+ import { collectSecretValues, redactDeep, redactDeepWith, redactSecrets } from '../core/secret-redaction.js';
7
7
  import { redactText } from './record-write-rules.js';
8
8
  export class RunRedaction {
9
9
  /** Lazily-collected concrete secret values from the host env (#427). */
10
10
  secretValues = null;
11
11
  /** Controller-issued tokens never persist, including when host-secret redaction is disabled. */
12
12
  sessionSecrets = new Set();
13
- registerSessionSecret(value) { this.sessionSecrets.add(value); }
14
- containsSessionSecret(value) { return [...this.sessionSecrets].some(secret => value.includes(secret)); }
13
+ /** `sessionSecrets` in insertion order; rebuilt only when a new secret is registered. */
14
+ sessionList = [];
15
+ registerSessionSecret(value) {
16
+ if (this.sessionSecrets.has(value))
17
+ return;
18
+ this.sessionSecrets.add(value);
19
+ this.sessionList = [...this.sessionSecrets];
20
+ }
21
+ containsSessionSecret(value) { return this.sessionList.some(secret => value.includes(secret)); }
15
22
  /**
16
23
  * Scrub known credential values / token shapes from an event before it is
17
24
  * persisted or fanned out. On by default; `CEZ_REDACT_SECRETS=0` opts out.
18
25
  */
19
26
  redact(event) {
20
- const safe = this.sessionSecrets.size ? redactDeep(event, [...this.sessionSecrets]) : event;
27
+ const session = this.sessionList;
21
28
  if (productEnv('REDACT_SECRETS') === '0')
22
- return safe;
23
- return redactDeep(safe, this.hostSecrets());
29
+ return session.length ? redactDeep(event, session) : event;
30
+ const host = this.hostSecrets();
31
+ if (!session.length)
32
+ return redactDeep(event, host);
33
+ // One copy for both scrubs; each string leaf gets the same two passes in the same order.
34
+ return redactDeepWith(event, text => redactSecrets(redactSecrets(text, session), host));
24
35
  }
25
36
  /** Best-effort scrub of one free-text string bound for `runs.json`. Honors
26
37
  * the `CEZ_REDACT_SECRETS=0` opt-out itself so every caller inherits it. */
27
38
  redactText(text) {
28
- return redactText(text, [...this.sessionSecrets], () => this.hostSecrets());
39
+ return redactText(text, this.sessionList, () => this.hostSecrets());
29
40
  }
30
41
  hostSecrets() {
31
42
  if (this.secretValues === null)
@@ -1 +1 @@
1
- {"version":3,"file":"run-redaction.js","sourceRoot":"","sources":["../../src/runs/run-redaction.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AACpD,OAAO,EAAE,mBAAmB,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AAE9E,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAGrD,MAAM,OAAO,YAAY;IACvB,wEAAwE;IAChE,YAAY,GAA6B,IAAI,CAAC;IACtD,gGAAgG;IAC/E,cAAc,GAAG,IAAI,GAAG,EAAU,CAAC;IACpD,qBAAqB,CAAC,KAAa,IAAU,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;IAC9E,qBAAqB,CAAC,KAAa,IAAa,OAAO,CAAC,GAAG,IAAI,CAAC,cAAc,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;IAEzH;;;OAGG;IACH,MAAM,CAAqB,KAAQ;QACjC,MAAM,IAAI,GAAG,IAAI,C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ps: ActivityRouteDeps): import("hono/hono-base").HonoBase<import("hono/types").BlankEnv, {
59
59
  "/workspace/activity": {
60
60
  $get: {
61
+ output: {
62
+ error: string;
63
+ code?: "invalid_input" | undefined;
64
+ };
65
+ outputFormat: "json";
66
+ status: 400;
67
+ input: {
68
+ query: {
69
+ project?: string | undefined;
70
+ };
71
+ };
72
+ } | {
73
+ output: {
74
+ error: string;
75
+ };
76
+ outputFormat: "json";
77
+ status: 404 | 409 | 503;
78
+ input: {
79
+ query: {
80
+ project?: string | undefined;
81
+ };
82
+ };
83
+ } | {
61
84
  output: {
62
85
  generatedAt: string;
63
86
  projects: {
@@ -288,29 +311,6 @@ export declare function createActivityRoutes(routeDeps: ActivityRouteDeps): impo
288
311
  project?: string | undefined;
289
312
  };
290
313
  };
291
- } | {
292
- output: {
293
- error: string;
294
- code?: "invalid_input" | undefined;
295
- };
296
- outputFormat: "json";
297
- status: 400;
298
- input: {
299
- query: {
300
- project?: string | undefined;
301
- };
302
- };
303
- } | {
304
- output: {
305
- error: string;
306
- };
307
- outputFormat: "json";
308
- status: 404 | 409 | 503;
309
- input: {
310
- query: {
311
- project?: string | undefined;
312
- };
313
- };
314
314
  };
315
315
  };
316
316
  }, "/", "/workspace/activity">;
@@ -16,12 +16,6 @@ export declare function createLiveRoutes({ resolveProject, serverGeneration, res
16
16
  output: {
17
17
  generation: string;
18
18
  results: ({
19
- projectId: string;
20
- runId: string;
21
- type: "error" | "reset";
22
- status: 400 | 404 | 409 | 413 | 503;
23
- error: string;
24
- } | {
25
19
  projectId: string;
26
20
  runId: string;
27
21
  type: "batch";
@@ -35,6 +29,12 @@ export declare function createLiveRoutes({ resolveProject, serverGeneration, res
35
29
  cursor: string;
36
30
  afterSeq: number;
37
31
  hasMore: boolean;
32
+ } | {
33
+ projectId: string;
34
+ runId: string;
35
+ type: "error" | "reset";
36
+ status: 400 | 404 | 409 | 413 | 503;
37
+ error: string;
38
38
  })[];
39
39
  };
40
40
  outputFormat: "json";
@@ -30,10 +30,19 @@ export declare function createModelsRoutes(options: {
30
30
  };
31
31
  } | {
32
32
  output: {
33
- error: string;
33
+ runner: string;
34
+ models: {
35
+ id: string;
36
+ label: string;
37
+ description: string;
38
+ effortLevels?: import('../contract/index.js').EffortLevel[];
39
+ }[];
40
+ source: import("../core/runner-model-catalog.ts").ModelCatalogSource;
41
+ stale: boolean;
42
+ reason?: string;
34
43
  };
35
44
  outputFormat: "json";
36
- status: 400;
45
+ status: import("hono/utils/http-status").ContentfulStatusCode;
37
46
  input: {
38
47
  query: {
39
48
  runner: string | string[];
@@ -54,19 +63,10 @@ export declare function createModelsRoutes(options: {
54
63
  };
55
64
  } | {
56
65
  output: {
57
- runner: string;
58
- models: {
59
- id: string;
60
- label: string;
61
- description: string;
62
- effortLevels?: import('../contract/index.js').EffortLevel[];
63
- }[];
64
- source: import("../core/runner-model-catalog.ts").ModelCatalogSource;
65
- stale: boolean;
66
- reason?: string;
66
+ error: string;
67
67
  };
68
68
  outputFormat: "json";
69
- status: import("hono/utils/http-status").ContentfulStatusCode;
69
+ status: 400;
70
70
  input: {
71
71
  query: {
72
72
  runner: string | string[];
@@ -18,7 +18,7 @@ export declare function createProviderSignInRoutes(options: {
18
18
  error: string;
19
19
  };
20
20
  outputFormat: "json";
21
- status: 409;
21
+ status: 400;
22
22
  input: {
23
23
  json: {
24
24
  provider: string;
@@ -30,7 +30,7 @@ export declare function createProviderSignInRoutes(options: {
30
30
  error: string;
31
31
  };
32
32
  outputFormat: "json";
33
- status: 400;
33
+ status: 409;
34
34
  input: {
35
35
  json: {
36
36
  provider: string;
@@ -40,7 +40,7 @@ export declare const reportsRoutes: import("hono/hono-base").HonoBase<ProjectApi
40
40
  error: string;
41
41
  };
42
42
  outputFormat: "json";
43
- status: 400;
43
+ status: 409;
44
44
  input: {
45
45
  query: {
46
46
  q?: string | undefined;
@@ -53,7 +53,7 @@ export declare const reportsRoutes: import("hono/hono-base").HonoBase<ProjectApi
53
53
  error: string;
54
54
  };
55
55
  outputFormat: "json";
56
- status: 409;
56
+ status: 400;
57
57
  input: {
58
58
  query: {
59
59
  q?: string | undefined;
@@ -51,11 +51,15 @@ export declare function createRunnerInstallRoutes(options: {
51
51
  "/runner-install/:runner": {
52
52
  $post: {
53
53
  output: {
54
- error: string;
55
- code?: "invalid_input" | undefined;
54
+ 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: 400;
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
- supported: boolean;
71
- installedVersion: string | null;
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: 202;
78
+ status: 400;
79
79
  input: {
80
80
  param: {
81
81
  runner: string;
@@ -58,15 +58,11 @@ export declare function createRunnersRoutes(options: {
58
58
  "/runner-install/:runner": {
59
59
  $post: {
60
60
  output: {
61
- supported: boolean;
62
- installedVersion: string | null;
63
- latestVersion: string | null;
64
- updateAvailable: boolean;
65
- phase: "activating" | "checking" | "downloading" | "extracting" | "failed" | "idle" | "removing" | "verifying";
66
- error: string | null;
61
+ error: string;
62
+ code?: "invalid_input" | undefined;
67
63
  };
68
64
  outputFormat: "json";
69
- status: 202;
65
+ status: 400;
70
66
  input: {
71
67
  param: {
72
68
  runner: string;
@@ -78,11 +74,15 @@ export declare function createRunnersRoutes(options: {
78
74
  };
79
75
  } | {
80
76
  output: {
81
- error: string;
82
- code?: "invalid_input" | undefined;
77
+ supported: boolean;
78
+ installedVersion: string | null;
79
+ latestVersion: string | null;
80
+ updateAvailable: boolean;
81
+ phase: "activating" | "checking" | "downloading" | "extracting" | "failed" | "idle" | "removing" | "verifying";
82
+ error: string | null;
83
83
  };
84
84
  outputFormat: "json";
85
- status: 400;
85
+ status: 202;
86
86
  input: {
87
87
  param: {
88
88
  runner: string;