@cnc-tools/storm 0.12.0 → 0.14.0
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/application.js +5 -1
- package/dist/bin/storm.js +6 -2
- package/dist/build-info.js +1 -1
- package/dist/chunks/{chunk-FK4RLDEK.js → chunk-27P2QSIM.js} +1 -1
- package/dist/chunks/{chunk-ODQHQJLE.js → chunk-5ED3IDUJ.js} +749 -1121
- package/dist/chunks/{chunk-FSP3SJ35.js → chunk-5TMHYH7G.js} +16 -46
- package/dist/chunks/{chunk-Y3BUNNRG.js → chunk-BFLYGMG3.js} +12 -7
- package/dist/chunks/{chunk-LQKNI3EG.js → chunk-BRUIATTR.js} +6 -6
- package/dist/chunks/{chunk-RYRJNHL7.js → chunk-HOKDKP5A.js} +3 -9
- package/dist/chunks/{chunk-SXW6XN4R.js → chunk-IVRRGGCD.js} +60 -20
- package/dist/chunks/{chunk-TMQQYHUX.js → chunk-QBR5VHJ7.js} +1 -1
- package/dist/chunks/{chunk-YT5OROR7.js → chunk-RA4L2ACU.js} +12 -2
- package/dist/chunks/{chunk-TEEZL3GA.js → chunk-RKONDLPS.js} +17 -71
- package/dist/chunks/{chunk-IYM44FUX.js → chunk-UC6DULWY.js} +2 -2
- package/dist/chunks/{chunk-4XT5RC5T.js → chunk-XPCUINWS.js} +6 -42
- package/dist/chunks/{chunk-U7M3ZB3Z.js → chunk-YBPTMJUM.js} +123 -180
- package/dist/chunks/{chunk-ISGQJIQM.js → chunk-Z5OXOZD3.js} +125 -83
- package/dist/chunks/{chunk-7D6LC5JY.js → chunk-ZH5R7W4A.js} +7 -39
- package/dist/chunks/{live-app-AZ5N5HBD.js → live-app-FBVWUUMT.js} +7 -7
- package/dist/commands/exec/command.d.ts +4 -90
- package/dist/commands/exec/command.js +15 -41
- package/dist/commands/exec/define-run-command.d.ts +19 -100
- package/dist/commands/exec/define-run-command.js +48 -15
- package/dist/commands/exec/driver-plan.d.ts +24 -16
- package/dist/commands/exec/driver-plan.js +34 -15
- package/dist/commands/exec/driver-refusals.js +7 -6
- package/dist/commands/exec/exec-words.d.ts +1 -1
- package/dist/commands/exec/exec-words.js +8 -2
- package/dist/commands/exec/final-results.d.ts +39 -0
- package/dist/commands/exec/final-results.js +29 -0
- package/dist/commands/exec/live-view.js +18 -22
- package/dist/commands/exec/metadata.js +1 -1
- package/dist/commands/exec/outcomes.d.ts +15 -109
- package/dist/commands/exec/outcomes.js +25 -39
- package/dist/commands/exec/plan-run.d.ts +11 -3
- package/dist/commands/exec/plan-run.js +3 -2
- package/dist/commands/exec/progress.d.ts +3 -19
- package/dist/commands/exec/progress.js +16 -60
- package/dist/commands/exec/run-command.d.ts +5 -24
- package/dist/commands/exec/run-command.js +32 -84
- package/dist/commands/exec/run-metadata.d.ts +0 -6
- package/dist/commands/exec/run-metadata.js +2 -8
- package/dist/commands/exec/snapshot-text.d.ts +7 -16
- package/dist/commands/exec/snapshot-text.js +9 -49
- package/dist/commands/exec/test-plan.d.ts +2 -1
- package/dist/commands/exec/test-plan.js +13 -4
- package/dist/commands/exec/tests-summary.d.ts +2 -2
- package/dist/commands/exec/view.js +2 -12
- package/dist/commands/exec/worker-chart.d.ts +1 -1
- package/dist/commands/playwright/command.d.ts +12 -97
- package/dist/commands/playwright/command.js +14 -14
- package/dist/commands/playwright/metadata.js +2 -2
- package/dist/commands/runs/facts.d.ts +1 -37
- package/dist/commands/runs/facts.js +4 -36
- package/dist/commands/runs/list/command.d.ts +0 -72
- package/dist/commands/runs/list/command.js +6 -6
- package/dist/commands/runs/list/outcomes.d.ts +0 -36
- package/dist/commands/runs/logs/command.js +6 -6
- package/dist/commands/runs/show/command.d.ts +2 -74
- package/dist/commands/runs/show/command.js +16 -43
- package/dist/commands/runs/show/metadata.js +1 -1
- package/dist/commands/runs/show/outcomes.d.ts +1 -37
- package/dist/commands/runs/show/outcomes.js +8 -42
- package/dist/commands/snapshots/build/command.d.ts +14 -411
- package/dist/commands/snapshots/build/command.js +59 -234
- package/dist/commands/snapshots/build/metadata.js +10 -7
- package/dist/commands/snapshots/build/outcomes.d.ts +11 -241
- package/dist/commands/snapshots/build/outcomes.js +29 -196
- package/dist/commands/snapshots/list/command.d.ts +2 -36
- package/dist/commands/snapshots/list/command.js +20 -56
- package/dist/commands/snapshots/list/metadata.js +1 -1
- package/dist/commands/snapshots/list/outcomes.d.ts +2 -37
- package/dist/commands/snapshots/list/outcomes.js +13 -53
- package/dist/commands/vitest/command.d.ts +14 -98
- package/dist/commands/vitest/command.js +14 -14
- package/dist/commands/vitest/metadata.js +2 -2
- package/dist/config/resolve.d.ts +1 -1
- package/dist/config/resolve.js +2 -1
- package/dist/config/schema.d.ts +8 -0
- package/dist/config/schema.js +5 -4
- package/dist/core/events.d.ts +5 -6
- package/dist/core/run-state.d.ts +7 -29
- package/dist/core/run-state.js +3 -26
- package/dist/core/run.d.ts +6 -14
- package/dist/core/run.js +17 -28
- package/dist/extensions/playwright/driver.js +17 -10
- package/dist/extensions/testserver/commands/pool/create/command.js +4 -4
- package/dist/extensions/testserver/commands/pool/list/command.js +2 -2
- package/dist/extensions/testserver/definition.d.ts +1 -1
- package/dist/extensions/testserver/extension.d.ts +1 -1
- package/dist/extensions/testserver/options/rules.d.ts +3 -3
- package/dist/extensions/testserver/options/rules.js +5 -5
- package/dist/extensions/testserver/resource.d.ts +1 -1
- package/dist/extensions/testserver/vercel-cli/index.d.ts +1 -0
- package/dist/extensions/testserver/vercel-cli/index.js +1 -0
- package/dist/extensions/testserver/vercel-cli/report.js +5 -2
- package/dist/extensions/testserver/vercel-cli/session-id.d.ts +8 -0
- package/dist/extensions/testserver/vercel-cli/session-id.js +16 -0
- package/dist/extensions/testserver/vitest/config.d.ts +2 -2
- package/dist/extensions/testserver/vitest/config.js +2 -2
- package/dist/extensions/testserver/vitest/container-scope.d.ts +25 -16
- package/dist/extensions/testserver/vitest/container-scope.js +32 -13
- package/dist/extensions/testserver/vitest/diagnostics.d.ts +5 -4
- package/dist/extensions/testserver/vitest/diagnostics.js +15 -8
- package/dist/extensions/testserver/vitest/fixtures.d.ts +10 -1
- package/dist/extensions/testserver/vitest/fixtures.js +36 -10
- package/dist/extensions/testserver/vitest/types.d.ts +9 -0
- package/dist/extensions/vitest/driver.js +28 -14
- package/dist/extensions/vitest/plan/gateways.d.ts +28 -5
- package/dist/extensions/vitest/plan/gateways.js +2 -2
- package/dist/extensions/vitest/plan/list-output.d.ts +5 -0
- package/dist/extensions/vitest/plan/list-output.js +23 -9
- package/dist/extensions/vitest/plan/live/list-gateway.d.ts +3 -2
- package/dist/extensions/vitest/plan/live/list-gateway.js +77 -64
- package/dist/extensions/vitest/plan/plan-over.d.ts +19 -7
- package/dist/extensions/vitest/plan/plan-over.js +18 -7
- package/dist/extensions/vitest/plan/plan.d.ts +14 -5
- package/dist/extensions/vitest/plan/plan.js +23 -9
- package/dist/extensions.d.ts +2 -2
- package/dist/run-directory/index.d.ts +1 -1
- package/dist/run-directory/index.js +0 -1
- package/dist/run-directory/plan.d.ts +3 -2
- package/dist/run-directory/plan.js +6 -3
- package/dist/run-directory/recording.js +2 -2
- package/dist/run-directory/run-record.d.ts +18 -135
- package/dist/run-directory/run-record.js +8 -68
- package/dist/runner/build-snapshots.d.ts +50 -114
- package/dist/runner/build-snapshots.js +70 -159
- package/dist/runner/events.d.ts +4 -88
- package/dist/runner/gateways.d.ts +5 -23
- package/dist/runner/index.d.ts +5 -6
- package/dist/runner/index.js +1 -1
- package/dist/runner/live/snapshot-records.js +7 -18
- package/dist/runner/prepare.d.ts +11 -22
- package/dist/runner/prepare.js +6 -17
- package/dist/runner/ready.d.ts +16 -45
- package/dist/runner/ready.js +34 -59
- package/dist/runner/recipe.d.ts +5 -45
- package/dist/runner/recipe.js +0 -41
- package/dist/runner/sandboxed-command.d.ts +5 -3
- package/dist/runner/sandboxed-command.js +10 -4
- package/dist/runner/scope.d.ts +8 -25
- package/dist/runner/scope.js +4 -8
- package/dist/runner/session.d.ts +18 -65
- package/dist/runner/session.js +15 -83
- package/dist/runner/snapshot-build.d.ts +2 -2
- package/dist/runner/snapshot-cache.d.ts +22 -74
- package/dist/runner/snapshot-cache.js +15 -107
- package/dist/runner/snapshot-inspect.d.ts +9 -13
- package/dist/runner/snapshot-inspect.js +48 -57
- package/dist/runner/snapshot-key.d.ts +9 -14
- package/dist/runner/snapshot-key.js +15 -22
- package/dist/sdk/extension/driver.d.ts +32 -6
- package/dist/sdk/extension/driver.js +12 -2
- package/dist/sdk/extension/index.d.ts +1 -1
- package/dist/sdk/extension/index.js +2 -1
- package/dist/sdk/extension/resource-definition.d.ts +6 -5
- package/dist/vendor/testserver-sdk/container/api-request.d.ts +2 -3
- package/dist/vendor/testserver-sdk/container/api-request.js +2 -3
- package/dist/vendor/testserver-sdk/container/container.d.ts +12 -2
- package/dist/vendor/testserver-sdk/container/container.js +10 -7
- package/dist/vendor/testserver-sdk/container/recorder.d.ts +29 -7
- package/dist/vendor/testserver-sdk/container/recorder.js +26 -14
- package/dist/vendor/testserver-sdk/index.d.ts +1 -1
- package/dist/vendor/testserver-sdk/index.js +1 -1
- package/dist/vendor/testserver-sdk/proxy/exchange.d.ts +24 -5
- package/dist/vendor/testserver-sdk/proxy/exchange.js +43 -25
- package/dist/vendor/testserver-sdk/proxy/faulted-exchange.js +15 -10
- package/dist/vendor/testserver-sdk/proxy/faults.d.ts +6 -5
- package/dist/vendor/testserver-sdk/proxy/proxy.d.ts +10 -1
- package/dist/vendor/testserver-sdk/proxy/proxy.js +5 -3
- package/dist/vendor/testserver-sdk/proxy/records.d.ts +17 -17
- package/dist/vendor/testserver-sdk/proxy/records.js +18 -17
- package/dist/vendor/testserver-sdk/records/body.d.ts +7 -9
- package/dist/vendor/testserver-sdk/records/body.js +10 -15
- package/dist/vendor/testserver-sdk/records/headers.d.ts +79 -0
- package/dist/vendor/testserver-sdk/records/headers.js +162 -0
- package/dist/vendor/testserver-sdk/records/index.d.ts +2 -1
- package/dist/vendor/testserver-sdk/records/index.js +4 -2
- package/dist/vendor/testserver-sdk/records/records.d.ts +19 -10
- package/package.json +5 -4
- package/skills/overview.md +5 -5
- package/skills/read-run-output.md +8 -9
- package/dist/runner/snapshot-save.d.ts +0 -70
- package/dist/runner/snapshot-save.js +0 -160
- package/dist/runner/snapshot-start.d.ts +0 -25
- package/dist/runner/snapshot-start.js +0 -16
- package/skills/testserver-builds.md +0 -82
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* `storm vitest`: the run command of storm's Vitest driver, which the Vitest extension brings and the registry gives by
|
|
3
|
-
* name (`driverNamed`, `src/extensions.ts`). It runs `vitest run <args>` in a run, after counting the
|
|
4
|
-
*
|
|
3
|
+
* name (`driverNamed`, `src/extensions.ts`). It runs `vitest run <args>` in a run, after counting, where the config
|
|
4
|
+
* file sets `testPlan`, the test files with `vitest list --filesOnly`, or each test with `vitest list` under
|
|
5
|
+
* `--count-tests`. Its usage, its arguments' help, its examples and what its refusals say are the driver's; `metadata.ts`
|
|
5
6
|
* holds its summary and description as plain text, so group help loads no driver.
|
|
6
7
|
*/
|
|
7
8
|
declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod").ZodObject<{
|
|
@@ -12,12 +13,11 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
12
13
|
mint: "mint";
|
|
13
14
|
}>>;
|
|
14
15
|
unsandboxed: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
15
|
-
saveDevSnapshot: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
16
|
-
noReuseDevSnapshot: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
17
16
|
showOutput: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
18
17
|
keepSandbox: import("zod").ZodOptional<import("zod").ZodString>;
|
|
19
18
|
verbose: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
20
19
|
args: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodString>>;
|
|
20
|
+
countTests?: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
21
21
|
}, import("zod/v4/core").$strip>, import("@vercel/clinkr").Outcomes<{
|
|
22
22
|
ran: import("zod").ZodObject<{
|
|
23
23
|
version: import("zod").ZodString;
|
|
@@ -32,48 +32,13 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
32
32
|
runner: import("zod").ZodNullable<import("zod").ZodObject<{
|
|
33
33
|
snapshotId: import("zod").ZodString;
|
|
34
34
|
base: import("zod").ZodString;
|
|
35
|
-
|
|
36
|
-
snapshotHead: import("zod").ZodNullable<import("zod").ZodString>;
|
|
37
|
-
snapshotKind: import("zod").ZodEnum<{
|
|
38
|
-
base: "base";
|
|
39
|
-
dev: "dev";
|
|
40
|
-
}>;
|
|
41
|
-
snapshotBuiltAt: import("zod").ZodString;
|
|
42
|
-
builtBehind: import("zod").ZodNullable<import("zod").ZodNumber>;
|
|
35
|
+
builtBehind: import("zod").ZodNumber;
|
|
43
36
|
uploadBytes: import("zod").ZodNumber;
|
|
44
37
|
built: import("zod").ZodBoolean;
|
|
45
38
|
vcpus: import("zod").ZodNumber;
|
|
46
39
|
region: import("zod").ZodString;
|
|
47
40
|
runtime: import("zod").ZodString;
|
|
48
41
|
buildMs: import("zod").ZodNumber;
|
|
49
|
-
save: import("zod").ZodNullable<import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
50
|
-
kind: import("zod").ZodLiteral<"saved">;
|
|
51
|
-
snapshotId: import("zod").ZodString;
|
|
52
|
-
base: import("zod").ZodString;
|
|
53
|
-
branch: import("zod").ZodNullable<import("zod").ZodString>;
|
|
54
|
-
head: import("zod").ZodString;
|
|
55
|
-
ms: import("zod").ZodNumber;
|
|
56
|
-
sizeBytes: import("zod").ZodNumber;
|
|
57
|
-
entryWritten: import("zod").ZodBoolean;
|
|
58
|
-
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
59
|
-
kind: import("zod").ZodLiteral<"failed">;
|
|
60
|
-
step: import("zod").ZodEnum<{
|
|
61
|
-
"save-snapshot": "save-snapshot";
|
|
62
|
-
scrub: "scrub";
|
|
63
|
-
}>;
|
|
64
|
-
message: import("zod").ZodString;
|
|
65
|
-
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
66
|
-
kind: import("zod").ZodLiteral<"stopped">;
|
|
67
|
-
}, import("zod/v4/core").$strip>], "kind">>;
|
|
68
|
-
noSaveReason: import("zod").ZodNullable<import("zod").ZodEnum<{
|
|
69
|
-
"already-saved": "already-saved";
|
|
70
|
-
ci: "ci";
|
|
71
|
-
"command-failed": "command-failed";
|
|
72
|
-
"keep-sandbox": "keep-sandbox";
|
|
73
|
-
"no-save-flag": "no-save-flag";
|
|
74
|
-
"not-trusted": "not-trusted";
|
|
75
|
-
recipe: "recipe";
|
|
76
|
-
}>>;
|
|
77
42
|
}, import("zod/v4/core").$strip>>;
|
|
78
43
|
timeline: import("zod").ZodObject<{
|
|
79
44
|
startedAt: import("zod").ZodString;
|
|
@@ -118,8 +83,9 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
118
83
|
}, import("zod/v4/core").$strip>>;
|
|
119
84
|
}, import("zod/v4/core").$strip>;
|
|
120
85
|
runId: import("zod").ZodNullable<import("zod").ZodString>;
|
|
121
|
-
|
|
122
|
-
|
|
86
|
+
noFinalTestResults: import("zod").ZodBoolean;
|
|
87
|
+
plan: import("zod").ZodExactOptional<import("zod").ZodObject<{
|
|
88
|
+
tests: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
123
89
|
files: import("zod").ZodNumber;
|
|
124
90
|
options: import("zod").ZodArray<import("zod").ZodObject<{
|
|
125
91
|
path: import("zod").ZodString;
|
|
@@ -130,7 +96,7 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
130
96
|
flag: "flag";
|
|
131
97
|
}>;
|
|
132
98
|
}, import("zod/v4/core").$strip>>;
|
|
133
|
-
}, import("zod/v4/core").$strip
|
|
99
|
+
}, import("zod/v4/core").$strip>>;
|
|
134
100
|
}, import("zod/v4/core").$strip>;
|
|
135
101
|
}, {
|
|
136
102
|
ran: unknown;
|
|
@@ -139,10 +105,6 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
139
105
|
flags: string[];
|
|
140
106
|
configFile: string | null;
|
|
141
107
|
}]>;
|
|
142
|
-
devSnapshotsNotTrusted: import("@vercel/clinkr").SharedError<"dev_snapshots_not_trusted", [data: {
|
|
143
|
-
flag: string;
|
|
144
|
-
configFile: string | null;
|
|
145
|
-
}]>;
|
|
146
108
|
driverPlanFailed: import("@vercel/clinkr").SharedError<"driver_plan_failed", [data: {
|
|
147
109
|
driver: string;
|
|
148
110
|
kind: "exited" | "start-failed" | "timed-out" | "unreadable-output";
|
|
@@ -262,10 +224,6 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
262
224
|
flags: string[];
|
|
263
225
|
configFile: string | null;
|
|
264
226
|
}]>;
|
|
265
|
-
readonly devSnapshotsNotTrusted: import("@vercel/clinkr").SharedError<"dev_snapshots_not_trusted", [data: {
|
|
266
|
-
flag: string;
|
|
267
|
-
configFile: string | null;
|
|
268
|
-
}]>;
|
|
269
227
|
readonly driverPlanFailed: import("@vercel/clinkr").SharedError<"driver_plan_failed", [data: {
|
|
270
228
|
driver: string;
|
|
271
229
|
kind: "exited" | "start-failed" | "timed-out" | "unreadable-output";
|
|
@@ -394,48 +352,13 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
394
352
|
runner: import("zod").ZodNullable<import("zod").ZodObject<{
|
|
395
353
|
snapshotId: import("zod").ZodString;
|
|
396
354
|
base: import("zod").ZodString;
|
|
397
|
-
|
|
398
|
-
snapshotHead: import("zod").ZodNullable<import("zod").ZodString>;
|
|
399
|
-
snapshotKind: import("zod").ZodEnum<{
|
|
400
|
-
base: "base";
|
|
401
|
-
dev: "dev";
|
|
402
|
-
}>;
|
|
403
|
-
snapshotBuiltAt: import("zod").ZodString;
|
|
404
|
-
builtBehind: import("zod").ZodNullable<import("zod").ZodNumber>;
|
|
355
|
+
builtBehind: import("zod").ZodNumber;
|
|
405
356
|
uploadBytes: import("zod").ZodNumber;
|
|
406
357
|
built: import("zod").ZodBoolean;
|
|
407
358
|
vcpus: import("zod").ZodNumber;
|
|
408
359
|
region: import("zod").ZodString;
|
|
409
360
|
runtime: import("zod").ZodString;
|
|
410
361
|
buildMs: import("zod").ZodNumber;
|
|
411
|
-
save: import("zod").ZodNullable<import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
412
|
-
kind: import("zod").ZodLiteral<"saved">;
|
|
413
|
-
snapshotId: import("zod").ZodString;
|
|
414
|
-
base: import("zod").ZodString;
|
|
415
|
-
branch: import("zod").ZodNullable<import("zod").ZodString>;
|
|
416
|
-
head: import("zod").ZodString;
|
|
417
|
-
ms: import("zod").ZodNumber;
|
|
418
|
-
sizeBytes: import("zod").ZodNumber;
|
|
419
|
-
entryWritten: import("zod").ZodBoolean;
|
|
420
|
-
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
421
|
-
kind: import("zod").ZodLiteral<"failed">;
|
|
422
|
-
step: import("zod").ZodEnum<{
|
|
423
|
-
"save-snapshot": "save-snapshot";
|
|
424
|
-
scrub: "scrub";
|
|
425
|
-
}>;
|
|
426
|
-
message: import("zod").ZodString;
|
|
427
|
-
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
428
|
-
kind: import("zod").ZodLiteral<"stopped">;
|
|
429
|
-
}, import("zod/v4/core").$strip>], "kind">>;
|
|
430
|
-
noSaveReason: import("zod").ZodNullable<import("zod").ZodEnum<{
|
|
431
|
-
"already-saved": "already-saved";
|
|
432
|
-
ci: "ci";
|
|
433
|
-
"command-failed": "command-failed";
|
|
434
|
-
"keep-sandbox": "keep-sandbox";
|
|
435
|
-
"no-save-flag": "no-save-flag";
|
|
436
|
-
"not-trusted": "not-trusted";
|
|
437
|
-
recipe: "recipe";
|
|
438
|
-
}>>;
|
|
439
362
|
}, import("zod/v4/core").$strip>>;
|
|
440
363
|
timeline: import("zod").ZodObject<{
|
|
441
364
|
startedAt: import("zod").ZodString;
|
|
@@ -480,8 +403,9 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
480
403
|
}, import("zod/v4/core").$strip>>;
|
|
481
404
|
}, import("zod/v4/core").$strip>;
|
|
482
405
|
runId: import("zod").ZodNullable<import("zod").ZodString>;
|
|
483
|
-
|
|
484
|
-
|
|
406
|
+
noFinalTestResults: import("zod").ZodBoolean;
|
|
407
|
+
plan: import("zod").ZodExactOptional<import("zod").ZodObject<{
|
|
408
|
+
tests: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
485
409
|
files: import("zod").ZodNumber;
|
|
486
410
|
options: import("zod").ZodArray<import("zod").ZodObject<{
|
|
487
411
|
path: import("zod").ZodString;
|
|
@@ -492,7 +416,7 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
492
416
|
flag: "flag";
|
|
493
417
|
}>;
|
|
494
418
|
}, import("zod/v4/core").$strip>>;
|
|
495
|
-
}, import("zod/v4/core").$strip
|
|
419
|
+
}, import("zod/v4/core").$strip>>;
|
|
496
420
|
}, import("zod/v4/core").$strip>;
|
|
497
421
|
}, {
|
|
498
422
|
ran: unknown;
|
|
@@ -501,10 +425,6 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
501
425
|
flags: string[];
|
|
502
426
|
configFile: string | null;
|
|
503
427
|
}]>;
|
|
504
|
-
devSnapshotsNotTrusted: import("@vercel/clinkr").SharedError<"dev_snapshots_not_trusted", [data: {
|
|
505
|
-
flag: string;
|
|
506
|
-
configFile: string | null;
|
|
507
|
-
}]>;
|
|
508
428
|
driverPlanFailed: import("@vercel/clinkr").SharedError<"driver_plan_failed", [data: {
|
|
509
429
|
driver: string;
|
|
510
430
|
kind: "exited" | "start-failed" | "timed-out" | "unreadable-output";
|
|
@@ -624,10 +544,6 @@ declare const _default: import("@vercel/clinkr").CommandDefinition<import("zod")
|
|
|
624
544
|
flags: string[];
|
|
625
545
|
configFile: string | null;
|
|
626
546
|
}]>;
|
|
627
|
-
readonly devSnapshotsNotTrusted: import("@vercel/clinkr").SharedError<"dev_snapshots_not_trusted", [data: {
|
|
628
|
-
flag: string;
|
|
629
|
-
configFile: string | null;
|
|
630
|
-
}]>;
|
|
631
547
|
readonly driverPlanFailed: import("@vercel/clinkr").SharedError<"driver_plan_failed", [data: {
|
|
632
548
|
driver: string;
|
|
633
549
|
kind: "exited" | "start-failed" | "timed-out" | "unreadable-output";
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import {
|
|
2
2
|
defineRunCommand
|
|
3
|
-
} from "../../chunks/chunk-
|
|
4
|
-
import "../../chunks/chunk-
|
|
5
|
-
import "../../chunks/chunk-
|
|
3
|
+
} from "../../chunks/chunk-IVRRGGCD.js";
|
|
4
|
+
import "../../chunks/chunk-HOKDKP5A.js";
|
|
5
|
+
import "../../chunks/chunk-YBPTMJUM.js";
|
|
6
6
|
import "../../chunks/chunk-I5GZLOLQ.js";
|
|
7
|
-
import "../../chunks/chunk-
|
|
8
|
-
import "../../chunks/chunk-
|
|
9
|
-
import "../../chunks/chunk-
|
|
7
|
+
import "../../chunks/chunk-27P2QSIM.js";
|
|
8
|
+
import "../../chunks/chunk-BFLYGMG3.js";
|
|
9
|
+
import "../../chunks/chunk-XPCUINWS.js";
|
|
10
10
|
import {
|
|
11
11
|
driverNamed
|
|
12
|
-
} from "../../chunks/chunk-
|
|
13
|
-
import "../../chunks/chunk-
|
|
14
|
-
import "../../chunks/chunk-
|
|
12
|
+
} from "../../chunks/chunk-Z5OXOZD3.js";
|
|
13
|
+
import "../../chunks/chunk-UC6DULWY.js";
|
|
14
|
+
import "../../chunks/chunk-BRUIATTR.js";
|
|
15
15
|
import "../../chunks/chunk-NMVODY3P.js";
|
|
16
|
-
import "../../chunks/chunk-
|
|
17
|
-
import "../../chunks/chunk-
|
|
18
|
-
import "../../chunks/chunk-
|
|
19
|
-
import "../../chunks/chunk-
|
|
20
|
-
import "../../chunks/chunk-
|
|
16
|
+
import "../../chunks/chunk-RKONDLPS.js";
|
|
17
|
+
import "../../chunks/chunk-QBR5VHJ7.js";
|
|
18
|
+
import "../../chunks/chunk-5TMHYH7G.js";
|
|
19
|
+
import "../../chunks/chunk-5ED3IDUJ.js";
|
|
20
|
+
import "../../chunks/chunk-RA4L2ACU.js";
|
|
21
21
|
import "../../chunks/chunk-BW2ADH7U.js";
|
|
22
22
|
import "../../chunks/chunk-GQIL3AHY.js";
|
|
23
23
|
import "../../chunks/chunk-GSC6SRTW.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// src/commands/vitest/metadata.ts
|
|
2
2
|
var metadata = {
|
|
3
|
-
description: "Run vitest run with the run payload in STORM_RUN, after counting its
|
|
4
|
-
summary: "
|
|
3
|
+
description: "Run vitest run with the run payload in STORM_RUN, after counting its test files and sizing the run when storm.config.ts sets testPlan. storm's flags come first; every other argument goes to vitest run unchanged, in order. Put vitest's own dash options, such as -t or --project, after --. Without testPlan: true in storm.config.ts, or --count-tests, it counts nothing, as storm exec counts nothing, so no program of the project runs on this machine before a sandboxed run. With it, before anything is minted, acquired or started, it counts the test files with vitest list --filesOnly --json and the same arguments, on this machine, with this machine's environment: in the working directory for an unsandboxed run (--unsandboxed), and in <repository root>/<runner cwd> for a sandboxed run, the directory where vitest runs in the runner sandbox. That count imports no test file and applies the file filters and --project, but not -t: a -t that matches no test starts the run, and vitest run skips every test and exits 0. With --count-tests it counts each test with vitest list --json instead, whether or not storm.config.ts sets testPlan, which imports every test file to collect its tests, so it is slow for a large suite and needs what the test files import to resolve on this machine. A run that counts refuses with no_matching_tests when vitest lists no file, or no test with --count-tests, and with driver_plan_failed when listing fails; vitest list refuses some options only vitest run takes. A signal while it counts stops vitest list and cancels the run. A vitest config that resolves only inside the runner sandbox can't be counted here: leave testPlan out of storm.config.ts. A resource of the run may size itself from the count: an option whose default is a function of the test plan takes its own flag if given, else its key in storm.config.ts, else the default for the count; the run says each such option's value and where it came from on stderr before it acquires anything. In an unsandboxed run, vitest is the nearest node_modules/.bin/vitest from the working directory up to the repository's root, or the filesystem's root outside a repository; in a sandboxed run, vitest from the runner's PATH, which starts with node_modules/.bin of the runner cwd and of the repository's root. Otherwise it runs as storm exec does: in a runner sandbox by default or on this machine with --unsandboxed, with a live view or plain lines on stderr, a waterfall, a run directory that storm runs show reads back, and the exit code of vitest. A run whose vitest exits 0 but reports no final test result to storm, since the Vitest config lists no storm reporter or a --reporter replaced it, warns no_final_test_results, whose next steps say what to add to the config. The result of a run that counted, and its run directory's run.json, carry the test plan: the files counted, the tests with --count-tests, and each option sized from them, with its value and where it came from.",
|
|
4
|
+
summary: "Run vitest, after counting the test files if storm.config.ts asks."
|
|
5
5
|
};
|
|
6
6
|
export {
|
|
7
7
|
metadata
|
package/dist/config/resolve.d.ts
CHANGED
|
@@ -10,7 +10,7 @@ export interface SettingFlags {
|
|
|
10
10
|
readonly project?: string | undefined;
|
|
11
11
|
}
|
|
12
12
|
/**
|
|
13
|
-
* Resolves each top-level setting: the flag's value, else the config file's. `runner`
|
|
13
|
+
* Resolves each top-level setting: the flag's value, else the config file's. `runner` and `testPlan` have no flag. `file` is the
|
|
14
14
|
* loaded config file's settings, already checked, or `undefined` when no file applies.
|
|
15
15
|
*/
|
|
16
16
|
export declare function resolveSettings(flags: SettingFlags, file: CheckedSettings | undefined): ResolvedSettings;
|
package/dist/config/resolve.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import { defaultResourceKey, resourceCall, NOT_COUNTED, optionKeyPath, } from "../sdk/extension/index.js";
|
|
4
4
|
import { settingsOf } from "./typed-options.js";
|
|
5
5
|
/**
|
|
6
|
-
* Resolves each top-level setting: the flag's value, else the config file's. `runner`
|
|
6
|
+
* Resolves each top-level setting: the flag's value, else the config file's. `runner` and `testPlan` have no flag. `file` is the
|
|
7
7
|
* loaded config file's settings, already checked, or `undefined` when no file applies.
|
|
8
8
|
*/
|
|
9
9
|
export function resolveSettings(flags, file) {
|
|
@@ -16,6 +16,7 @@ export function resolveSettings(flags, file) {
|
|
|
16
16
|
scope: pick(flags.scope, file?.scope),
|
|
17
17
|
project: pick(flags.project, file?.project),
|
|
18
18
|
runner: pick(undefined, file?.runner),
|
|
19
|
+
testPlan: pick(undefined, file?.testPlan),
|
|
19
20
|
};
|
|
20
21
|
}
|
|
21
22
|
/**
|
package/dist/config/schema.d.ts
CHANGED
|
@@ -18,6 +18,14 @@ export interface ConfigSettings {
|
|
|
18
18
|
* `vcpus` may be a function of the run, which reads a resource by its resource factory: `run.get(<name>)`.
|
|
19
19
|
*/
|
|
20
20
|
readonly runner?: RunnerRecipe<RecipeRun>;
|
|
21
|
+
/**
|
|
22
|
+
* Whether `storm vitest` and `storm playwright` plan the tests before a run: `true` counts them on this machine
|
|
23
|
+
* before anything is minted, acquired or started (`storm vitest` the test files, `storm playwright` each test), and
|
|
24
|
+
* the count is the run's test plan, which a resource option's default may size the run from. Without it a run
|
|
25
|
+
* counts nothing, and no program of the project runs on this machine before a run in a runner sandbox. `storm exec`
|
|
26
|
+
* never counts.
|
|
27
|
+
*/
|
|
28
|
+
readonly testPlan?: boolean;
|
|
21
29
|
}
|
|
22
30
|
/** A top-level setting's name. */
|
|
23
31
|
export type ConfigSettingKey = keyof ConfigSettings;
|
package/dist/config/schema.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
// What a `storm.config.ts` holds at its top level: the settings `scope`, `project` and `
|
|
2
|
-
// rule, and `resources`, whose sections the resource definitions a caller passes in define (`src/sdk/extension/`). Also
|
|
1
|
+
// What a `storm.config.ts` holds at its top level: the settings `scope`, `project`, `runner` and `testPlan`, each
|
|
2
|
+
// with its rule, and `resources`, whose sections the resource definitions a caller passes in define (`src/sdk/extension/`). Also
|
|
3
3
|
// the check vocabulary every rule shares: `Checked`, `ValueProblem`, `checkWith` and how a problem names a value.
|
|
4
4
|
import { checkRecipe } from "../runner/index.js";
|
|
5
|
-
import { nonEmptyString } from "../sdk/extension/index.js";
|
|
5
|
+
import { booleanOption, nonEmptyString } from "../sdk/extension/index.js";
|
|
6
6
|
/** The config file's name. storm looks for it in the working directory and its parents. */
|
|
7
7
|
export const CONFIG_FILE_NAME = "storm.config.ts";
|
|
8
8
|
/** `value` checked by `schema`: its output, or each issue as a problem at the issue's path inside the value. */
|
|
@@ -23,9 +23,10 @@ const SETTING_CHECKS = {
|
|
|
23
23
|
scope: (value) => checkWith(nonEmptyString, value),
|
|
24
24
|
project: (value) => checkWith(nonEmptyString, value),
|
|
25
25
|
runner: checkRecipe,
|
|
26
|
+
testPlan: (value) => checkWith(booleanOption, value),
|
|
26
27
|
};
|
|
27
28
|
/** Every top-level setting, in the order a config file's problems list them. */
|
|
28
|
-
export const CONFIG_SETTING_KEYS = ["scope", "project", "runner"];
|
|
29
|
+
export const CONFIG_SETTING_KEYS = ["scope", "project", "runner", "testPlan"];
|
|
29
30
|
/** Whether `key` is a top-level setting. */
|
|
30
31
|
export function isConfigSettingKey(key) {
|
|
31
32
|
return Object.hasOwn(SETTING_CHECKS, key);
|
package/dist/core/events.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { CredentialEvent } from "../credential/index.ts";
|
|
2
2
|
import type { LaneOutcome } from "../sdk/extension/index.ts";
|
|
3
|
-
import type { RunnerEvent,
|
|
3
|
+
import type { RunnerEvent, SnapshotCacheNote } from "../runner/index.ts";
|
|
4
4
|
import type { Clock } from "../time/index.ts";
|
|
5
5
|
import type { TestEvent } from "../sdk/run/launcher.ts";
|
|
6
6
|
import type { RunInstance, ResourceAcquired, ResourceEvent, ResourceNoticeEvent, ResourceSkip, ResourceWarningEvent, RunLane } from "./resource.ts";
|
|
@@ -34,10 +34,9 @@ import type { RanCommand } from "./timing.ts";
|
|
|
34
34
|
* - `command-started`: the command started, or is about to start in the runner sandbox.
|
|
35
35
|
* - `command-ended`: the command ended as `outcome` after `ms`; `command` is its executable's name. A command the
|
|
36
36
|
* run killed reports the runner's `command-stopped` instead.
|
|
37
|
-
* - `cleanup-started`: the run is cleaning up: with a runner sandbox
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
* runs); and releasing its resource instances whose acquires took anything (`resources`, their resource keys, in
|
|
37
|
+
* - `cleanup-started`: the run is cleaning up: with a runner sandbox stopping and deleting the runner's sandboxes, but
|
|
38
|
+
* for the runner sandbox, which it keeps running `keepMs` when that is above 0 (`keepMs` is null without a runner
|
|
39
|
+
* sandbox); and releasing its resource instances whose acquires took anything (`resources`, their resource keys, in
|
|
41
40
|
* order).
|
|
42
41
|
* - `cleanup-finished`: it is done; `resourceWarnings` counts the warnings releasing the run's resource instances
|
|
43
42
|
* reported, summed over them, and it counts how many of the runner's sandboxes couldn't be stopped (`notStopped`) or
|
|
@@ -83,7 +82,7 @@ export type RunEvent = {
|
|
|
83
82
|
readonly ms: number;
|
|
84
83
|
} | {
|
|
85
84
|
readonly kind: "cleanup-started";
|
|
86
|
-
readonly
|
|
85
|
+
readonly keepMs: number | null;
|
|
87
86
|
readonly resources: readonly string[];
|
|
88
87
|
} | {
|
|
89
88
|
readonly kind: "cleanup-finished";
|
package/dist/core/run-state.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { MintTarget } from "../credential/index.ts";
|
|
2
2
|
import type { LaneStates, ResourceDefinition, Span, SpanStatus } from "../sdk/extension/index.ts";
|
|
3
|
-
import type { KeptSandbox
|
|
3
|
+
import type { KeptSandbox } from "../runner/index.ts";
|
|
4
4
|
import type { TimedRunEvent } from "./events.ts";
|
|
5
5
|
import type { RunInstance } from "./resource.ts";
|
|
6
6
|
import { type SetupPhaseName } from "./setup-phases.ts";
|
|
@@ -24,36 +24,18 @@ export interface RunnerStepState {
|
|
|
24
24
|
readonly latest: string | undefined;
|
|
25
25
|
}
|
|
26
26
|
/**
|
|
27
|
-
* What the runner did with its runner snapshot: reused or built one, of the base it holds, or is building one.
|
|
28
|
-
*
|
|
29
|
-
* says its kind, its built-at commit and how far it is behind the run.
|
|
27
|
+
* What the runner did with its runner snapshot: reused or built one, of the base it holds, or is building one.
|
|
28
|
+
* `builtBehind` is how many commits HEAD has that the base lacks, null when the base isn't in HEAD's history.
|
|
30
29
|
*/
|
|
31
30
|
export type RunnerSnapshotState = {
|
|
32
31
|
readonly kind: "reused" | "built";
|
|
33
32
|
readonly id: string;
|
|
34
33
|
readonly base: string;
|
|
35
|
-
readonly
|
|
36
|
-
readonly head: string | null;
|
|
37
|
-
readonly snapshot: StartedFromSnapshot;
|
|
34
|
+
readonly builtBehind: number | null;
|
|
38
35
|
} | {
|
|
39
36
|
readonly kind: "building";
|
|
40
37
|
readonly summary: string;
|
|
41
38
|
};
|
|
42
|
-
/**
|
|
43
|
-
* Saving the runner sandbox as a dev snapshot: under way, saved as runner snapshot `id` at HEAD commit `head`, or
|
|
44
|
-
* not saved. `branch` is HEAD's branch, null when detached.
|
|
45
|
-
*/
|
|
46
|
-
export type DevSnapshotSaveState = {
|
|
47
|
-
readonly kind: "saving";
|
|
48
|
-
readonly branch: string | null;
|
|
49
|
-
} | {
|
|
50
|
-
readonly kind: "saved";
|
|
51
|
-
readonly id: string;
|
|
52
|
-
readonly branch: string | null;
|
|
53
|
-
readonly head: string;
|
|
54
|
-
} | {
|
|
55
|
-
readonly kind: "not-saved";
|
|
56
|
-
};
|
|
57
39
|
/** One test worker, as its test events show it. */
|
|
58
40
|
export interface TestWorkerState {
|
|
59
41
|
/** Its worker index, from 0. */
|
|
@@ -93,10 +75,6 @@ export interface RunnerState extends Span {
|
|
|
93
75
|
readonly activity: "saving-snapshot" | "waiting-for-snapshot" | undefined;
|
|
94
76
|
/** The runner sandbox the run kept running once it ended, once closing kept it. */
|
|
95
77
|
readonly kept: KeptSandbox | undefined;
|
|
96
|
-
/** Saving the runner sandbox as a dev snapshot, once it began. */
|
|
97
|
-
readonly save: DevSnapshotSaveState | undefined;
|
|
98
|
-
/** Why the run, whose command ended on its own, started no save, once it said so. */
|
|
99
|
-
readonly noSave: RunnerNoSaveReason | undefined;
|
|
100
78
|
}
|
|
101
79
|
/** The command: its argument list and how it ended; `stopped` when the run killed it. */
|
|
102
80
|
export interface CommandState extends Span {
|
|
@@ -106,10 +84,10 @@ export interface CommandState extends Span {
|
|
|
106
84
|
/** The cleanup: what it stops and releases, and what it couldn't. */
|
|
107
85
|
export interface CleanupState extends Span {
|
|
108
86
|
/**
|
|
109
|
-
*
|
|
110
|
-
*
|
|
87
|
+
* How long it keeps the runner sandbox running while it stops and deletes the runner's other sandboxes, stopping and
|
|
88
|
+
* deleting it at 0; null without a runner sandbox.
|
|
111
89
|
*/
|
|
112
|
-
readonly
|
|
90
|
+
readonly keepMs: number | null;
|
|
113
91
|
/** The resource keys of the resource instances it releases: each whose acquire took anything, in order. */
|
|
114
92
|
readonly resources: readonly string[];
|
|
115
93
|
/** How many warnings releasing the run's resource instances reported, summed over them. */
|
package/dist/core/run-state.js
CHANGED
|
@@ -74,8 +74,6 @@ function applyEvent(resources, state, event, at) {
|
|
|
74
74
|
uploadBytes: undefined,
|
|
75
75
|
activity: undefined,
|
|
76
76
|
kept: undefined,
|
|
77
|
-
save: undefined,
|
|
78
|
-
noSave: undefined,
|
|
79
77
|
},
|
|
80
78
|
};
|
|
81
79
|
case "minting":
|
|
@@ -137,7 +135,7 @@ function applyEvent(resources, state, event, at) {
|
|
|
137
135
|
status: "running",
|
|
138
136
|
startedAt: at,
|
|
139
137
|
endedAt: undefined,
|
|
140
|
-
|
|
138
|
+
keepMs: event.keepMs,
|
|
141
139
|
resources: event.resources,
|
|
142
140
|
resourceWarnings: 0,
|
|
143
141
|
notStopped: 0,
|
|
@@ -215,9 +213,7 @@ function applyRunnerEvent(state, event, at) {
|
|
|
215
213
|
kind: "reused",
|
|
216
214
|
id: event.snapshotId,
|
|
217
215
|
base: event.base,
|
|
218
|
-
|
|
219
|
-
head: event.head,
|
|
220
|
-
snapshot: event.snapshot,
|
|
216
|
+
builtBehind: event.builtBehind,
|
|
221
217
|
},
|
|
222
218
|
}));
|
|
223
219
|
case "snapshot-build-started":
|
|
@@ -228,14 +224,7 @@ function applyRunnerEvent(state, event, at) {
|
|
|
228
224
|
kind: "built",
|
|
229
225
|
id: event.snapshotId,
|
|
230
226
|
base: event.base,
|
|
231
|
-
|
|
232
|
-
head: null,
|
|
233
|
-
// A run builds its base snapshot at its own base.
|
|
234
|
-
snapshot: {
|
|
235
|
-
kind: "base",
|
|
236
|
-
builtAt: event.base,
|
|
237
|
-
builtBehind: event.builtBehind,
|
|
238
|
-
},
|
|
227
|
+
builtBehind: event.builtBehind,
|
|
239
228
|
},
|
|
240
229
|
activity: undefined,
|
|
241
230
|
}));
|
|
@@ -272,23 +261,11 @@ function applyRunnerEvent(state, event, at) {
|
|
|
272
261
|
return withRunner(state.cleanup === undefined ? state : { ...state, cleanup: { ...state.cleanup, waiting: true } }, () => ({ activity: "waiting-for-snapshot" }));
|
|
273
262
|
case "sandbox-kept":
|
|
274
263
|
return withRunner(state, () => ({ kept: { name: event.name, stopsAt: event.stopsAt } }));
|
|
275
|
-
case "dev-snapshot-saving":
|
|
276
|
-
return withRunner(state, () => ({ save: { kind: "saving", branch: event.branch } }));
|
|
277
|
-
case "dev-snapshot-saved":
|
|
278
|
-
return withRunner(state, () => ({
|
|
279
|
-
save: { kind: "saved", id: event.snapshotId, branch: event.branch, head: event.head },
|
|
280
|
-
}));
|
|
281
|
-
case "dev-snapshot-not-saved":
|
|
282
|
-
return withRunner(state, () => ({ save: { kind: "not-saved" } }));
|
|
283
|
-
case "dev-snapshot-skipped":
|
|
284
|
-
return withRunner(state, () => ({ noSave: event.reason }));
|
|
285
264
|
// A step's outcome comes from its lane's end, not from the end of its output.
|
|
286
265
|
case "output-started":
|
|
287
266
|
case "output-ended":
|
|
288
267
|
case "snapshot-entry-not-written":
|
|
289
268
|
case "command-output-started":
|
|
290
|
-
case "dev-snapshots-dropped":
|
|
291
|
-
case "dev-snapshots-not-dropped":
|
|
292
269
|
return state;
|
|
293
270
|
}
|
|
294
271
|
}
|
package/dist/core/run.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type CredentialGateway, type CredentialSourceChoice, type GitHubActionsTokenGateway, type MintFailure, type MintTarget } from "../credential/index.ts";
|
|
2
|
-
import { type RunnerCleanupFacts, type RunnerContext, type RunnerFailure, type
|
|
2
|
+
import { type RunnerCleanupFacts, type RunnerContext, type RunnerFailure, type RunnerSessionRequest, type RunnerSnapshotCacheFailure, type RunnerSnapshotEntry } from "../runner/index.ts";
|
|
3
3
|
import type { Clock } from "../time/index.ts";
|
|
4
4
|
import type { RunProgress } from "./events.ts";
|
|
5
5
|
import type { CommandGateway } from "./gateways.ts";
|
|
@@ -22,7 +22,7 @@ export interface RunContext extends RunnerContext {
|
|
|
22
22
|
/**
|
|
23
23
|
* What a sandboxed run needs beyond an unsandboxed run: what its runner session runs (`RunnerSessionRequest`), the
|
|
24
24
|
* runner checked on this machine, the team and project the run's credential is minted for, the local user, the runner
|
|
25
|
-
* secrets,
|
|
25
|
+
* secrets, and how long it keeps the runner sandbox.
|
|
26
26
|
*/
|
|
27
27
|
export type RunRunnerRequest = RunnerSessionRequest;
|
|
28
28
|
/** What every run was asked to do, unsandboxed or sandboxed. */
|
|
@@ -96,13 +96,10 @@ export interface RanRunner {
|
|
|
96
96
|
/** The runner snapshot it started from, and its base. */
|
|
97
97
|
readonly snapshotId: string;
|
|
98
98
|
readonly base: string;
|
|
99
|
-
/** For a dev snapshot it started from, the branch and HEAD commit of the run that saved it; null otherwise. */
|
|
100
|
-
readonly snapshotBranch: string | null;
|
|
101
|
-
readonly snapshotHead: string | null;
|
|
102
99
|
/** Whether this run built the runner snapshot. */
|
|
103
100
|
readonly built: boolean;
|
|
104
|
-
/**
|
|
105
|
-
readonly
|
|
101
|
+
/** How many commits HEAD has that the snapshot's base lacks. */
|
|
102
|
+
readonly builtBehind: number;
|
|
106
103
|
/** How many bytes of changes the run uploaded on top of the snapshot's base. */
|
|
107
104
|
readonly uploadBytes: number;
|
|
108
105
|
readonly vcpus: number;
|
|
@@ -110,10 +107,6 @@ export interface RanRunner {
|
|
|
110
107
|
readonly runtime: string;
|
|
111
108
|
/** How long the build step took, in milliseconds. */
|
|
112
109
|
readonly buildMs: number;
|
|
113
|
-
/** How saving the runner sandbox as a dev snapshot ended; null when the run started no save. */
|
|
114
|
-
readonly save: RunnerSave | null;
|
|
115
|
-
/** Why the run, whose command ended on its own, started no save; null when it started one. */
|
|
116
|
-
readonly noSave: RunnerNoSaveReason | null;
|
|
117
110
|
}
|
|
118
111
|
/**
|
|
119
112
|
* How a run ended.
|
|
@@ -197,8 +190,7 @@ export type RunStopped = ResourceRefusal | {
|
|
|
197
190
|
*
|
|
198
191
|
* Release happens however the run ended, a throw included: once the command has stopped and, in a sandboxed run, the
|
|
199
192
|
* runner session has closed its sandbox scope, each resource instance is released in reverse order, even when the
|
|
200
|
-
* `cleanup-started` event can't be reported.
|
|
201
|
-
*
|
|
202
|
-
* `finally`; a sandboxed run's runner session does, as it finishes or closes.
|
|
193
|
+
* `cleanup-started` event can't be reported. An unsandboxed run releases them in `finally`; a sandboxed run's runner
|
|
194
|
+
* session does, as it finishes or closes.
|
|
203
195
|
*/
|
|
204
196
|
export declare function executeRun(definitionSet: ResourceDefinitionSet, context: RunContext, resourceContexts: ResourceContextMap, request: RunRequest, control: RunControl, progress: RunProgress): Promise<RunOutcome>;
|