@cnc-tools/storm 0.6.0 → 0.8.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/build-info.js +1 -1
- package/dist/commands/exec/cleanup.d.ts +3 -3
- package/dist/commands/exec/cleanup.js +1 -1
- package/dist/commands/exec/command.d.ts +797 -1
- package/dist/commands/exec/command.js +1 -1
- package/dist/commands/exec/live-view.js +32 -15
- package/dist/commands/exec/metadata.d.ts +5 -2
- package/dist/commands/exec/metadata.js +4 -0
- package/dist/commands/exec/mint-failed.d.ts +28 -0
- package/dist/commands/exec/outcomes.d.ts +526 -0
- package/dist/commands/exec/outcomes.js +9 -0
- package/dist/commands/exec/progress.d.ts +14 -2
- package/dist/commands/exec/progress.js +57 -14
- package/dist/commands/exec/run-command.d.ts +10 -4
- package/dist/commands/exec/run-command.js +41 -8
- package/dist/commands/exec/run-metadata.d.ts +6 -3
- package/dist/commands/exec/run-metadata.js +6 -3
- package/dist/commands/exec/run-record.d.ts +83 -4
- package/dist/commands/exec/run-record.js +49 -1
- package/dist/commands/exec/tests-summary.d.ts +1 -1
- package/dist/commands/exec/tests-summary.js +1 -1
- package/dist/commands/exec/view.js +36 -4
- package/dist/commands/runs/facts.d.ts +25 -0
- package/dist/commands/runs/facts.js +36 -3
- package/dist/commands/runs/list/command.d.ts +154 -1
- package/dist/commands/runs/list/command.js +1 -1
- package/dist/commands/runs/list/outcomes.d.ts +41 -0
- package/dist/commands/runs/logs/command.d.ts +263 -1
- package/dist/commands/runs/logs/command.js +1 -1
- package/dist/commands/runs/logs/outcomes.d.ts +105 -0
- package/dist/commands/runs/show/command.d.ts +354 -1
- package/dist/commands/runs/show/command.js +1 -1
- package/dist/commands/runs/show/metadata.js +1 -1
- package/dist/commands/runs/show/outcomes.d.ts +96 -0
- package/dist/commands/runs/show/outcomes.js +30 -1
- package/dist/commands/vitest/command.d.ts +912 -1
- package/dist/commands/vitest/command.js +1 -1
- package/dist/commands/vitest/metadata.d.ts +5 -2
- package/dist/commands/vitest/metadata.js +4 -0
- package/dist/commands/vitest/outcomes.d.ts +320 -0
- package/dist/config/errors.d.ts +73 -0
- package/dist/config/schema.d.ts +1 -1
- package/dist/config-file/define.d.ts +4 -3
- package/dist/config-file/define.js +1 -1
- package/dist/config-file/toolchain.js +1 -1
- package/dist/core/command-slots.d.ts +8 -2
- package/dist/core/command-slots.js +6 -2
- package/dist/core/events.d.ts +9 -7
- package/dist/core/index.d.ts +1 -1
- package/dist/core/run-state.d.ts +30 -6
- package/dist/core/run-state.js +19 -4
- package/dist/core/run.d.ts +17 -4
- package/dist/core/run.js +61 -25
- package/dist/credential/index.d.ts +1 -0
- package/dist/credential/index.js +1 -0
- package/dist/credential/settle.d.ts +20 -0
- package/dist/credential/target.d.ts +6 -0
- package/dist/credential/target.js +7 -0
- package/dist/resources/github/command.d.ts +54 -2
- package/dist/resources/github/config.js +1 -1
- package/dist/resources/github/index.js +1 -1
- package/dist/resources/github/resource.js +2 -2
- package/dist/resources/testserver/command.d.ts +208 -10
- package/dist/resources/testserver/command.js +7 -0
- package/dist/resources/testserver/commands/create/command.d.ts +808 -1
- package/dist/resources/testserver/commands/create/command.js +64 -23
- package/dist/resources/testserver/commands/create/metadata.js +6 -2
- package/dist/resources/testserver/commands/create/outcomes.d.ts +347 -0
- package/dist/resources/testserver/commands/create/outcomes.js +14 -1
- package/dist/resources/testserver/commands/list/command.d.ts +84 -1
- package/dist/resources/testserver/commands/list/command.js +1 -1
- package/dist/resources/testserver/commands/list/outcomes.d.ts +16 -0
- package/dist/resources/testserver/config.js +14 -4
- package/dist/resources/testserver/events.d.ts +9 -0
- package/dist/resources/testserver/index.js +8 -7
- package/dist/resources/testserver/lane.js +1 -0
- package/dist/resources/testserver/live/gateways.d.ts +2 -0
- package/dist/resources/testserver/live/gateways.js +16 -3
- package/dist/resources/testserver/pool/channels.d.ts +5 -2
- package/dist/resources/testserver/pool/channels.js +1 -1
- package/dist/resources/testserver/pool/create.d.ts +6 -2
- package/dist/resources/testserver/pool/create.js +6 -5
- package/dist/resources/testserver/pool/index.d.ts +1 -0
- package/dist/resources/testserver/pool/index.js +1 -0
- package/dist/resources/testserver/pool/pull-request.d.ts +89 -0
- package/dist/resources/testserver/pool/pull-request.js +85 -0
- package/dist/resources/testserver/pr-build-facts.d.ts +130 -0
- package/dist/resources/testserver/pr-build-facts.js +261 -0
- package/dist/resources/testserver/presentation.d.ts +2 -2
- package/dist/resources/testserver/presentation.js +12 -3
- package/dist/resources/testserver/provider.d.ts +16 -6
- package/dist/resources/testserver/provider.js +46 -15
- package/dist/resources/testserver/pull-request/gateways.d.ts +117 -0
- package/dist/resources/testserver/pull-request/gateways.js +5 -0
- package/dist/resources/testserver/pull-request/index.d.ts +5 -0
- package/dist/resources/testserver/pull-request/index.js +6 -0
- package/dist/resources/testserver/pull-request/live/github-rest.d.ts +28 -0
- package/dist/resources/testserver/pull-request/live/github-rest.js +114 -0
- package/dist/resources/testserver/pull-request/live/github-token-gateway.d.ts +12 -0
- package/dist/resources/testserver/pull-request/live/github-token-gateway.js +39 -0
- package/dist/resources/testserver/pull-request/live/pull-request-gateway.d.ts +10 -0
- package/dist/resources/testserver/pull-request/live/pull-request-gateway.js +27 -0
- package/dist/resources/testserver/pull-request/live/testserver-workflow-gateway.d.ts +21 -0
- package/dist/resources/testserver/pull-request/live/testserver-workflow-gateway.js +64 -0
- package/dist/resources/testserver/ran.d.ts +5 -0
- package/dist/resources/testserver/ran.js +19 -3
- package/dist/resources/testserver/resource.d.ts +5 -1
- package/dist/resources/testserver/resource.js +2 -2
- package/dist/resources/testserver/sandbox/build-reference.d.ts +38 -0
- package/dist/resources/testserver/sandbox/build-reference.js +79 -0
- package/dist/resources/testserver/sandbox/index.d.ts +1 -0
- package/dist/resources/testserver/sandbox/index.js +1 -0
- package/dist/resources.d.ts +265 -15
- package/dist/runner/events.d.ts +64 -1
- package/dist/runner/gateways.d.ts +17 -6
- package/dist/runner/index.d.ts +5 -4
- package/dist/runner/index.js +4 -3
- package/dist/runner/live/snapshot-records.js +18 -4
- package/dist/runner/prepare.d.ts +23 -4
- package/dist/runner/prepare.js +13 -3
- package/dist/runner/ready.d.ts +7 -3
- package/dist/runner/ready.js +11 -5
- package/dist/runner/scope.d.ts +17 -1
- package/dist/runner/scope.js +4 -0
- package/dist/runner/snapshot-build.d.ts +3 -1
- package/dist/runner/snapshot-build.js +12 -2
- package/dist/runner/snapshot-cache.d.ts +46 -8
- package/dist/runner/snapshot-cache.js +60 -11
- package/dist/runner/snapshot-key.d.ts +12 -1
- package/dist/runner/snapshot-key.js +17 -1
- package/dist/runner/snapshot-save.d.ts +53 -0
- package/dist/runner/snapshot-save.js +148 -0
- package/dist/sdk/index.js +2 -2
- package/dist/story/align.d.ts +1 -1
- package/dist/story/align.js +1 -1
- package/dist/story/command-line.d.ts +34 -0
- package/dist/story/command-line.js +100 -0
- package/dist/story/definition.d.ts +22 -15
- package/dist/story/definition.js +2 -2
- package/dist/story/errors.js +1 -1
- package/dist/story/gateways.d.ts +45 -25
- package/dist/story/gateways.js +2 -2
- package/dist/story/host.d.ts +11 -8
- package/dist/story/host.js +37 -37
- package/dist/story/index.d.ts +2 -1
- package/dist/story/index.js +6 -5
- package/dist/story/json.d.ts +1 -1
- package/dist/story/json.js +2 -2
- package/dist/story/live/recording-gateway.d.ts +2 -0
- package/dist/story/live/{artifact-gateway.js → recording-gateway.js} +33 -12
- package/dist/story/mode.d.ts +2 -2
- package/dist/story/mode.js +1 -1
- package/dist/story/orphans.d.ts +23 -5
- package/dist/story/orphans.js +44 -8
- package/dist/story/recording.d.ts +62 -0
- package/dist/story/{artifact.js → recording.js} +31 -27
- package/dist/story/report.d.ts +21 -9
- package/dist/story/report.js +37 -25
- package/dist/story/settle.d.ts +23 -21
- package/dist/story/settle.js +17 -16
- package/dist/story/{run.d.ts → start.d.ts} +18 -17
- package/dist/story/{run.js → start.js} +66 -43
- package/dist/vercel-cli/context.js +1 -1
- package/dist/vercel-cli/index.js +1 -1
- package/dist/vitest/config.js +2 -2
- package/dist/vitest/fixtures.d.ts +1 -1
- package/dist/vitest/fixtures.js +1 -1
- package/dist/vitest/index.js +3 -3
- package/dist/vitest/plan.js +1 -1
- package/package.json +3 -3
- package/skills/overview.md +2 -0
- package/skills/testserver-builds.md +80 -0
- package/dist/story/artifact.d.ts +0 -60
- package/dist/story/live/artifact-gateway.d.ts +0 -2
|
@@ -52,4 +52,109 @@ export declare const outcomes: import("@vercel/clinkr").Outcomes<{
|
|
|
52
52
|
snapshot: "snapshot";
|
|
53
53
|
}>>;
|
|
54
54
|
}, z.core.$strip>;
|
|
55
|
+
}, {
|
|
56
|
+
readonly runsUnreadable: {
|
|
57
|
+
readonly exitCode: 1;
|
|
58
|
+
readonly description: "storm couldn't read the run directories.";
|
|
59
|
+
readonly schema: z.ZodObject<{
|
|
60
|
+
path: z.ZodString;
|
|
61
|
+
message: z.ZodString;
|
|
62
|
+
}, z.core.$strip>;
|
|
63
|
+
readonly render: ({ path, message }: {
|
|
64
|
+
readonly path: string;
|
|
65
|
+
readonly message: string;
|
|
66
|
+
}) => {
|
|
67
|
+
message: string;
|
|
68
|
+
rows: (readonly ["Path", string])[];
|
|
69
|
+
};
|
|
70
|
+
};
|
|
71
|
+
readonly runNotFound: {
|
|
72
|
+
readonly exitCode: 1;
|
|
73
|
+
readonly description: "No run directory has the id given: it was never a run on this machine, or it was removed.";
|
|
74
|
+
readonly schema: z.ZodObject<{
|
|
75
|
+
id: z.ZodString;
|
|
76
|
+
}, z.core.$strip>;
|
|
77
|
+
readonly render: ({ id }: {
|
|
78
|
+
readonly id: string;
|
|
79
|
+
}) => {
|
|
80
|
+
message: string;
|
|
81
|
+
next: {
|
|
82
|
+
type: "command";
|
|
83
|
+
argv: string[];
|
|
84
|
+
label: string;
|
|
85
|
+
}[];
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
readonly noRuns: {
|
|
89
|
+
readonly exitCode: 1;
|
|
90
|
+
readonly description: "Without an id, the scope has no run.";
|
|
91
|
+
readonly schema: z.ZodObject<{
|
|
92
|
+
scope: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
93
|
+
kind: z.ZodLiteral<"config">;
|
|
94
|
+
configFile: z.ZodString;
|
|
95
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
96
|
+
kind: z.ZodLiteral<"all">;
|
|
97
|
+
why: z.ZodEnum<{
|
|
98
|
+
flag: "flag";
|
|
99
|
+
"no-config-file": "no-config-file";
|
|
100
|
+
}>;
|
|
101
|
+
}, z.core.$strip>], "kind">;
|
|
102
|
+
}, z.core.$strip>;
|
|
103
|
+
readonly render: ({ scope }: {
|
|
104
|
+
scope: {
|
|
105
|
+
kind: "config";
|
|
106
|
+
configFile: string;
|
|
107
|
+
} | {
|
|
108
|
+
kind: "all";
|
|
109
|
+
why: "flag" | "no-config-file";
|
|
110
|
+
};
|
|
111
|
+
}) => {
|
|
112
|
+
message: string;
|
|
113
|
+
next: {
|
|
114
|
+
type: "command";
|
|
115
|
+
argv: string[];
|
|
116
|
+
label: string;
|
|
117
|
+
}[];
|
|
118
|
+
} | {
|
|
119
|
+
message: string;
|
|
120
|
+
next: {
|
|
121
|
+
type: "text";
|
|
122
|
+
text: string;
|
|
123
|
+
}[];
|
|
124
|
+
};
|
|
125
|
+
};
|
|
126
|
+
readonly logNotFound: {
|
|
127
|
+
readonly exitCode: 1;
|
|
128
|
+
readonly description: "The run has no log for the step given: the step didn't run, or hasn't written output yet.";
|
|
129
|
+
readonly schema: z.ZodObject<{
|
|
130
|
+
id: z.ZodString;
|
|
131
|
+
step: z.ZodEnum<{
|
|
132
|
+
apply: "apply";
|
|
133
|
+
build: "build";
|
|
134
|
+
command: "command";
|
|
135
|
+
install: "install";
|
|
136
|
+
snapshot: "snapshot";
|
|
137
|
+
}>;
|
|
138
|
+
logs: z.ZodArray<z.ZodEnum<{
|
|
139
|
+
apply: "apply";
|
|
140
|
+
build: "build";
|
|
141
|
+
command: "command";
|
|
142
|
+
install: "install";
|
|
143
|
+
snapshot: "snapshot";
|
|
144
|
+
}>>;
|
|
145
|
+
}, z.core.$strip>;
|
|
146
|
+
readonly render: ({ id, step, logs }: {
|
|
147
|
+
id: string;
|
|
148
|
+
step: "apply" | "build" | "command" | "install" | "snapshot";
|
|
149
|
+
logs: ("apply" | "build" | "command" | "install" | "snapshot")[];
|
|
150
|
+
}) => {
|
|
151
|
+
message: string;
|
|
152
|
+
rows: (readonly ["Logs", string])[];
|
|
153
|
+
next: {
|
|
154
|
+
type: "command";
|
|
155
|
+
argv: string[];
|
|
156
|
+
label: string;
|
|
157
|
+
}[];
|
|
158
|
+
};
|
|
159
|
+
};
|
|
55
160
|
}>;
|
|
@@ -40,8 +40,290 @@ export declare function command(cmd: CommandBuilder<StormApp>): import("@vercel/
|
|
|
40
40
|
id: z.ZodString;
|
|
41
41
|
base: z.ZodString;
|
|
42
42
|
built: z.ZodBoolean;
|
|
43
|
+
branch: z.ZodNullable<z.ZodString>;
|
|
44
|
+
head: z.ZodNullable<z.ZodString>;
|
|
43
45
|
url: z.ZodString;
|
|
44
46
|
}, z.core.$strip>>;
|
|
47
|
+
save: z.ZodNullable<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
48
|
+
kind: z.ZodLiteral<"saved">;
|
|
49
|
+
snapshotId: z.ZodString;
|
|
50
|
+
base: z.ZodString;
|
|
51
|
+
branch: z.ZodString;
|
|
52
|
+
head: z.ZodString;
|
|
53
|
+
ms: z.ZodNumber;
|
|
54
|
+
sizeBytes: z.ZodNumber;
|
|
55
|
+
entryWritten: z.ZodBoolean;
|
|
56
|
+
url: z.ZodString;
|
|
57
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
58
|
+
kind: z.ZodLiteral<"skipped">;
|
|
59
|
+
reason: z.ZodLiteral<"detached-head">;
|
|
60
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
61
|
+
kind: z.ZodLiteral<"failed">;
|
|
62
|
+
step: z.ZodEnum<{
|
|
63
|
+
"save-snapshot": "save-snapshot";
|
|
64
|
+
scrub: "scrub";
|
|
65
|
+
}>;
|
|
66
|
+
message: z.ZodString;
|
|
67
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
68
|
+
kind: z.ZodLiteral<"stopped">;
|
|
69
|
+
}, z.core.$strip>], "kind">>;
|
|
70
|
+
}, z.core.$strip>], "kind">>;
|
|
71
|
+
git: z.ZodNullable<z.ZodObject<{
|
|
72
|
+
branch: z.ZodNullable<z.ZodString>;
|
|
73
|
+
commit: z.ZodString;
|
|
74
|
+
dirty: z.ZodBoolean;
|
|
75
|
+
}, z.core.$strip>>;
|
|
76
|
+
ended: z.ZodNullable<z.ZodObject<{
|
|
77
|
+
outcome: z.ZodString;
|
|
78
|
+
exitCode: z.ZodNullable<z.ZodNumber>;
|
|
79
|
+
signal: z.ZodNullable<z.ZodString>;
|
|
80
|
+
ms: z.ZodNullable<z.ZodNumber>;
|
|
81
|
+
tests: z.ZodNullable<z.ZodObject<{
|
|
82
|
+
passed: z.ZodNumber;
|
|
83
|
+
failed: z.ZodNumber;
|
|
84
|
+
skipped: z.ZodNumber;
|
|
85
|
+
}, z.core.$strip>>;
|
|
86
|
+
testsIncomplete: z.ZodNullable<z.ZodString>;
|
|
87
|
+
resources: z.ZodNullable<z.ZodType<import("../../../core/resource.ts").ResourceRanFacts<import("../../../resources.ts").Resources>, import("../../../core/resource.ts").ResourceRanFacts<import("../../../resources.ts").Resources>, z.core.$ZodTypeInternals<import("../../../core/resource.ts").ResourceRanFacts<import("../../../resources.ts").Resources>, import("../../../core/resource.ts").ResourceRanFacts<import("../../../resources.ts").Resources>>>>;
|
|
88
|
+
}, z.core.$strip>>;
|
|
89
|
+
finished: z.ZodBoolean;
|
|
90
|
+
logs: z.ZodArray<z.ZodObject<{
|
|
91
|
+
step: z.ZodEnum<{
|
|
92
|
+
apply: "apply";
|
|
93
|
+
build: "build";
|
|
94
|
+
command: "command";
|
|
95
|
+
install: "install";
|
|
96
|
+
snapshot: "snapshot";
|
|
97
|
+
}>;
|
|
98
|
+
path: z.ZodString;
|
|
99
|
+
}, z.core.$strip>>;
|
|
100
|
+
unreadableTestLines: z.ZodNumber;
|
|
101
|
+
timeline: z.ZodNullable<z.ZodObject<{
|
|
102
|
+
startedAt: z.ZodString;
|
|
103
|
+
totalMs: z.ZodNumber;
|
|
104
|
+
rows: z.ZodArray<z.ZodObject<{
|
|
105
|
+
name: z.ZodEnum<{
|
|
106
|
+
cleanup: "cleanup";
|
|
107
|
+
mint: "mint";
|
|
108
|
+
runner: "runner";
|
|
109
|
+
tests: "tests";
|
|
110
|
+
testserver: "testserver";
|
|
111
|
+
}>;
|
|
112
|
+
startMs: z.ZodNumber;
|
|
113
|
+
endMs: z.ZodNumber;
|
|
114
|
+
outcome: z.ZodEnum<{
|
|
115
|
+
done: "done";
|
|
116
|
+
failed: "failed";
|
|
117
|
+
stopped: "stopped";
|
|
118
|
+
unfinished: "unfinished";
|
|
119
|
+
}>;
|
|
120
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
121
|
+
name: z.ZodEnum<{
|
|
122
|
+
[x: string]: string;
|
|
123
|
+
}>;
|
|
124
|
+
startMs: z.ZodNumber;
|
|
125
|
+
endMs: z.ZodNumber;
|
|
126
|
+
outcome: z.ZodEnum<{
|
|
127
|
+
done: "done";
|
|
128
|
+
failed: "failed";
|
|
129
|
+
stopped: "stopped";
|
|
130
|
+
unfinished: "unfinished";
|
|
131
|
+
}>;
|
|
132
|
+
}, z.core.$strip>>;
|
|
133
|
+
idleMs: z.ZodNumber;
|
|
134
|
+
snapshot: z.ZodOptional<z.ZodEnum<{
|
|
135
|
+
built: "built";
|
|
136
|
+
reused: "reused";
|
|
137
|
+
}>>;
|
|
138
|
+
sandboxes: z.ZodOptional<z.ZodObject<{
|
|
139
|
+
reused: z.ZodNumber;
|
|
140
|
+
created: z.ZodNumber;
|
|
141
|
+
}, z.core.$strip>>;
|
|
142
|
+
}, z.core.$strip>>;
|
|
143
|
+
criticalPath: z.ZodArray<z.ZodEnum<{
|
|
144
|
+
cleanup: "cleanup";
|
|
145
|
+
mint: "mint";
|
|
146
|
+
runner: "runner";
|
|
147
|
+
tests: "tests";
|
|
148
|
+
testserver: "testserver";
|
|
149
|
+
}>>;
|
|
150
|
+
}, z.core.$strip>>;
|
|
151
|
+
selection: z.ZodObject<{
|
|
152
|
+
failed: z.ZodBoolean;
|
|
153
|
+
test: z.ZodNullable<z.ZodString>;
|
|
154
|
+
}, z.core.$strip>;
|
|
155
|
+
tests: z.ZodArray<z.ZodObject<{
|
|
156
|
+
id: z.ZodString;
|
|
157
|
+
file: z.ZodString;
|
|
158
|
+
test: z.ZodString;
|
|
159
|
+
state: z.ZodEnum<{
|
|
160
|
+
fail: "fail";
|
|
161
|
+
pass: "pass";
|
|
162
|
+
skip: "skip";
|
|
163
|
+
}>;
|
|
164
|
+
retryCount: z.ZodNumber;
|
|
165
|
+
flaky: z.ZodBoolean;
|
|
166
|
+
errors: z.ZodArray<z.ZodObject<{
|
|
167
|
+
name: z.ZodString;
|
|
168
|
+
message: z.ZodString;
|
|
169
|
+
stack: z.ZodNullable<z.ZodString>;
|
|
170
|
+
diff: z.ZodNullable<z.ZodString>;
|
|
171
|
+
}, z.core.$strip>>;
|
|
172
|
+
selected: z.ZodBoolean;
|
|
173
|
+
output: z.ZodNullable<z.ZodObject<{
|
|
174
|
+
text: z.ZodString;
|
|
175
|
+
droppedChars: z.ZodNumber;
|
|
176
|
+
}, z.core.$strip>>;
|
|
177
|
+
}, z.core.$strip>>;
|
|
178
|
+
}, z.core.$strip>;
|
|
179
|
+
}, {
|
|
180
|
+
shown: unknown;
|
|
181
|
+
}, {
|
|
182
|
+
runsUnreadable: z.ZodObject<{
|
|
183
|
+
path: z.ZodString;
|
|
184
|
+
message: z.ZodString;
|
|
185
|
+
}, z.core.$strip>;
|
|
186
|
+
runNotFound: z.ZodObject<{
|
|
187
|
+
id: z.ZodString;
|
|
188
|
+
}, z.core.$strip>;
|
|
189
|
+
noRuns: z.ZodObject<{
|
|
190
|
+
scope: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
191
|
+
kind: z.ZodLiteral<"config">;
|
|
192
|
+
configFile: z.ZodString;
|
|
193
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
194
|
+
kind: z.ZodLiteral<"all">;
|
|
195
|
+
why: z.ZodEnum<{
|
|
196
|
+
flag: "flag";
|
|
197
|
+
"no-config-file": "no-config-file";
|
|
198
|
+
}>;
|
|
199
|
+
}, z.core.$strip>], "kind">;
|
|
200
|
+
}, z.core.$strip>;
|
|
201
|
+
}, {
|
|
202
|
+
readonly runsUnreadable: {
|
|
203
|
+
readonly exitCode: 1;
|
|
204
|
+
readonly description: "storm couldn't read the run directories.";
|
|
205
|
+
readonly schema: z.ZodObject<{
|
|
206
|
+
path: z.ZodString;
|
|
207
|
+
message: z.ZodString;
|
|
208
|
+
}, z.core.$strip>;
|
|
209
|
+
readonly render: ({ path, message }: {
|
|
210
|
+
readonly path: string;
|
|
211
|
+
readonly message: string;
|
|
212
|
+
}) => {
|
|
213
|
+
message: string;
|
|
214
|
+
rows: (readonly ["Path", string])[];
|
|
215
|
+
};
|
|
216
|
+
};
|
|
217
|
+
readonly runNotFound: {
|
|
218
|
+
readonly exitCode: 1;
|
|
219
|
+
readonly description: "No run directory has the id given: it was never a run on this machine, or it was removed.";
|
|
220
|
+
readonly schema: z.ZodObject<{
|
|
221
|
+
id: z.ZodString;
|
|
222
|
+
}, z.core.$strip>;
|
|
223
|
+
readonly render: ({ id }: {
|
|
224
|
+
readonly id: string;
|
|
225
|
+
}) => {
|
|
226
|
+
message: string;
|
|
227
|
+
next: {
|
|
228
|
+
type: "command";
|
|
229
|
+
argv: string[];
|
|
230
|
+
label: string;
|
|
231
|
+
}[];
|
|
232
|
+
};
|
|
233
|
+
};
|
|
234
|
+
readonly noRuns: {
|
|
235
|
+
readonly exitCode: 1;
|
|
236
|
+
readonly description: "Without an id, no run in the scope has finished.";
|
|
237
|
+
readonly schema: z.ZodObject<{
|
|
238
|
+
scope: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
239
|
+
kind: z.ZodLiteral<"config">;
|
|
240
|
+
configFile: z.ZodString;
|
|
241
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
242
|
+
kind: z.ZodLiteral<"all">;
|
|
243
|
+
why: z.ZodEnum<{
|
|
244
|
+
flag: "flag";
|
|
245
|
+
"no-config-file": "no-config-file";
|
|
246
|
+
}>;
|
|
247
|
+
}, z.core.$strip>], "kind">;
|
|
248
|
+
}, z.core.$strip>;
|
|
249
|
+
readonly render: ({ scope }: {
|
|
250
|
+
scope: {
|
|
251
|
+
kind: "config";
|
|
252
|
+
configFile: string;
|
|
253
|
+
} | {
|
|
254
|
+
kind: "all";
|
|
255
|
+
why: "flag" | "no-config-file";
|
|
256
|
+
};
|
|
257
|
+
}) => {
|
|
258
|
+
message: string;
|
|
259
|
+
next: {
|
|
260
|
+
type: "command";
|
|
261
|
+
argv: string[];
|
|
262
|
+
label: string;
|
|
263
|
+
}[];
|
|
264
|
+
} | {
|
|
265
|
+
message: string;
|
|
266
|
+
next: {
|
|
267
|
+
type: "text";
|
|
268
|
+
text: string;
|
|
269
|
+
}[];
|
|
270
|
+
};
|
|
271
|
+
};
|
|
272
|
+
}>, import("@vercel/clinkr").OutcomeOf<import("@vercel/clinkr").Outcomes<{
|
|
273
|
+
shown: z.ZodObject<{
|
|
274
|
+
id: z.ZodString;
|
|
275
|
+
path: z.ZodString;
|
|
276
|
+
active: z.ZodBoolean;
|
|
277
|
+
startedAt: z.ZodNullable<z.ZodString>;
|
|
278
|
+
cwd: z.ZodNullable<z.ZodString>;
|
|
279
|
+
configFile: z.ZodNullable<z.ZodString>;
|
|
280
|
+
argv: z.ZodNullable<z.ZodArray<z.ZodString>>;
|
|
281
|
+
where: z.ZodNullable<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
282
|
+
kind: z.ZodLiteral<"local">;
|
|
283
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
284
|
+
kind: z.ZodLiteral<"runner">;
|
|
285
|
+
team: z.ZodString;
|
|
286
|
+
project: z.ZodString;
|
|
287
|
+
region: z.ZodString;
|
|
288
|
+
runtime: z.ZodString;
|
|
289
|
+
vcpus: z.ZodNumber;
|
|
290
|
+
base: z.ZodString;
|
|
291
|
+
baseRef: z.ZodString;
|
|
292
|
+
sandbox: z.ZodNullable<z.ZodString>;
|
|
293
|
+
sandboxUrl: z.ZodNullable<z.ZodString>;
|
|
294
|
+
keptUntil: z.ZodNullable<z.ZodString>;
|
|
295
|
+
keptMinutesLeft: z.ZodNullable<z.ZodNumber>;
|
|
296
|
+
snapshot: z.ZodNullable<z.ZodObject<{
|
|
297
|
+
id: z.ZodString;
|
|
298
|
+
base: z.ZodString;
|
|
299
|
+
built: z.ZodBoolean;
|
|
300
|
+
branch: z.ZodNullable<z.ZodString>;
|
|
301
|
+
head: z.ZodNullable<z.ZodString>;
|
|
302
|
+
url: z.ZodString;
|
|
303
|
+
}, z.core.$strip>>;
|
|
304
|
+
save: z.ZodNullable<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
305
|
+
kind: z.ZodLiteral<"saved">;
|
|
306
|
+
snapshotId: z.ZodString;
|
|
307
|
+
base: z.ZodString;
|
|
308
|
+
branch: z.ZodString;
|
|
309
|
+
head: z.ZodString;
|
|
310
|
+
ms: z.ZodNumber;
|
|
311
|
+
sizeBytes: z.ZodNumber;
|
|
312
|
+
entryWritten: z.ZodBoolean;
|
|
313
|
+
url: z.ZodString;
|
|
314
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
315
|
+
kind: z.ZodLiteral<"skipped">;
|
|
316
|
+
reason: z.ZodLiteral<"detached-head">;
|
|
317
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
318
|
+
kind: z.ZodLiteral<"failed">;
|
|
319
|
+
step: z.ZodEnum<{
|
|
320
|
+
"save-snapshot": "save-snapshot";
|
|
321
|
+
scrub: "scrub";
|
|
322
|
+
}>;
|
|
323
|
+
message: z.ZodString;
|
|
324
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
325
|
+
kind: z.ZodLiteral<"stopped">;
|
|
326
|
+
}, z.core.$strip>], "kind">>;
|
|
45
327
|
}, z.core.$strip>], "kind">>;
|
|
46
328
|
git: z.ZodNullable<z.ZodObject<{
|
|
47
329
|
branch: z.ZodNullable<z.ZodString>;
|
|
@@ -173,4 +455,75 @@ export declare function command(cmd: CommandBuilder<StormApp>): import("@vercel/
|
|
|
173
455
|
}>;
|
|
174
456
|
}, z.core.$strip>], "kind">;
|
|
175
457
|
}, z.core.$strip>;
|
|
176
|
-
}
|
|
458
|
+
}, {
|
|
459
|
+
readonly runsUnreadable: {
|
|
460
|
+
readonly exitCode: 1;
|
|
461
|
+
readonly description: "storm couldn't read the run directories.";
|
|
462
|
+
readonly schema: z.ZodObject<{
|
|
463
|
+
path: z.ZodString;
|
|
464
|
+
message: z.ZodString;
|
|
465
|
+
}, z.core.$strip>;
|
|
466
|
+
readonly render: ({ path, message }: {
|
|
467
|
+
readonly path: string;
|
|
468
|
+
readonly message: string;
|
|
469
|
+
}) => {
|
|
470
|
+
message: string;
|
|
471
|
+
rows: (readonly ["Path", string])[];
|
|
472
|
+
};
|
|
473
|
+
};
|
|
474
|
+
readonly runNotFound: {
|
|
475
|
+
readonly exitCode: 1;
|
|
476
|
+
readonly description: "No run directory has the id given: it was never a run on this machine, or it was removed.";
|
|
477
|
+
readonly schema: z.ZodObject<{
|
|
478
|
+
id: z.ZodString;
|
|
479
|
+
}, z.core.$strip>;
|
|
480
|
+
readonly render: ({ id }: {
|
|
481
|
+
readonly id: string;
|
|
482
|
+
}) => {
|
|
483
|
+
message: string;
|
|
484
|
+
next: {
|
|
485
|
+
type: "command";
|
|
486
|
+
argv: string[];
|
|
487
|
+
label: string;
|
|
488
|
+
}[];
|
|
489
|
+
};
|
|
490
|
+
};
|
|
491
|
+
readonly noRuns: {
|
|
492
|
+
readonly exitCode: 1;
|
|
493
|
+
readonly description: "Without an id, no run in the scope has finished.";
|
|
494
|
+
readonly schema: z.ZodObject<{
|
|
495
|
+
scope: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
496
|
+
kind: z.ZodLiteral<"config">;
|
|
497
|
+
configFile: z.ZodString;
|
|
498
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
499
|
+
kind: z.ZodLiteral<"all">;
|
|
500
|
+
why: z.ZodEnum<{
|
|
501
|
+
flag: "flag";
|
|
502
|
+
"no-config-file": "no-config-file";
|
|
503
|
+
}>;
|
|
504
|
+
}, z.core.$strip>], "kind">;
|
|
505
|
+
}, z.core.$strip>;
|
|
506
|
+
readonly render: ({ scope }: {
|
|
507
|
+
scope: {
|
|
508
|
+
kind: "config";
|
|
509
|
+
configFile: string;
|
|
510
|
+
} | {
|
|
511
|
+
kind: "all";
|
|
512
|
+
why: "flag" | "no-config-file";
|
|
513
|
+
};
|
|
514
|
+
}) => {
|
|
515
|
+
message: string;
|
|
516
|
+
next: {
|
|
517
|
+
type: "command";
|
|
518
|
+
argv: string[];
|
|
519
|
+
label: string;
|
|
520
|
+
}[];
|
|
521
|
+
} | {
|
|
522
|
+
message: string;
|
|
523
|
+
next: {
|
|
524
|
+
type: "text";
|
|
525
|
+
text: string;
|
|
526
|
+
}[];
|
|
527
|
+
};
|
|
528
|
+
};
|
|
529
|
+
}>>, StormApp, false>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export const metadata = {
|
|
2
|
-
description: "Show a past run from its run directory: its command, config file, working directory, the branch and commit it started from, start, how long it took and how it ended; where its command ran, on this machine or in a runner sandbox, with the sandbox's name, region, vCPUs, runtime and page in the Vercel dashboard, until when the run kept it running, with its Connect page while it runs, its control plane team and project, the run's base and the runner snapshot it started from, with its page; each Testserver sandbox it used, with its log viewer URL; the run logs it has, each with the storm runs logs command that prints it; its waterfall; and each test's final result, in color on a terminal that takes it. With --failed or --test, only the selected tests, how many of all they are, and each one's errors and test output, the last 8 MiB of what it printed, failure reports included. Without an id, the newest finished run of the storm.config.ts found from the working directory, or of every config with --all; pass the id `storm vitest` or `storm exec` printed when another run may have finished since. A run's test results are saved once it finishes. Changes nothing.",
|
|
2
|
+
description: "Show a past run from its run directory: its command, config file, working directory, the branch and commit it started from, start, how long it took and how it ended; where its command ran, on this machine or in a runner sandbox, with the sandbox's name, region, vCPUs, runtime and page in the Vercel dashboard, until when the run kept it running, with its Connect page while it runs, its control plane team and project, the run's base and the runner snapshot it started from, with a branch snapshot's branch and commit, and its page, and the branch snapshot the run saved, with its page, or why it saved none; each Testserver sandbox it used, with its log viewer URL; the run logs it has, each with the storm runs logs command that prints it; its waterfall; and each test's final result, in color on a terminal that takes it. With --failed or --test, only the selected tests, how many of all they are, and each one's errors and test output, the last 8 MiB of what it printed, failure reports included. Without an id, the newest finished run of the storm.config.ts found from the working directory, or of every config with --all; pass the id `storm vitest` or `storm exec` printed when another run may have finished since. A run's test results are saved once it finishes. Changes nothing.",
|
|
3
3
|
summary: "Show a past run and its tests.",
|
|
4
4
|
usages: ["[<id>] [--failed] [--test <TEXT>] [--all]"],
|
|
5
5
|
fields: {
|
|
@@ -28,8 +28,33 @@ export declare const outcomes: import("@vercel/clinkr").Outcomes<{
|
|
|
28
28
|
id: z.ZodString;
|
|
29
29
|
base: z.ZodString;
|
|
30
30
|
built: z.ZodBoolean;
|
|
31
|
+
branch: z.ZodNullable<z.ZodString>;
|
|
32
|
+
head: z.ZodNullable<z.ZodString>;
|
|
31
33
|
url: z.ZodString;
|
|
32
34
|
}, z.core.$strip>>;
|
|
35
|
+
save: z.ZodNullable<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
36
|
+
kind: z.ZodLiteral<"saved">;
|
|
37
|
+
snapshotId: z.ZodString;
|
|
38
|
+
base: z.ZodString;
|
|
39
|
+
branch: z.ZodString;
|
|
40
|
+
head: z.ZodString;
|
|
41
|
+
ms: z.ZodNumber;
|
|
42
|
+
sizeBytes: z.ZodNumber;
|
|
43
|
+
entryWritten: z.ZodBoolean;
|
|
44
|
+
url: z.ZodString;
|
|
45
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
46
|
+
kind: z.ZodLiteral<"skipped">;
|
|
47
|
+
reason: z.ZodLiteral<"detached-head">;
|
|
48
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
49
|
+
kind: z.ZodLiteral<"failed">;
|
|
50
|
+
step: z.ZodEnum<{
|
|
51
|
+
"save-snapshot": "save-snapshot";
|
|
52
|
+
scrub: "scrub";
|
|
53
|
+
}>;
|
|
54
|
+
message: z.ZodString;
|
|
55
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
56
|
+
kind: z.ZodLiteral<"stopped">;
|
|
57
|
+
}, z.core.$strip>], "kind">>;
|
|
33
58
|
}, z.core.$strip>], "kind">>;
|
|
34
59
|
git: z.ZodNullable<z.ZodObject<{
|
|
35
60
|
branch: z.ZodNullable<z.ZodString>;
|
|
@@ -161,4 +186,75 @@ export declare const outcomes: import("@vercel/clinkr").Outcomes<{
|
|
|
161
186
|
}>;
|
|
162
187
|
}, z.core.$strip>], "kind">;
|
|
163
188
|
}, z.core.$strip>;
|
|
189
|
+
}, {
|
|
190
|
+
readonly runsUnreadable: {
|
|
191
|
+
readonly exitCode: 1;
|
|
192
|
+
readonly description: "storm couldn't read the run directories.";
|
|
193
|
+
readonly schema: z.ZodObject<{
|
|
194
|
+
path: z.ZodString;
|
|
195
|
+
message: z.ZodString;
|
|
196
|
+
}, z.core.$strip>;
|
|
197
|
+
readonly render: ({ path, message }: {
|
|
198
|
+
readonly path: string;
|
|
199
|
+
readonly message: string;
|
|
200
|
+
}) => {
|
|
201
|
+
message: string;
|
|
202
|
+
rows: (readonly ["Path", string])[];
|
|
203
|
+
};
|
|
204
|
+
};
|
|
205
|
+
readonly runNotFound: {
|
|
206
|
+
readonly exitCode: 1;
|
|
207
|
+
readonly description: "No run directory has the id given: it was never a run on this machine, or it was removed.";
|
|
208
|
+
readonly schema: z.ZodObject<{
|
|
209
|
+
id: z.ZodString;
|
|
210
|
+
}, z.core.$strip>;
|
|
211
|
+
readonly render: ({ id }: {
|
|
212
|
+
readonly id: string;
|
|
213
|
+
}) => {
|
|
214
|
+
message: string;
|
|
215
|
+
next: {
|
|
216
|
+
type: "command";
|
|
217
|
+
argv: string[];
|
|
218
|
+
label: string;
|
|
219
|
+
}[];
|
|
220
|
+
};
|
|
221
|
+
};
|
|
222
|
+
readonly noRuns: {
|
|
223
|
+
readonly exitCode: 1;
|
|
224
|
+
readonly description: "Without an id, no run in the scope has finished.";
|
|
225
|
+
readonly schema: z.ZodObject<{
|
|
226
|
+
scope: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
227
|
+
kind: z.ZodLiteral<"config">;
|
|
228
|
+
configFile: z.ZodString;
|
|
229
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
230
|
+
kind: z.ZodLiteral<"all">;
|
|
231
|
+
why: z.ZodEnum<{
|
|
232
|
+
flag: "flag";
|
|
233
|
+
"no-config-file": "no-config-file";
|
|
234
|
+
}>;
|
|
235
|
+
}, z.core.$strip>], "kind">;
|
|
236
|
+
}, z.core.$strip>;
|
|
237
|
+
readonly render: ({ scope }: {
|
|
238
|
+
scope: {
|
|
239
|
+
kind: "config";
|
|
240
|
+
configFile: string;
|
|
241
|
+
} | {
|
|
242
|
+
kind: "all";
|
|
243
|
+
why: "flag" | "no-config-file";
|
|
244
|
+
};
|
|
245
|
+
}) => {
|
|
246
|
+
message: string;
|
|
247
|
+
next: {
|
|
248
|
+
type: "command";
|
|
249
|
+
argv: string[];
|
|
250
|
+
label: string;
|
|
251
|
+
}[];
|
|
252
|
+
} | {
|
|
253
|
+
message: string;
|
|
254
|
+
next: {
|
|
255
|
+
type: "text";
|
|
256
|
+
text: string;
|
|
257
|
+
}[];
|
|
258
|
+
};
|
|
259
|
+
};
|
|
164
260
|
}>;
|
|
@@ -231,11 +231,40 @@ function whereRows(shown) {
|
|
|
231
231
|
: [
|
|
232
232
|
[
|
|
233
233
|
"Snapshot",
|
|
234
|
-
[
|
|
234
|
+
[
|
|
235
|
+
`${snapshot.id} of ${short(snapshot.base)}, ${snapshot.built ? "built" : "reused"}${snapshot.branch === null || snapshot.head === null ? "" : `, branch ${snapshot.branch} at ${short(snapshot.head)}`}`,
|
|
236
|
+
` ${snapshot.url}`,
|
|
237
|
+
],
|
|
235
238
|
],
|
|
236
239
|
]),
|
|
240
|
+
...saveRows(where.save),
|
|
237
241
|
];
|
|
238
242
|
}
|
|
243
|
+
/** Each step of a branch snapshot's save, as a person names it. */
|
|
244
|
+
const SAVE_STEPS = { scrub: "scrub", "save-snapshot": "save" };
|
|
245
|
+
/** The row for the branch snapshot the run saved the runner sandbox as, or why it didn't; none without the flag. */
|
|
246
|
+
function saveRows(save) {
|
|
247
|
+
if (save === null)
|
|
248
|
+
return [];
|
|
249
|
+
switch (save.kind) {
|
|
250
|
+
case "saved":
|
|
251
|
+
return [
|
|
252
|
+
[
|
|
253
|
+
"Saved",
|
|
254
|
+
[
|
|
255
|
+
`${save.snapshotId} of ${short(save.base)}, branch ${save.branch} at ${short(save.head)}${save.entryWritten ? "" : ", not in the cache"}`,
|
|
256
|
+
` ${save.url}`,
|
|
257
|
+
],
|
|
258
|
+
],
|
|
259
|
+
];
|
|
260
|
+
case "skipped":
|
|
261
|
+
return [["Saved", { text: "nothing: HEAD was detached", tone: "muted" }]];
|
|
262
|
+
case "failed":
|
|
263
|
+
return [["Saved", { text: `nothing: the ${SAVE_STEPS[save.step]} failed: ${save.message}`, tone: "muted" }]];
|
|
264
|
+
case "stopped":
|
|
265
|
+
return [["Saved", { text: "nothing: the run stopped", tone: "muted" }]];
|
|
266
|
+
}
|
|
267
|
+
}
|
|
239
268
|
/**
|
|
240
269
|
* The row for the runner sandbox the run kept running, if it did: until when, in success while it still runs, with its
|
|
241
270
|
* Connect page in the Vercel dashboard, or muted once it has stopped.
|