@cat-factory/contracts 0.287.1 → 0.290.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/binary-capabilities.d.ts +166 -0
- package/dist/binary-capabilities.d.ts.map +1 -1
- package/dist/binary-capabilities.js +267 -18
- package/dist/binary-capabilities.js.map +1 -1
- package/dist/binary-generators.d.ts +130 -4
- package/dist/binary-generators.d.ts.map +1 -1
- package/dist/binary-generators.js +96 -4
- package/dist/binary-generators.js.map +1 -1
- package/dist/debug-api.d.ts +2 -2
- package/dist/execution.d.ts +22 -10
- package/dist/execution.d.ts.map +1 -1
- package/dist/execution.js +5 -2
- package/dist/execution.js.map +1 -1
- package/dist/pipeline-environment-lifecycle.d.ts +12 -10
- package/dist/pipeline-environment-lifecycle.d.ts.map +1 -1
- package/dist/pipeline-environment-lifecycle.js +13 -11
- package/dist/pipeline-environment-lifecycle.js.map +1 -1
- package/dist/routes/agent-runs.d.ts +2 -2
- package/dist/routes/bug-hunt.d.ts +2 -2
- package/dist/routes/debug-api.d.ts +1 -1
- package/dist/routes/execution.d.ts +9 -9
- package/dist/routes/human-review.d.ts +1 -1
- package/dist/routes/human-test.d.ts +5 -5
- package/dist/routes/public-evidence.d.ts +16 -0
- package/dist/routes/public-evidence.d.ts.map +1 -1
- package/dist/routes/visual-confirm.d.ts +3 -3
- package/dist/routes/workspaces.d.ts +30 -2
- package/dist/routes/workspaces.d.ts.map +1 -1
- package/dist/run-evidence.d.ts +114 -1
- package/dist/run-evidence.d.ts.map +1 -1
- package/dist/run-evidence.js +170 -0
- package/dist/run-evidence.js.map +1 -1
- package/dist/run-outcome.d.ts +135 -2
- package/dist/run-outcome.d.ts.map +1 -1
- package/dist/run-outcome.js +277 -3
- package/dist/run-outcome.js.map +1 -1
- package/dist/snapshot.d.ts +15 -1
- package/dist/snapshot.d.ts.map +1 -1
- package/dist/tool-servers.d.ts +9 -7
- package/dist/tool-servers.d.ts.map +1 -1
- package/dist/tool-servers.js +8 -5
- package/dist/tool-servers.js.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run-evidence.d.ts","sourceRoot":"","sources":["../src/run-evidence.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAC1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;
|
|
1
|
+
{"version":3,"file":"run-evidence.d.ts","sourceRoot":"","sources":["../src/run-evidence.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAC1C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AAC1D,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;AACnF,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAA;AACjE,OAAO,KAAK,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAC/E,OAAO,KAAK,EAAE,kBAAkB,EAAE,wBAAwB,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AA8B5F,wCAAwC;AACxC,eAAO,MAAM,iBAAiB,eAAe,CAAA;AAE7C;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,aAAa,CAAA;AAE7C;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,aAAa,CAAA;AAE7C;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAElD;AAED;;;;;;;;;GASG;AACH,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,SAAS,YAAY,EAAE,EAC9B,OAAO,EAAE,CAAC,IAAI,EAAE,YAAY,KAAK,OAAO,EACxC,WAAW,EAAE,CAAC,IAAI,EAAE,YAAY,KAAK,OAAO,GAC3C,YAAY,GAAG,SAAS,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AAS,YAAY,EAAE,GAAG,OAAO,CAKnF;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,yBAAyB;IACxC,uFAAuF;IACvF,EAAE,EAAE,MAAM,CAAA;IACV,GAAG,EAAE,MAAM,GAAG,IAAI,CAAA;IAClB,MAAM,EAAE,iBAAiB,CAAA;IACzB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,2EAA2E;IAC3E,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,MAAM,EAAE,YAAY,GAAG,YAAY,CAAA;IACnC;;;;;;;;;OASG;IACH,UAAU,EAAE,OAAO,CAAA;CACpB;AAED;;;;;;;GAOG;AACH,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,yBAAyB,GAAG,OAAO,CAEtF;AAkDD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,0BAA0B,CACxC,KAAK,EAAE,SAAS,YAAY,EAAE,GAC7B,yBAAyB,EAAE,CAY7B"}
|
package/dist/run-evidence.js
CHANGED
|
@@ -27,6 +27,18 @@ import { UI_TESTER_AGENT_KIND } from './visual-pipeline.js';
|
|
|
27
27
|
// ---------------------------------------------------------------------------
|
|
28
28
|
/** The API tester gate's agent kind. */
|
|
29
29
|
export const TESTER_AGENT_KIND = 'tester-api';
|
|
30
|
+
/**
|
|
31
|
+
* The agent kind that PROVISIONS a run's ephemeral environments, the sole provisioner.
|
|
32
|
+
* `pipeline-environment-lifecycle.ts` states its authoring rules relative to it and re-exports
|
|
33
|
+
* it (see the note there for why the definition lives on this side).
|
|
34
|
+
*/
|
|
35
|
+
export const DEPLOYER_AGENT_KIND = 'deployer';
|
|
36
|
+
/**
|
|
37
|
+
* The agent kind that RECLAIMS them again, the deployer's counterpart at the other end of the
|
|
38
|
+
* lifecycle. It tears down by the environment ids the deployer RECORDED on its own step, so it
|
|
39
|
+
* has nothing whatsoever to do without one earlier in the chain.
|
|
40
|
+
*/
|
|
41
|
+
export const DISPOSER_AGENT_KIND = 'disposer';
|
|
30
42
|
/**
|
|
31
43
|
* Whether an agent kind is one of the tester gate kinds (API or UI).
|
|
32
44
|
*
|
|
@@ -212,4 +224,162 @@ export function countCapturedViews(pairs) {
|
|
|
212
224
|
captured += 1;
|
|
213
225
|
return captured;
|
|
214
226
|
}
|
|
227
|
+
// ---- The run's ephemeral environments --------------------------------------
|
|
228
|
+
//
|
|
229
|
+
// A run that provisions throwaway infrastructure is read twice as well: the verification
|
|
230
|
+
// report proves the three-leg lifecycle (up, exercised, reclaimed) for a reviewer, and the
|
|
231
|
+
// outcome summary answers the one question a designer has, which is whether there is something
|
|
232
|
+
// standing to click. Both start from the same producers on the run's own steps, so which steps
|
|
233
|
+
// each is folded from, which recorded states mean the environment is gone, and how the
|
|
234
|
+
// observations of one environment are reconciled are stated here rather than on either side.
|
|
235
|
+
/** The lifecycle states that mean an environment is no longer standing. */
|
|
236
|
+
const GONE_ENVIRONMENT_STATUSES = new Set(['torn_down', 'expired', 'failed']);
|
|
237
|
+
/**
|
|
238
|
+
* Whether a recorded lifecycle status means the environment is no longer standing.
|
|
239
|
+
*
|
|
240
|
+
* `tearing_down` is deliberately NOT one of them: a teardown that has been asked for is not a
|
|
241
|
+
* teardown that happened, and the two surfaces reading this need to keep them apart (the report
|
|
242
|
+
* because an unfinished reclaim is not proof of one, the summary because it is a different thing
|
|
243
|
+
* to tell a person than "it is gone").
|
|
244
|
+
*/
|
|
245
|
+
export function isEnvironmentGone(status) {
|
|
246
|
+
return GONE_ENVIRONMENT_STATUSES.has(status);
|
|
247
|
+
}
|
|
248
|
+
/** Every deployer step of a run, in pipeline order. */
|
|
249
|
+
export function deployerSteps(steps) {
|
|
250
|
+
return steps.filter((step) => step.agentKind === DEPLOYER_AGENT_KIND);
|
|
251
|
+
}
|
|
252
|
+
/**
|
|
253
|
+
* The per-frame deploy outcomes this run recorded, keyed by service-frame block id.
|
|
254
|
+
*
|
|
255
|
+
* Folded over EVERY deployer step rather than read off one of them, because a pipeline may
|
|
256
|
+
* deploy more than once (a re-deploy after a fix, a `human-test` gate looping back to rebuild
|
|
257
|
+
* the environment a person is testing), and a later deploy of the same frame WINS: it superseded
|
|
258
|
+
* the earlier environment, so its row is the live one and the earlier id is a tombstone.
|
|
259
|
+
*
|
|
260
|
+
* That is the rule the disposer has always reclaimed by, and it is stated here because the two
|
|
261
|
+
* evidence reductions read the same frames it tears down. Reading a single step instead drops
|
|
262
|
+
* every frame the earlier deploys settled, which does not merely lose rows: the superseded
|
|
263
|
+
* environment is then unaccounted for, and a summary that lists what no frame claims surfaces it
|
|
264
|
+
* again as a live preview URL pointing at something the re-deploy already replaced.
|
|
265
|
+
*/
|
|
266
|
+
export function deployedFrames(steps) {
|
|
267
|
+
const byFrame = new Map();
|
|
268
|
+
for (const step of deployerSteps(steps)) {
|
|
269
|
+
for (const [frameId, state] of Object.entries(step.deployEnvs ?? {}))
|
|
270
|
+
byFrame.set(frameId, state);
|
|
271
|
+
}
|
|
272
|
+
return byFrame;
|
|
273
|
+
}
|
|
274
|
+
/**
|
|
275
|
+
* The per-frame reclaim outcomes this run recorded, the mirror of {@link deployedFrames} at the
|
|
276
|
+
* other end of the lifecycle and folded the same way, for the same reason: a run that deployed
|
|
277
|
+
* twice disposes twice.
|
|
278
|
+
*/
|
|
279
|
+
export function disposedFrames(steps) {
|
|
280
|
+
const byFrame = new Map();
|
|
281
|
+
for (const step of steps) {
|
|
282
|
+
if (step.agentKind !== DISPOSER_AGENT_KIND)
|
|
283
|
+
continue;
|
|
284
|
+
for (const [frameId, state] of Object.entries(step.disposeEnvs ?? {})) {
|
|
285
|
+
byFrame.set(frameId, state);
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
return byFrame;
|
|
289
|
+
}
|
|
290
|
+
/**
|
|
291
|
+
* Whether the run's deployer step DECLARED that the environments it provisions outlive the run
|
|
292
|
+
* (`StepOptions.retainEnvironment`).
|
|
293
|
+
*
|
|
294
|
+
* Read off the step the run actually dispatched rather than off the pipeline definition, which
|
|
295
|
+
* can be edited after the run started: every consumer of this is describing what THIS run did.
|
|
296
|
+
* It is what separates an environment still standing because that was the point from one still
|
|
297
|
+
* standing because the reclaim never happened, which is the difference between a preview URL a
|
|
298
|
+
* reviewer is meant to keep clicking and a leak.
|
|
299
|
+
*/
|
|
300
|
+
export function declaresRetainedEnvironment(steps) {
|
|
301
|
+
return steps.some((step) => step.agentKind === DEPLOYER_AGENT_KIND && step.stepOptions?.retainEnvironment === true);
|
|
302
|
+
}
|
|
303
|
+
/**
|
|
304
|
+
* Whether an observation describes an environment that is no longer standing, by either route:
|
|
305
|
+
* a recorded terminal status, or a later deploy having replaced it.
|
|
306
|
+
*
|
|
307
|
+
* The total form of {@link isEnvironmentGone} for a run's own observations, and the one both
|
|
308
|
+
* reductions ask. Reading the status alone answers "was it torn down", which is a strictly
|
|
309
|
+
* narrower question than "is it gone".
|
|
310
|
+
*/
|
|
311
|
+
export function isObservedEnvironmentGone(observed) {
|
|
312
|
+
return observed.superseded || isEnvironmentGone(observed.status);
|
|
313
|
+
}
|
|
314
|
+
/**
|
|
315
|
+
* The environment identities an earlier deploy named that the run's CURRENT frame rows no longer
|
|
316
|
+
* do: the ids and URLs a later deploy of the same frame superseded.
|
|
317
|
+
*
|
|
318
|
+
* Both keys, because the two are how the same environment is named by producers that recorded it
|
|
319
|
+
* at different times: a deploy row predating `deployEnvs.environmentId` names its environment
|
|
320
|
+
* only by the URL it handed out.
|
|
321
|
+
*/
|
|
322
|
+
function supersededEnvironmentKeys(steps) {
|
|
323
|
+
const live = new Set();
|
|
324
|
+
for (const state of deployedFrames(steps).values()) {
|
|
325
|
+
if (state.environmentId)
|
|
326
|
+
live.add(state.environmentId);
|
|
327
|
+
if (state.url)
|
|
328
|
+
live.add(state.url);
|
|
329
|
+
}
|
|
330
|
+
const superseded = new Set();
|
|
331
|
+
for (const step of deployerSteps(steps)) {
|
|
332
|
+
for (const state of Object.values(step.deployEnvs ?? {})) {
|
|
333
|
+
for (const key of [state.environmentId, state.url]) {
|
|
334
|
+
if (key && !live.has(key))
|
|
335
|
+
superseded.add(key);
|
|
336
|
+
}
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
return superseded;
|
|
340
|
+
}
|
|
341
|
+
/** Narrow a producer's optional `expiresAt` / `lastError` to the observation's nullable shape. */
|
|
342
|
+
function observation(fields, source, superseded) {
|
|
343
|
+
return {
|
|
344
|
+
id: fields.id,
|
|
345
|
+
url: fields.url,
|
|
346
|
+
status: fields.status,
|
|
347
|
+
expiresAt: fields.expiresAt ?? null,
|
|
348
|
+
lastError: fields.lastError ?? null,
|
|
349
|
+
source,
|
|
350
|
+
superseded: superseded.has(fields.id) || (fields.url != null && superseded.has(fields.url)),
|
|
351
|
+
};
|
|
352
|
+
}
|
|
353
|
+
/**
|
|
354
|
+
* Everything the run's own steps observed about the environments it stood up: one row per
|
|
355
|
+
* environment id, carrying the LAST observation of it, in the order the run first saw each one.
|
|
356
|
+
*
|
|
357
|
+
* Two producers write these and both have to be folded in, because they are the same
|
|
358
|
+
* environments seen at different moments. A step PROJECTION (`step.environment`) is the weakest
|
|
359
|
+
* signal there is: the run's polls write it and never refresh it once the run settles, so an
|
|
360
|
+
* environment the TTL sweep reclaimed afterwards keeps a `ready` projection forever. The
|
|
361
|
+
* `human-test` gate's own record (`step.humanTest.environment`) is written over the same
|
|
362
|
+
* environment (the gate no longer provisions one: it READS what the deployer stood up), and on
|
|
363
|
+
* the way past it stamps `torn_down` for the environment it destroyed when the person confirmed.
|
|
364
|
+
*
|
|
365
|
+
* Folding the two by IDENTITY, later-wins, is what makes that teardown visible. Kept apart, the
|
|
366
|
+
* deployer's step projection still says `ready` for the same id, and a consumer that reads only
|
|
367
|
+
* projections offers a link to an environment the gate destroyed. Kept as two lists, the same
|
|
368
|
+
* environment appears twice under two producers, which reads as two.
|
|
369
|
+
*/
|
|
370
|
+
export function runEnvironmentObservations(steps) {
|
|
371
|
+
const superseded = supersededEnvironmentKeys(steps);
|
|
372
|
+
const byId = new Map();
|
|
373
|
+
for (const step of steps) {
|
|
374
|
+
const projected = step.environment;
|
|
375
|
+
if (projected)
|
|
376
|
+
byId.set(projected.id, observation(projected, 'projection', superseded));
|
|
377
|
+
// After the projection, not before: the two never land on one step today (the gate is not an
|
|
378
|
+
// env-projection kind), and where they ever do the gate's record is the later fact.
|
|
379
|
+
const tested = step.humanTest?.environment;
|
|
380
|
+
if (tested)
|
|
381
|
+
byId.set(tested.id, observation(tested, 'human_test', superseded));
|
|
382
|
+
}
|
|
383
|
+
return [...byId.values()];
|
|
384
|
+
}
|
|
215
385
|
//# sourceMappingURL=run-evidence.js.map
|
package/dist/run-evidence.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run-evidence.js","sourceRoot":"","sources":["../src/run-evidence.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"run-evidence.js","sourceRoot":"","sources":["../src/run-evidence.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAA;AAE3D,8EAA8E;AAC9E,0FAA0F;AAC1F,EAAE;AACF,gGAAgG;AAChG,4FAA4F;AAC5F,8FAA8F;AAC9F,8FAA8F;AAC9F,gGAAgG;AAChG,wDAAwD;AACxD,EAAE;AACF,+FAA+F;AAC/F,6FAA6F;AAC7F,kDAAkD;AAClD,+FAA+F;AAC/F,gGAAgG;AAChG,yFAAyF;AACzF,8DAA8D;AAC9D,+FAA+F;AAC/F,+CAA+C;AAC/C,EAAE;AACF,+FAA+F;AAC/F,+FAA+F;AAC/F,gGAAgG;AAChG,+FAA+F;AAC/F,8DAA8D;AAC9D,8EAA8E;AAE9E,wCAAwC;AACxC,MAAM,CAAC,MAAM,iBAAiB,GAAG,YAAY,CAAA;AAE7C;;;;GAIG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,UAAU,CAAA;AAE7C;;;;GAIG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,UAAU,CAAA;AAE7C;;;;;;GAMG;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MAAM,IAAI,GAAG,IAAI,GAAG,EAAqC,CAAA;IACzD,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,MAAM,SAAS,GAAG,IAAI,CAAC,WAAW,CAAA;QAClC,IAAI,SAAS;YAAE,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,EAAE,EAAE,WAAW,CAAC,SAAS,EAAE,YAAY,EAAE,UAAU,CAAC,CAAC,CAAA;QACvF,6FAA6F;QAC7F,oFAAoF;QACpF,MAAM,MAAM,GAAG,IAAI,CAAC,SAAS,EAAE,WAAW,CAAA;QAC1C,IAAI,MAAM;YAAE,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,EAAE,WAAW,CAAC,MAAM,EAAE,YAAY,EAAE,UAAU,CAAC,CAAC,CAAA;IAChF,CAAC;IACD,OAAO,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC,CAAA;AAC3B,CAAC"}
|
package/dist/run-outcome.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ import type { ServiceSpecView } from './spec.js';
|
|
|
7
7
|
* consumer would want to notice; never a compatibility switch (the surface is additive, so a
|
|
8
8
|
* consumer written against an older number keeps reading the fields it knows).
|
|
9
9
|
*/
|
|
10
|
-
export declare const RUN_OUTCOME_VERSION =
|
|
10
|
+
export declare const RUN_OUTCOME_VERSION = 3;
|
|
11
11
|
/**
|
|
12
12
|
* Where the run stands, in the terms the person reading the outcome cares about. Derived from
|
|
13
13
|
* the BLOCK's status first (it is what the merge lifecycle writes) and from the run only for
|
|
@@ -186,6 +186,99 @@ export declare const outcomeVisualsSchema: v.VariantSchema<"status", [v.ObjectSc
|
|
|
186
186
|
}, undefined>, undefined>;
|
|
187
187
|
}, undefined>], undefined>;
|
|
188
188
|
export type OutcomeVisuals = v.InferOutput<typeof outcomeVisualsSchema>;
|
|
189
|
+
/**
|
|
190
|
+
* Why there is no environment to open. Each names a different reaction, and the last two are the
|
|
191
|
+
* pair that matters: a pipeline that stands nothing up and one that was meant to and did not are
|
|
192
|
+
* opposite facts about whether anything is missing.
|
|
193
|
+
*/
|
|
194
|
+
export declare const environmentsGapSchema: v.PicklistSchema<["run_unavailable", "no_environment_step", "not_provisioned", "infraless"], undefined>;
|
|
195
|
+
export type EnvironmentsGap = v.InferOutput<typeof environmentsGapSchema>;
|
|
196
|
+
/**
|
|
197
|
+
* Where one environment stands, in the terms of the only question this section answers: is there
|
|
198
|
+
* something to click, and if not, why not.
|
|
199
|
+
*
|
|
200
|
+
* Six members rather than the recorded lifecycle status alone, because the run's own reclaim is
|
|
201
|
+
* part of the answer and the status projection cannot see it. `reclaimed` is deliberately the
|
|
202
|
+
* one word for BOTH "the run's disposer tore it down" and "the disposer went looking and found
|
|
203
|
+
* nothing live": who took it is not recorded anywhere this reduction can read, and the reader's
|
|
204
|
+
* next move (start another run) is the same either way. `reclaiming` is kept apart from it
|
|
205
|
+
* because a teardown that has been asked for is not one that happened.
|
|
206
|
+
*/
|
|
207
|
+
export declare const outcomeEnvironmentStateSchema: v.PicklistSchema<["live", "provisioning", "failed", "reclaiming", "reclaimed", "expired"], undefined>;
|
|
208
|
+
export type OutcomeEnvironmentState = v.InferOutput<typeof outcomeEnvironmentStateSchema>;
|
|
209
|
+
/**
|
|
210
|
+
* Which producer this row came from, so a consumer never reads one as another.
|
|
211
|
+
*
|
|
212
|
+
* `projected` is the in-flight row: the environment the run's steps are currently running
|
|
213
|
+
* against, read off the step projection because no terminal per-frame outcome exists yet. It is
|
|
214
|
+
* the weakest of the three and the only one that can still change, which is exactly why it is
|
|
215
|
+
* labelled rather than folded into `deployer`.
|
|
216
|
+
*/
|
|
217
|
+
export declare const outcomeEnvironmentOriginSchema: v.PicklistSchema<["deployer", "human_test", "projected"], undefined>;
|
|
218
|
+
export type OutcomeEnvironmentOrigin = v.InferOutput<typeof outcomeEnvironmentOriginSchema>;
|
|
219
|
+
/** One environment this run stood up: where it is, where it stands, and how long it lasts. */
|
|
220
|
+
export declare const outcomeEnvironmentSchema: v.ObjectSchema<{
|
|
221
|
+
/** The public URL, or null when there is not one to open (still provisioning, or it failed). */
|
|
222
|
+
readonly url: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
223
|
+
readonly state: v.PicklistSchema<["live", "provisioning", "failed", "reclaiming", "reclaimed", "expired"], undefined>;
|
|
224
|
+
readonly origin: v.PicklistSchema<["deployer", "human_test", "projected"], undefined>;
|
|
225
|
+
/**
|
|
226
|
+
* Epoch ms the environment's TTL lapses, when the platform recorded one.
|
|
227
|
+
*
|
|
228
|
+
* A lapsed TTL is NOT folded into `state`: this reduction is clock-free on purpose, so the SPA
|
|
229
|
+
* composing it live off its store and the endpoint composing it server-side cannot disagree
|
|
230
|
+
* about the same run. What a reader gets instead is the instant itself, which says the same
|
|
231
|
+
* thing without either surface having to guess whether the sweep has run yet.
|
|
232
|
+
*/
|
|
233
|
+
readonly expiresAt: v.NullableSchema<v.NumberSchema<undefined>, undefined>;
|
|
234
|
+
/**
|
|
235
|
+
* True when the run's deployer DECLARED that the environments it provisions outlive the run.
|
|
236
|
+
* It is what separates a preview URL a reviewer is meant to keep clicking from one that is
|
|
237
|
+
* still standing because the reclaim never happened.
|
|
238
|
+
*/
|
|
239
|
+
readonly retained: v.BooleanSchema<undefined>;
|
|
240
|
+
/** The service frame this environment was stood up for; null for a row no frame keys. */
|
|
241
|
+
readonly frameId: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
242
|
+
/** The environments-registry id, the handle an operator greps for. Null when not recorded. */
|
|
243
|
+
readonly environmentId: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
244
|
+
/** The producer's own verbatim cause, when it recorded one. Detail, never the headline. */
|
|
245
|
+
readonly detail: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
246
|
+
}, undefined>;
|
|
247
|
+
export type OutcomeEnvironment = v.InferOutput<typeof outcomeEnvironmentSchema>;
|
|
248
|
+
export declare const outcomeEnvironmentsSchema: v.VariantSchema<"status", [v.ObjectSchema<{
|
|
249
|
+
readonly status: v.LiteralSchema<"absent", undefined>;
|
|
250
|
+
readonly gap: v.PicklistSchema<["run_unavailable", "no_environment_step", "not_provisioned", "infraless"], undefined>;
|
|
251
|
+
}, undefined>, v.ObjectSchema<{
|
|
252
|
+
readonly status: v.LiteralSchema<"reported", undefined>;
|
|
253
|
+
readonly entries: v.ArraySchema<v.ObjectSchema<{
|
|
254
|
+
/** The public URL, or null when there is not one to open (still provisioning, or it failed). */
|
|
255
|
+
readonly url: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
256
|
+
readonly state: v.PicklistSchema<["live", "provisioning", "failed", "reclaiming", "reclaimed", "expired"], undefined>;
|
|
257
|
+
readonly origin: v.PicklistSchema<["deployer", "human_test", "projected"], undefined>;
|
|
258
|
+
/**
|
|
259
|
+
* Epoch ms the environment's TTL lapses, when the platform recorded one.
|
|
260
|
+
*
|
|
261
|
+
* A lapsed TTL is NOT folded into `state`: this reduction is clock-free on purpose, so the SPA
|
|
262
|
+
* composing it live off its store and the endpoint composing it server-side cannot disagree
|
|
263
|
+
* about the same run. What a reader gets instead is the instant itself, which says the same
|
|
264
|
+
* thing without either surface having to guess whether the sweep has run yet.
|
|
265
|
+
*/
|
|
266
|
+
readonly expiresAt: v.NullableSchema<v.NumberSchema<undefined>, undefined>;
|
|
267
|
+
/**
|
|
268
|
+
* True when the run's deployer DECLARED that the environments it provisions outlive the run.
|
|
269
|
+
* It is what separates a preview URL a reviewer is meant to keep clicking from one that is
|
|
270
|
+
* still standing because the reclaim never happened.
|
|
271
|
+
*/
|
|
272
|
+
readonly retained: v.BooleanSchema<undefined>;
|
|
273
|
+
/** The service frame this environment was stood up for; null for a row no frame keys. */
|
|
274
|
+
readonly frameId: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
275
|
+
/** The environments-registry id, the handle an operator greps for. Null when not recorded. */
|
|
276
|
+
readonly environmentId: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
277
|
+
/** The producer's own verbatim cause, when it recorded one. Detail, never the headline. */
|
|
278
|
+
readonly detail: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
279
|
+
}, undefined>, undefined>;
|
|
280
|
+
}, undefined>], undefined>;
|
|
281
|
+
export type OutcomeEnvironments = v.InferOutput<typeof outcomeEnvironmentsSchema>;
|
|
189
282
|
/** Why there is no linked source to show. */
|
|
190
283
|
export declare const sourcesGapSchema: v.PicklistSchema<["run_unavailable", "none_linked"], undefined>;
|
|
191
284
|
export type SourcesGap = v.InferOutput<typeof sourcesGapSchema>;
|
|
@@ -370,6 +463,43 @@ export declare const runOutcomeSchema: v.ObjectSchema<{
|
|
|
370
463
|
readonly referenceArtifactId: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
371
464
|
}, undefined>, undefined>;
|
|
372
465
|
}, undefined>], undefined>;
|
|
466
|
+
/**
|
|
467
|
+
* The throwaway environments the run stood up, so "click and look" is one step from the
|
|
468
|
+
* summary rather than buried in the step that provisioned it.
|
|
469
|
+
*/
|
|
470
|
+
readonly environments: v.VariantSchema<"status", [v.ObjectSchema<{
|
|
471
|
+
readonly status: v.LiteralSchema<"absent", undefined>;
|
|
472
|
+
readonly gap: v.PicklistSchema<["run_unavailable", "no_environment_step", "not_provisioned", "infraless"], undefined>;
|
|
473
|
+
}, undefined>, v.ObjectSchema<{
|
|
474
|
+
readonly status: v.LiteralSchema<"reported", undefined>;
|
|
475
|
+
readonly entries: v.ArraySchema<v.ObjectSchema<{
|
|
476
|
+
/** The public URL, or null when there is not one to open (still provisioning, or it failed). */
|
|
477
|
+
readonly url: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
478
|
+
readonly state: v.PicklistSchema<["live", "provisioning", "failed", "reclaiming", "reclaimed", "expired"], undefined>;
|
|
479
|
+
readonly origin: v.PicklistSchema<["deployer", "human_test", "projected"], undefined>;
|
|
480
|
+
/**
|
|
481
|
+
* Epoch ms the environment's TTL lapses, when the platform recorded one.
|
|
482
|
+
*
|
|
483
|
+
* A lapsed TTL is NOT folded into `state`: this reduction is clock-free on purpose, so the SPA
|
|
484
|
+
* composing it live off its store and the endpoint composing it server-side cannot disagree
|
|
485
|
+
* about the same run. What a reader gets instead is the instant itself, which says the same
|
|
486
|
+
* thing without either surface having to guess whether the sweep has run yet.
|
|
487
|
+
*/
|
|
488
|
+
readonly expiresAt: v.NullableSchema<v.NumberSchema<undefined>, undefined>;
|
|
489
|
+
/**
|
|
490
|
+
* True when the run's deployer DECLARED that the environments it provisions outlive the run.
|
|
491
|
+
* It is what separates a preview URL a reviewer is meant to keep clicking from one that is
|
|
492
|
+
* still standing because the reclaim never happened.
|
|
493
|
+
*/
|
|
494
|
+
readonly retained: v.BooleanSchema<undefined>;
|
|
495
|
+
/** The service frame this environment was stood up for; null for a row no frame keys. */
|
|
496
|
+
readonly frameId: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
497
|
+
/** The environments-registry id, the handle an operator greps for. Null when not recorded. */
|
|
498
|
+
readonly environmentId: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
499
|
+
/** The producer's own verbatim cause, when it recorded one. Detail, never the headline. */
|
|
500
|
+
readonly detail: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
501
|
+
}, undefined>, undefined>;
|
|
502
|
+
}, undefined>], undefined>;
|
|
373
503
|
/** The linked pages the run built from, and how current the copy its agents read was. */
|
|
374
504
|
readonly sources: v.VariantSchema<"status", [v.ObjectSchema<{
|
|
375
505
|
readonly status: v.LiteralSchema<"absent", undefined>;
|
|
@@ -461,7 +591,10 @@ export declare function composeRunOutcome({ block, instance, spec }: ComposeRunO
|
|
|
461
591
|
* notices would be the same empty card by another route.
|
|
462
592
|
*
|
|
463
593
|
* Linked SOURCES deliberately do not count. They say what the run was working FROM, not what it
|
|
464
|
-
* produced, so a run that has only read its brief has nothing for this card to answer yet.
|
|
594
|
+
* produced, so a run that has only read its brief has nothing for this card to answer yet. An
|
|
595
|
+
* ENVIRONMENT does count, and is the one thing here that can be worth opening before the run has
|
|
596
|
+
* produced anything else: a running preview of the change is exactly what the person who does
|
|
597
|
+
* not read diffs came for.
|
|
465
598
|
*/
|
|
466
599
|
export declare function hasOutcomeToShow(outcome: RunOutcome): boolean;
|
|
467
600
|
//# sourceMappingURL=run-outcome.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run-outcome.d.ts","sourceRoot":"","sources":["../src/run-outcome.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAC5B,OAAO,KAAK,EAAE,KAAK,EAAkB,MAAM,eAAe,CAAA;
|
|
1
|
+
{"version":3,"file":"run-outcome.d.ts","sourceRoot":"","sources":["../src/run-outcome.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAC5B,OAAO,KAAK,EAAE,KAAK,EAAkB,MAAM,eAAe,CAAA;AAG1D,OAAO,KAAK,EAGV,iBAAiB,EAElB,MAAM,gBAAgB,CAAA;AAsBvB,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,WAAW,CAAA;AA8ChD;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,IAAI,CAAA;AAEpC;;;;GAIG;AACH,eAAO,MAAM,wBAAwB,iHAYnC,CAAA;AACF,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,WAAW,CAAC,OAAO,wBAAwB,CAAC,CAAA;AAE/E,8FAA8F;AAC9F,eAAO,MAAM,wBAAwB;;;;IAInC,0EAA0E;;aAE1E,CAAA;AACF,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,WAAW,CAAC,OAAO,wBAAwB,CAAC,CAAA;AAI/E;;;;;;;;;GASG;AACH,eAAO,MAAM,iBAAiB,oBAAoB,CAAA;AAClD,MAAM,MAAM,iBAAiB,GAAG,OAAO,iBAAiB,CAAA;AAExD,qFAAqF;AACrF,eAAO,MAAM,qBAAqB,6HAahC,CAAA;AACF,MAAM,MAAM,eAAe,GAAG,CAAC,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