deepline 0.2.21 → 0.2.23
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/bundling-sources/sdk/src/client.ts +43 -0
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/shared_libs/play-runtime/app-runtime-api.ts +8 -0
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backend.ts +5 -0
- package/dist/bundling-sources/shared_libs/plays/authoring-contract.ts +2 -2
- package/dist/bundling-sources/shared_libs/security/safe-outbound-fetch.ts +42 -12
- package/dist/cli/index.js +73 -5
- package/dist/cli/index.mjs +73 -5
- package/dist/{compiler-manifest-xFkbJX2B.d.mts → compiler-manifest-CGZadg-v.d.mts} +2 -2
- package/dist/{compiler-manifest-xFkbJX2B.d.ts → compiler-manifest-CGZadg-v.d.ts} +2 -2
- package/dist/index.d.mts +40 -2
- package/dist/index.d.ts +40 -2
- package/dist/index.js +14 -1
- package/dist/index.mjs +14 -1
- package/dist/install-integrity.json +2 -2
- package/dist/plays/bundle-play-file.d.mts +2 -2
- package/dist/plays/bundle-play-file.d.ts +2 -2
- package/dist/plays/bundle-play-file.mjs +2 -2
- package/package.json +1 -1
|
@@ -607,6 +607,22 @@ export type PlaySecretMetadata = {
|
|
|
607
607
|
export type RunsNamespace = {
|
|
608
608
|
/** Get current run status by public run id. */
|
|
609
609
|
get: (runId: string, options?: RunsGetOptions) => Promise<PlayStatus>;
|
|
610
|
+
/** Explicitly read the retained original input (may include customer data). */
|
|
611
|
+
input: (runId: string) => Promise<{
|
|
612
|
+
runId: string;
|
|
613
|
+
input: Record<string, unknown> | unknown[];
|
|
614
|
+
bytes: number;
|
|
615
|
+
sha256: string | null;
|
|
616
|
+
replayedFromRunId: string | null;
|
|
617
|
+
}>;
|
|
618
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
619
|
+
rerun: (runId: string) => Promise<{
|
|
620
|
+
runId: string;
|
|
621
|
+
replayedFromRunId: string;
|
|
622
|
+
revisionId: string | null;
|
|
623
|
+
status: string;
|
|
624
|
+
next: { inspect: string; input: string };
|
|
625
|
+
}>;
|
|
610
626
|
/** List runs for one play, optionally filtered by status. */
|
|
611
627
|
list: (options: RunsListOptions) => Promise<PlayRunListItem[]>;
|
|
612
628
|
/** Stream run events and return the latest/terminal run status. */
|
|
@@ -1569,6 +1585,8 @@ export class DeeplineClient {
|
|
|
1569
1585
|
list: (options) => this.listRuns(options),
|
|
1570
1586
|
tail: (runId, options) => this.tailRun(runId, options),
|
|
1571
1587
|
logs: (runId, options) => this.getRunLogs(runId, options),
|
|
1588
|
+
input: (runId) => this.getRunInput(runId),
|
|
1589
|
+
rerun: (runId) => this.rerun(runId),
|
|
1572
1590
|
exportDatasetRows: (input) => this.getPlaySheetRows(input),
|
|
1573
1591
|
stop: (runId, options) => this.stopRun(runId, options),
|
|
1574
1592
|
stopAll: (options) => this.stopAllRuns(options),
|
|
@@ -3452,6 +3470,31 @@ export class DeeplineClient {
|
|
|
3452
3470
|
}
|
|
3453
3471
|
}
|
|
3454
3472
|
|
|
3473
|
+
/** Get the exact original input retained for a run. This is intentionally separate from status. */
|
|
3474
|
+
async getRunInput(runId: string): Promise<{
|
|
3475
|
+
runId: string;
|
|
3476
|
+
input: Record<string, unknown> | unknown[];
|
|
3477
|
+
bytes: number;
|
|
3478
|
+
sha256: string | null;
|
|
3479
|
+
replayedFromRunId: string | null;
|
|
3480
|
+
}> {
|
|
3481
|
+
return this.http.get(`/api/v2/runs/${encodeURIComponent(runId)}/input`);
|
|
3482
|
+
}
|
|
3483
|
+
|
|
3484
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
3485
|
+
async rerun(runId: string): Promise<{
|
|
3486
|
+
runId: string;
|
|
3487
|
+
replayedFromRunId: string;
|
|
3488
|
+
revisionId: string | null;
|
|
3489
|
+
status: string;
|
|
3490
|
+
next: { inspect: string; input: string };
|
|
3491
|
+
}> {
|
|
3492
|
+
return this.http.post(
|
|
3493
|
+
`/api/v2/runs/${encodeURIComponent(runId)}/rerun`,
|
|
3494
|
+
{},
|
|
3495
|
+
);
|
|
3496
|
+
}
|
|
3497
|
+
|
|
3455
3498
|
/**
|
|
3456
3499
|
* Fetch persisted logs for a run using the public runs resource model.
|
|
3457
3500
|
*
|
|
@@ -160,7 +160,7 @@ export const SDK_RELEASE = {
|
|
|
160
160
|
// 0.2.0 makes Dataset Handles uniformly async-only after 0.1.320 briefly
|
|
161
161
|
// exposed storage-dependent synchronous access. This deliberate minor
|
|
162
162
|
// release keeps lazy paging semantics independent of row residency.
|
|
163
|
-
version: '0.2.
|
|
163
|
+
version: '0.2.23',
|
|
164
164
|
contracts: {
|
|
165
165
|
api: {
|
|
166
166
|
name: 'sdk-http-api',
|
|
@@ -149,6 +149,10 @@ type RuntimeApiRequest =
|
|
|
149
149
|
maxCreditsPerRun?: number | null;
|
|
150
150
|
staticPipeline?: unknown;
|
|
151
151
|
source?: 'published' | 'ad_hoc' | 'draft';
|
|
152
|
+
inputFileId?: string;
|
|
153
|
+
inputBytes?: number;
|
|
154
|
+
inputSha256?: string;
|
|
155
|
+
replayedFromRunId?: string | null;
|
|
152
156
|
}
|
|
153
157
|
| ({
|
|
154
158
|
action: 'save_results';
|
|
@@ -1598,6 +1602,10 @@ export async function startRunViaAppRuntime(
|
|
|
1598
1602
|
maxCreditsPerRun?: number | null;
|
|
1599
1603
|
staticPipeline?: unknown;
|
|
1600
1604
|
source?: 'published' | 'ad_hoc' | 'draft';
|
|
1605
|
+
inputFileId?: string;
|
|
1606
|
+
inputBytes?: number;
|
|
1607
|
+
inputSha256?: string;
|
|
1608
|
+
replayedFromRunId?: string | null;
|
|
1601
1609
|
idempotencyKey?: string;
|
|
1602
1610
|
},
|
|
1603
1611
|
): Promise<void> {
|
|
@@ -49,6 +49,11 @@ export type PlaySchedulerSubmitInput = {
|
|
|
49
49
|
artifactHash: string;
|
|
50
50
|
graphHash: string;
|
|
51
51
|
input: PlayRunInputPayload;
|
|
52
|
+
/** Convex metadata for the exact input saved before scheduler submission. */
|
|
53
|
+
inputFileId?: string;
|
|
54
|
+
inputBytes?: number;
|
|
55
|
+
inputSha256?: string;
|
|
56
|
+
replayedFromRunId?: string | null;
|
|
52
57
|
/** Start a fresh run graph and recompute runtime-sheet rows. */
|
|
53
58
|
force?: boolean;
|
|
54
59
|
/** Explicit cache bypass for completed ctx.tools.execute receipts. */
|
|
@@ -1658,10 +1658,10 @@ export const PLAY_AUTHORING_FIELD_REGISTRY = {
|
|
|
1658
1658
|
},
|
|
1659
1659
|
referenceType: 'string',
|
|
1660
1660
|
required: true,
|
|
1661
|
-
resolution: '
|
|
1661
|
+
resolution: 'runtime-dynamic',
|
|
1662
1662
|
issueCode: 'play_authoring_run_play_option_invalid',
|
|
1663
1663
|
description: 'Stable identity for one inline child Play call.',
|
|
1664
|
-
errorMessage: 'ctx.runPlay key must be a non-empty
|
|
1664
|
+
errorMessage: 'ctx.runPlay key must be a non-empty string.',
|
|
1665
1665
|
},
|
|
1666
1666
|
'ctx.runPlay.playRef': {
|
|
1667
1667
|
schema: Type.Union([
|
|
@@ -14,6 +14,7 @@ import {
|
|
|
14
14
|
type NodeSafeFetchOptions = {
|
|
15
15
|
maxRedirects?: number;
|
|
16
16
|
maxResponseBytes?: number;
|
|
17
|
+
truncateResponseBody?: boolean;
|
|
17
18
|
sensitiveHeaders?: Iterable<string>;
|
|
18
19
|
validateUrl?: (url: URL) => void;
|
|
19
20
|
};
|
|
@@ -187,6 +188,7 @@ function createRequest(
|
|
|
187
188
|
init: RequestInit,
|
|
188
189
|
prepared: PreparedBody,
|
|
189
190
|
maxResponseBytes: number | undefined,
|
|
191
|
+
truncateResponseBody: boolean,
|
|
190
192
|
): Promise<Response> {
|
|
191
193
|
return new Promise((resolve, reject) => {
|
|
192
194
|
const transport = url.protocol === 'https:' ? https : http;
|
|
@@ -208,7 +210,8 @@ function createRequest(
|
|
|
208
210
|
!noBodyResponse &&
|
|
209
211
|
maxResponseBytes !== undefined &&
|
|
210
212
|
Number.isFinite(contentLength) &&
|
|
211
|
-
contentLength > maxResponseBytes
|
|
213
|
+
contentLength > maxResponseBytes &&
|
|
214
|
+
!truncateResponseBody
|
|
212
215
|
) {
|
|
213
216
|
response.resume();
|
|
214
217
|
reject(
|
|
@@ -219,12 +222,27 @@ function createRequest(
|
|
|
219
222
|
|
|
220
223
|
const chunks: Buffer[] = [];
|
|
221
224
|
let receivedBytes = 0;
|
|
225
|
+
let settled = false;
|
|
226
|
+
const resolveResponse = () => {
|
|
227
|
+
if (settled) return;
|
|
228
|
+
settled = true;
|
|
229
|
+
resolve(
|
|
230
|
+
new Response(noBodyResponse ? null : Buffer.concat(chunks), {
|
|
231
|
+
status,
|
|
232
|
+
statusText: response.statusMessage,
|
|
233
|
+
headers: response.headers as HeadersInit,
|
|
234
|
+
}),
|
|
235
|
+
);
|
|
236
|
+
};
|
|
222
237
|
response.on('data', (chunk) => {
|
|
238
|
+
if (settled) return;
|
|
223
239
|
const buffer = Buffer.isBuffer(chunk) ? chunk : Buffer.from(chunk);
|
|
240
|
+
const previousReceivedBytes = receivedBytes;
|
|
224
241
|
receivedBytes += buffer.byteLength;
|
|
225
242
|
if (
|
|
226
243
|
maxResponseBytes !== undefined &&
|
|
227
|
-
receivedBytes > maxResponseBytes
|
|
244
|
+
receivedBytes > maxResponseBytes &&
|
|
245
|
+
!truncateResponseBody
|
|
228
246
|
) {
|
|
229
247
|
response.destroy(
|
|
230
248
|
new Error(
|
|
@@ -234,19 +252,29 @@ function createRequest(
|
|
|
234
252
|
return;
|
|
235
253
|
}
|
|
236
254
|
if (!noBodyResponse) {
|
|
237
|
-
|
|
255
|
+
if (maxResponseBytes !== undefined && truncateResponseBody) {
|
|
256
|
+
const remainingBytes = Math.max(
|
|
257
|
+
0,
|
|
258
|
+
maxResponseBytes - previousReceivedBytes,
|
|
259
|
+
);
|
|
260
|
+
if (remainingBytes > 0) {
|
|
261
|
+
chunks.push(buffer.subarray(0, remainingBytes));
|
|
262
|
+
}
|
|
263
|
+
if (receivedBytes >= maxResponseBytes) {
|
|
264
|
+
resolveResponse();
|
|
265
|
+
response.destroy();
|
|
266
|
+
}
|
|
267
|
+
} else {
|
|
268
|
+
chunks.push(buffer);
|
|
269
|
+
}
|
|
238
270
|
}
|
|
239
271
|
});
|
|
240
|
-
response.on('error',
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
status,
|
|
245
|
-
statusText: response.statusMessage,
|
|
246
|
-
headers: response.headers as HeadersInit,
|
|
247
|
-
}),
|
|
248
|
-
);
|
|
272
|
+
response.on('error', (error) => {
|
|
273
|
+
if (settled) return;
|
|
274
|
+
settled = true;
|
|
275
|
+
reject(error);
|
|
249
276
|
});
|
|
277
|
+
response.on('end', resolveResponse);
|
|
250
278
|
},
|
|
251
279
|
);
|
|
252
280
|
|
|
@@ -299,6 +327,7 @@ export async function safeOutboundFetch(
|
|
|
299
327
|
const redirectMode = init.redirect ?? 'follow';
|
|
300
328
|
const maxRedirects = options.maxRedirects ?? 10;
|
|
301
329
|
const maxResponseBytes = options.maxResponseBytes;
|
|
330
|
+
const truncateResponseBody = options.truncateResponseBody === true;
|
|
302
331
|
const validateUrl = options.validateUrl;
|
|
303
332
|
let currentUrl = assertPublicHttpUrl(input);
|
|
304
333
|
let currentInit: RequestInit = { ...init, redirect: 'manual' };
|
|
@@ -321,6 +350,7 @@ export async function safeOutboundFetch(
|
|
|
321
350
|
currentInit,
|
|
322
351
|
await prepareBody(currentInit),
|
|
323
352
|
maxResponseBytes,
|
|
353
|
+
truncateResponseBody,
|
|
324
354
|
);
|
|
325
355
|
|
|
326
356
|
Object.defineProperty(response, 'url', {
|
package/dist/cli/index.js
CHANGED
|
@@ -1044,7 +1044,7 @@ var SDK_RELEASE = {
|
|
|
1044
1044
|
// 0.2.0 makes Dataset Handles uniformly async-only after 0.1.320 briefly
|
|
1045
1045
|
// exposed storage-dependent synchronous access. This deliberate minor
|
|
1046
1046
|
// release keeps lazy paging semantics independent of row residency.
|
|
1047
|
-
version: "0.2.
|
|
1047
|
+
version: "0.2.23",
|
|
1048
1048
|
contracts: {
|
|
1049
1049
|
api: {
|
|
1050
1050
|
name: "sdk-http-api",
|
|
@@ -3775,6 +3775,8 @@ var DeeplineClient = class {
|
|
|
3775
3775
|
list: (options2) => this.listRuns(options2),
|
|
3776
3776
|
tail: (runId, options2) => this.tailRun(runId, options2),
|
|
3777
3777
|
logs: (runId, options2) => this.getRunLogs(runId, options2),
|
|
3778
|
+
input: (runId) => this.getRunInput(runId),
|
|
3779
|
+
rerun: (runId) => this.rerun(runId),
|
|
3778
3780
|
exportDatasetRows: (input2) => this.getPlaySheetRows(input2),
|
|
3779
3781
|
stop: (runId, options2) => this.stopRun(runId, options2),
|
|
3780
3782
|
stopAll: (options2) => this.stopAllRuns(options2)
|
|
@@ -5179,6 +5181,17 @@ var DeeplineClient = class {
|
|
|
5179
5181
|
await sleep2(delayMs);
|
|
5180
5182
|
}
|
|
5181
5183
|
}
|
|
5184
|
+
/** Get the exact original input retained for a run. This is intentionally separate from status. */
|
|
5185
|
+
async getRunInput(runId) {
|
|
5186
|
+
return this.http.get(`/api/v2/runs/${encodeURIComponent(runId)}/input`);
|
|
5187
|
+
}
|
|
5188
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
5189
|
+
async rerun(runId) {
|
|
5190
|
+
return this.http.post(
|
|
5191
|
+
`/api/v2/runs/${encodeURIComponent(runId)}/rerun`,
|
|
5192
|
+
{}
|
|
5193
|
+
);
|
|
5194
|
+
}
|
|
5182
5195
|
/**
|
|
5183
5196
|
* Fetch persisted logs for a run using the public runs resource model.
|
|
5184
5197
|
*
|
|
@@ -15496,10 +15509,10 @@ var PLAY_AUTHORING_FIELD_REGISTRY = {
|
|
|
15496
15509
|
},
|
|
15497
15510
|
referenceType: "string",
|
|
15498
15511
|
required: true,
|
|
15499
|
-
resolution: "
|
|
15512
|
+
resolution: "runtime-dynamic",
|
|
15500
15513
|
issueCode: "play_authoring_run_play_option_invalid",
|
|
15501
15514
|
description: "Stable identity for one inline child Play call.",
|
|
15502
|
-
errorMessage: "ctx.runPlay key must be a non-empty
|
|
15515
|
+
errorMessage: "ctx.runPlay key must be a non-empty string."
|
|
15503
15516
|
},
|
|
15504
15517
|
"ctx.runPlay.playRef": {
|
|
15505
15518
|
schema: Type.Union([
|
|
@@ -21842,7 +21855,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
21842
21855
|
function parseRunIdPositional(args, usage) {
|
|
21843
21856
|
for (let index = 0; index < args.length; index += 1) {
|
|
21844
21857
|
const arg = args[index];
|
|
21845
|
-
if (arg === "--json" || arg === "--full" || arg === "--logs" || arg === "--compact" || arg === "--log-failed" || arg === "--failed" || arg === "--limit") {
|
|
21858
|
+
if (arg === "--json" || arg === "--full" || arg === "--input" || arg === "--logs" || arg === "--compact" || arg === "--log-failed" || arg === "--failed" || arg === "--limit") {
|
|
21846
21859
|
if (arg === "--limit" && args[index + 1]) {
|
|
21847
21860
|
index += 1;
|
|
21848
21861
|
}
|
|
@@ -21859,7 +21872,7 @@ function parseRunIdPositional(args, usage) {
|
|
|
21859
21872
|
throw new DeeplineError(usage);
|
|
21860
21873
|
}
|
|
21861
21874
|
async function handleRunGet(args) {
|
|
21862
|
-
const usage = "Usage: deepline runs get <run-id> [--json] [--full] [--log-failed]";
|
|
21875
|
+
const usage = "Usage: deepline runs get <run-id> [--json] [--full] [--input] [--log-failed]";
|
|
21863
21876
|
let runId;
|
|
21864
21877
|
try {
|
|
21865
21878
|
runId = parseRunIdPositional(args, usage);
|
|
@@ -21868,6 +21881,11 @@ async function handleRunGet(args) {
|
|
|
21868
21881
|
return 1;
|
|
21869
21882
|
}
|
|
21870
21883
|
const client2 = new DeeplineClient();
|
|
21884
|
+
if (args.includes("--input")) {
|
|
21885
|
+
const input2 = await client2.getRunInput(runId);
|
|
21886
|
+
printCommandEnvelope(input2, { json: true });
|
|
21887
|
+
return 0;
|
|
21888
|
+
}
|
|
21871
21889
|
const status = await client2.runs.get(runId, {
|
|
21872
21890
|
full: args.includes("--full"),
|
|
21873
21891
|
failedLogs: args.includes("--log-failed")
|
|
@@ -21877,6 +21895,29 @@ async function handleRunGet(args) {
|
|
|
21877
21895
|
});
|
|
21878
21896
|
return 0;
|
|
21879
21897
|
}
|
|
21898
|
+
async function handleRunsRerun(args) {
|
|
21899
|
+
const usage = "Usage: deepline runs rerun <run-id> [--json]";
|
|
21900
|
+
let runId;
|
|
21901
|
+
try {
|
|
21902
|
+
runId = parseRunIdPositional(args, usage);
|
|
21903
|
+
} catch (error) {
|
|
21904
|
+
console.error(error instanceof Error ? error.message : usage);
|
|
21905
|
+
return 1;
|
|
21906
|
+
}
|
|
21907
|
+
const result = await new DeeplineClient().runs.rerun(runId);
|
|
21908
|
+
if (argsWantJson(args)) {
|
|
21909
|
+
printCommandEnvelope(result, { json: true });
|
|
21910
|
+
} else {
|
|
21911
|
+
console.log(`
|
|
21912
|
+
Rerun started from ${runId}.`);
|
|
21913
|
+
console.log(` inspect: deepline runs get ${result.runId} --json`);
|
|
21914
|
+
console.log(` original input: deepline runs get ${result.runId} --input`);
|
|
21915
|
+
console.log(
|
|
21916
|
+
" This is a fresh run using the original input and pinned revision. Normal tool receipt reuse still applies."
|
|
21917
|
+
);
|
|
21918
|
+
}
|
|
21919
|
+
return 0;
|
|
21920
|
+
}
|
|
21880
21921
|
async function handleRunsList(args) {
|
|
21881
21922
|
const usage = "Usage: deepline runs list [--play <play-name>] [--status <status>] [--limit <count>] [--offset <count>] [--json]";
|
|
21882
21923
|
let playName = null;
|
|
@@ -23455,14 +23496,20 @@ Examples:
|
|
|
23455
23496
|
`
|
|
23456
23497
|
Notes:
|
|
23457
23498
|
Full run status read. Use --full --json when debugging raw stream/status fields.
|
|
23499
|
+
Use --input only when you intentionally need the original payload; it can
|
|
23500
|
+
contain customer data and is never included in ordinary status output.
|
|
23458
23501
|
|
|
23459
23502
|
Examples:
|
|
23460
23503
|
deepline runs get play/my-play/run/20260501t000000-000
|
|
23461
23504
|
deepline runs get play/my-play/run/20260501t000000-000 --json
|
|
23462
23505
|
deepline runs get play/my-play/run/20260501t000000-000 --log-failed --json
|
|
23463
23506
|
deepline runs get play/my-play/run/20260501t000000-000 --full --json
|
|
23507
|
+
deepline runs get play/my-play/run/20260501t000000-000 --input
|
|
23464
23508
|
`
|
|
23465
23509
|
).option("--json", "Emit JSON output. Also automatic when stdout is piped").option("--full", "Debug only: with --json, emit the raw status payload").option(
|
|
23510
|
+
"--input",
|
|
23511
|
+
"Explicitly print the original retained input JSON (may contain customer data)"
|
|
23512
|
+
).option(
|
|
23466
23513
|
"--log-failed",
|
|
23467
23514
|
"Attach a bounded terminal-failure log window for failed runs"
|
|
23468
23515
|
).action(async (runId, options) => {
|
|
@@ -23470,9 +23517,30 @@ Examples:
|
|
|
23470
23517
|
runId,
|
|
23471
23518
|
...options.json ? ["--json"] : [],
|
|
23472
23519
|
...options.full ? ["--full"] : [],
|
|
23520
|
+
...options.input ? ["--input"] : [],
|
|
23473
23521
|
...options.logFailed ? ["--log-failed"] : []
|
|
23474
23522
|
]);
|
|
23475
23523
|
});
|
|
23524
|
+
runs.command("rerun <runId>").description(
|
|
23525
|
+
"Start a fresh run from a prior run's retained input and pinned revision."
|
|
23526
|
+
).addHelpText(
|
|
23527
|
+
"after",
|
|
23528
|
+
`
|
|
23529
|
+
Notes:
|
|
23530
|
+
Creates a new run. It never mutates the original run.
|
|
23531
|
+
The rerun uses the original input and exact saved revision. Normal completed
|
|
23532
|
+
tool receipts may be reused; inspect the new run before forcing any external
|
|
23533
|
+
side effect.
|
|
23534
|
+
|
|
23535
|
+
Examples:
|
|
23536
|
+
deepline runs rerun play/my-play/webhook/abc --json
|
|
23537
|
+
`
|
|
23538
|
+
).option("--json", "Emit JSON output. Also automatic when stdout is piped").action(async (runId, options) => {
|
|
23539
|
+
process.exitCode = await handleRunsRerun([
|
|
23540
|
+
runId,
|
|
23541
|
+
...options.json ? ["--json"] : []
|
|
23542
|
+
]);
|
|
23543
|
+
});
|
|
23476
23544
|
runs.command("list").description("List play runs.").addHelpText(
|
|
23477
23545
|
"after",
|
|
23478
23546
|
`
|
package/dist/cli/index.mjs
CHANGED
|
@@ -1030,7 +1030,7 @@ var SDK_RELEASE = {
|
|
|
1030
1030
|
// 0.2.0 makes Dataset Handles uniformly async-only after 0.1.320 briefly
|
|
1031
1031
|
// exposed storage-dependent synchronous access. This deliberate minor
|
|
1032
1032
|
// release keeps lazy paging semantics independent of row residency.
|
|
1033
|
-
version: "0.2.
|
|
1033
|
+
version: "0.2.23",
|
|
1034
1034
|
contracts: {
|
|
1035
1035
|
api: {
|
|
1036
1036
|
name: "sdk-http-api",
|
|
@@ -3761,6 +3761,8 @@ var DeeplineClient = class {
|
|
|
3761
3761
|
list: (options2) => this.listRuns(options2),
|
|
3762
3762
|
tail: (runId, options2) => this.tailRun(runId, options2),
|
|
3763
3763
|
logs: (runId, options2) => this.getRunLogs(runId, options2),
|
|
3764
|
+
input: (runId) => this.getRunInput(runId),
|
|
3765
|
+
rerun: (runId) => this.rerun(runId),
|
|
3764
3766
|
exportDatasetRows: (input2) => this.getPlaySheetRows(input2),
|
|
3765
3767
|
stop: (runId, options2) => this.stopRun(runId, options2),
|
|
3766
3768
|
stopAll: (options2) => this.stopAllRuns(options2)
|
|
@@ -5165,6 +5167,17 @@ var DeeplineClient = class {
|
|
|
5165
5167
|
await sleep2(delayMs);
|
|
5166
5168
|
}
|
|
5167
5169
|
}
|
|
5170
|
+
/** Get the exact original input retained for a run. This is intentionally separate from status. */
|
|
5171
|
+
async getRunInput(runId) {
|
|
5172
|
+
return this.http.get(`/api/v2/runs/${encodeURIComponent(runId)}/input`);
|
|
5173
|
+
}
|
|
5174
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
5175
|
+
async rerun(runId) {
|
|
5176
|
+
return this.http.post(
|
|
5177
|
+
`/api/v2/runs/${encodeURIComponent(runId)}/rerun`,
|
|
5178
|
+
{}
|
|
5179
|
+
);
|
|
5180
|
+
}
|
|
5168
5181
|
/**
|
|
5169
5182
|
* Fetch persisted logs for a run using the public runs resource model.
|
|
5170
5183
|
*
|
|
@@ -15533,10 +15546,10 @@ var PLAY_AUTHORING_FIELD_REGISTRY = {
|
|
|
15533
15546
|
},
|
|
15534
15547
|
referenceType: "string",
|
|
15535
15548
|
required: true,
|
|
15536
|
-
resolution: "
|
|
15549
|
+
resolution: "runtime-dynamic",
|
|
15537
15550
|
issueCode: "play_authoring_run_play_option_invalid",
|
|
15538
15551
|
description: "Stable identity for one inline child Play call.",
|
|
15539
|
-
errorMessage: "ctx.runPlay key must be a non-empty
|
|
15552
|
+
errorMessage: "ctx.runPlay key must be a non-empty string."
|
|
15540
15553
|
},
|
|
15541
15554
|
"ctx.runPlay.playRef": {
|
|
15542
15555
|
schema: Type.Union([
|
|
@@ -21886,7 +21899,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
21886
21899
|
function parseRunIdPositional(args, usage) {
|
|
21887
21900
|
for (let index = 0; index < args.length; index += 1) {
|
|
21888
21901
|
const arg = args[index];
|
|
21889
|
-
if (arg === "--json" || arg === "--full" || arg === "--logs" || arg === "--compact" || arg === "--log-failed" || arg === "--failed" || arg === "--limit") {
|
|
21902
|
+
if (arg === "--json" || arg === "--full" || arg === "--input" || arg === "--logs" || arg === "--compact" || arg === "--log-failed" || arg === "--failed" || arg === "--limit") {
|
|
21890
21903
|
if (arg === "--limit" && args[index + 1]) {
|
|
21891
21904
|
index += 1;
|
|
21892
21905
|
}
|
|
@@ -21903,7 +21916,7 @@ function parseRunIdPositional(args, usage) {
|
|
|
21903
21916
|
throw new DeeplineError(usage);
|
|
21904
21917
|
}
|
|
21905
21918
|
async function handleRunGet(args) {
|
|
21906
|
-
const usage = "Usage: deepline runs get <run-id> [--json] [--full] [--log-failed]";
|
|
21919
|
+
const usage = "Usage: deepline runs get <run-id> [--json] [--full] [--input] [--log-failed]";
|
|
21907
21920
|
let runId;
|
|
21908
21921
|
try {
|
|
21909
21922
|
runId = parseRunIdPositional(args, usage);
|
|
@@ -21912,6 +21925,11 @@ async function handleRunGet(args) {
|
|
|
21912
21925
|
return 1;
|
|
21913
21926
|
}
|
|
21914
21927
|
const client2 = new DeeplineClient();
|
|
21928
|
+
if (args.includes("--input")) {
|
|
21929
|
+
const input2 = await client2.getRunInput(runId);
|
|
21930
|
+
printCommandEnvelope(input2, { json: true });
|
|
21931
|
+
return 0;
|
|
21932
|
+
}
|
|
21915
21933
|
const status = await client2.runs.get(runId, {
|
|
21916
21934
|
full: args.includes("--full"),
|
|
21917
21935
|
failedLogs: args.includes("--log-failed")
|
|
@@ -21921,6 +21939,29 @@ async function handleRunGet(args) {
|
|
|
21921
21939
|
});
|
|
21922
21940
|
return 0;
|
|
21923
21941
|
}
|
|
21942
|
+
async function handleRunsRerun(args) {
|
|
21943
|
+
const usage = "Usage: deepline runs rerun <run-id> [--json]";
|
|
21944
|
+
let runId;
|
|
21945
|
+
try {
|
|
21946
|
+
runId = parseRunIdPositional(args, usage);
|
|
21947
|
+
} catch (error) {
|
|
21948
|
+
console.error(error instanceof Error ? error.message : usage);
|
|
21949
|
+
return 1;
|
|
21950
|
+
}
|
|
21951
|
+
const result = await new DeeplineClient().runs.rerun(runId);
|
|
21952
|
+
if (argsWantJson(args)) {
|
|
21953
|
+
printCommandEnvelope(result, { json: true });
|
|
21954
|
+
} else {
|
|
21955
|
+
console.log(`
|
|
21956
|
+
Rerun started from ${runId}.`);
|
|
21957
|
+
console.log(` inspect: deepline runs get ${result.runId} --json`);
|
|
21958
|
+
console.log(` original input: deepline runs get ${result.runId} --input`);
|
|
21959
|
+
console.log(
|
|
21960
|
+
" This is a fresh run using the original input and pinned revision. Normal tool receipt reuse still applies."
|
|
21961
|
+
);
|
|
21962
|
+
}
|
|
21963
|
+
return 0;
|
|
21964
|
+
}
|
|
21924
21965
|
async function handleRunsList(args) {
|
|
21925
21966
|
const usage = "Usage: deepline runs list [--play <play-name>] [--status <status>] [--limit <count>] [--offset <count>] [--json]";
|
|
21926
21967
|
let playName = null;
|
|
@@ -23499,14 +23540,20 @@ Examples:
|
|
|
23499
23540
|
`
|
|
23500
23541
|
Notes:
|
|
23501
23542
|
Full run status read. Use --full --json when debugging raw stream/status fields.
|
|
23543
|
+
Use --input only when you intentionally need the original payload; it can
|
|
23544
|
+
contain customer data and is never included in ordinary status output.
|
|
23502
23545
|
|
|
23503
23546
|
Examples:
|
|
23504
23547
|
deepline runs get play/my-play/run/20260501t000000-000
|
|
23505
23548
|
deepline runs get play/my-play/run/20260501t000000-000 --json
|
|
23506
23549
|
deepline runs get play/my-play/run/20260501t000000-000 --log-failed --json
|
|
23507
23550
|
deepline runs get play/my-play/run/20260501t000000-000 --full --json
|
|
23551
|
+
deepline runs get play/my-play/run/20260501t000000-000 --input
|
|
23508
23552
|
`
|
|
23509
23553
|
).option("--json", "Emit JSON output. Also automatic when stdout is piped").option("--full", "Debug only: with --json, emit the raw status payload").option(
|
|
23554
|
+
"--input",
|
|
23555
|
+
"Explicitly print the original retained input JSON (may contain customer data)"
|
|
23556
|
+
).option(
|
|
23510
23557
|
"--log-failed",
|
|
23511
23558
|
"Attach a bounded terminal-failure log window for failed runs"
|
|
23512
23559
|
).action(async (runId, options) => {
|
|
@@ -23514,9 +23561,30 @@ Examples:
|
|
|
23514
23561
|
runId,
|
|
23515
23562
|
...options.json ? ["--json"] : [],
|
|
23516
23563
|
...options.full ? ["--full"] : [],
|
|
23564
|
+
...options.input ? ["--input"] : [],
|
|
23517
23565
|
...options.logFailed ? ["--log-failed"] : []
|
|
23518
23566
|
]);
|
|
23519
23567
|
});
|
|
23568
|
+
runs.command("rerun <runId>").description(
|
|
23569
|
+
"Start a fresh run from a prior run's retained input and pinned revision."
|
|
23570
|
+
).addHelpText(
|
|
23571
|
+
"after",
|
|
23572
|
+
`
|
|
23573
|
+
Notes:
|
|
23574
|
+
Creates a new run. It never mutates the original run.
|
|
23575
|
+
The rerun uses the original input and exact saved revision. Normal completed
|
|
23576
|
+
tool receipts may be reused; inspect the new run before forcing any external
|
|
23577
|
+
side effect.
|
|
23578
|
+
|
|
23579
|
+
Examples:
|
|
23580
|
+
deepline runs rerun play/my-play/webhook/abc --json
|
|
23581
|
+
`
|
|
23582
|
+
).option("--json", "Emit JSON output. Also automatic when stdout is piped").action(async (runId, options) => {
|
|
23583
|
+
process.exitCode = await handleRunsRerun([
|
|
23584
|
+
runId,
|
|
23585
|
+
...options.json ? ["--json"] : []
|
|
23586
|
+
]);
|
|
23587
|
+
});
|
|
23520
23588
|
runs.command("list").description("List play runs.").addHelpText(
|
|
23521
23589
|
"after",
|
|
23522
23590
|
`
|
|
@@ -2109,10 +2109,10 @@ declare const PLAY_AUTHORING_FIELD_REGISTRY: {
|
|
|
2109
2109
|
};
|
|
2110
2110
|
readonly referenceType: "string";
|
|
2111
2111
|
readonly required: true;
|
|
2112
|
-
readonly resolution: "
|
|
2112
|
+
readonly resolution: "runtime-dynamic";
|
|
2113
2113
|
readonly issueCode: "play_authoring_run_play_option_invalid";
|
|
2114
2114
|
readonly description: "Stable identity for one inline child Play call.";
|
|
2115
|
-
readonly errorMessage: "ctx.runPlay key must be a non-empty
|
|
2115
|
+
readonly errorMessage: "ctx.runPlay key must be a non-empty string.";
|
|
2116
2116
|
};
|
|
2117
2117
|
readonly 'ctx.runPlay.playRef': {
|
|
2118
2118
|
readonly schema: _sinclair_typebox.TUnion<[_sinclair_typebox.TString, _sinclair_typebox.TUnion<[_sinclair_typebox.TObject<{
|
|
@@ -2109,10 +2109,10 @@ declare const PLAY_AUTHORING_FIELD_REGISTRY: {
|
|
|
2109
2109
|
};
|
|
2110
2110
|
readonly referenceType: "string";
|
|
2111
2111
|
readonly required: true;
|
|
2112
|
-
readonly resolution: "
|
|
2112
|
+
readonly resolution: "runtime-dynamic";
|
|
2113
2113
|
readonly issueCode: "play_authoring_run_play_option_invalid";
|
|
2114
2114
|
readonly description: "Stable identity for one inline child Play call.";
|
|
2115
|
-
readonly errorMessage: "ctx.runPlay key must be a non-empty
|
|
2115
|
+
readonly errorMessage: "ctx.runPlay key must be a non-empty string.";
|
|
2116
2116
|
};
|
|
2117
2117
|
readonly 'ctx.runPlay.playRef': {
|
|
2118
2118
|
readonly schema: _sinclair_typebox.TUnion<[_sinclair_typebox.TString, _sinclair_typebox.TUnion<[_sinclair_typebox.TObject<{
|
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { e as PlayRuntimeBackendId, c as PlayCompilerManifest, D as DeeplineError, f as ToolExecutionError, g as ToolExecutionErrorOptions, h as PlayAuthoringColumnMap, i as PlayAuthoringColumnResolver, j as PlayAuthoringRuntimeContext, k as PlayAuthoringConditionalStepResolver, l as PlayAuthoringCsvInput, m as PlayAuthoringCsvOptions, n as PlayAuthoringDatasetBuilder, o as PlayAuthoringDatasetColumnDefinition, p as PlayAuthoringDatasetColumnRunInput, q as ToolExecuteResult, r as PlayAuthoringReferenceLike, s as PlayReturnObject$1, t as PlayAuthoringDefineConfig, u as PlayAuthoringDefinedPlay, v as PlayAuthoringFetchOptions, w as PlayAuthoringFileInput, x as PlayAuthoringBindings, y as PlayAuthoringCallExecution, z as PlayAuthoringCallOptions, A as PlayAuthoringFetchResponse, B as PlayAuthoringInputContract, C as PlayAuthoringStepProgramStep, E as PlayAuthoringRuntimeStepOptions, F as PlaySqlListenerDeclaration, G as PlaySqlListenerEvent, H as PlaySqlListenerOperation, I as PlaySqlQuery, J as PlayAuthoringStepOptions, K as PlayAuthoringStepProgram, L as PlayAuthoringStepProgramResolver, M as PlayAuthoringStepResolver, N as PlayToolExecutionRequest } from './compiler-manifest-
|
|
2
|
-
export { O as DEEPLINE_EXTRACTOR_TARGETS, Q as DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS, R as DeeplineEmailStatusGetterValue, S as DeeplineExtractorTarget, U as DeeplineGetterValue, V as DeeplineGetterValueMap, W as JOB_CHANGE_STATUS_VALUES, X as JobChangeStatus, Y as PHONE_STATUS_VALUES, Z as PhoneStatus, _ as PlayDataset, $ as PlayDatasetInput, a0 as PreviousCell, a1 as ProviderTransientError, a2 as ProviderTransientErrorCategory, a3 as ToolExecutionErrorCategory, a4 as ToolExecutionErrorOrigin, a5 as ToolExecutionFailureV1, a6 as ToolExecutionNetworkKind, a7 as ToolExecutionNetworkScope, a8 as isDeeplineExtractorTarget } from './compiler-manifest-
|
|
1
|
+
import { e as PlayRuntimeBackendId, c as PlayCompilerManifest, D as DeeplineError, f as ToolExecutionError, g as ToolExecutionErrorOptions, h as PlayAuthoringColumnMap, i as PlayAuthoringColumnResolver, j as PlayAuthoringRuntimeContext, k as PlayAuthoringConditionalStepResolver, l as PlayAuthoringCsvInput, m as PlayAuthoringCsvOptions, n as PlayAuthoringDatasetBuilder, o as PlayAuthoringDatasetColumnDefinition, p as PlayAuthoringDatasetColumnRunInput, q as ToolExecuteResult, r as PlayAuthoringReferenceLike, s as PlayReturnObject$1, t as PlayAuthoringDefineConfig, u as PlayAuthoringDefinedPlay, v as PlayAuthoringFetchOptions, w as PlayAuthoringFileInput, x as PlayAuthoringBindings, y as PlayAuthoringCallExecution, z as PlayAuthoringCallOptions, A as PlayAuthoringFetchResponse, B as PlayAuthoringInputContract, C as PlayAuthoringStepProgramStep, E as PlayAuthoringRuntimeStepOptions, F as PlaySqlListenerDeclaration, G as PlaySqlListenerEvent, H as PlaySqlListenerOperation, I as PlaySqlQuery, J as PlayAuthoringStepOptions, K as PlayAuthoringStepProgram, L as PlayAuthoringStepProgramResolver, M as PlayAuthoringStepResolver, N as PlayToolExecutionRequest } from './compiler-manifest-CGZadg-v.mjs';
|
|
2
|
+
export { O as DEEPLINE_EXTRACTOR_TARGETS, Q as DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS, R as DeeplineEmailStatusGetterValue, S as DeeplineExtractorTarget, U as DeeplineGetterValue, V as DeeplineGetterValueMap, W as JOB_CHANGE_STATUS_VALUES, X as JobChangeStatus, Y as PHONE_STATUS_VALUES, Z as PhoneStatus, _ as PlayDataset, $ as PlayDatasetInput, a0 as PreviousCell, a1 as ProviderTransientError, a2 as ProviderTransientErrorCategory, a3 as ToolExecutionErrorCategory, a4 as ToolExecutionErrorOrigin, a5 as ToolExecutionFailureV1, a6 as ToolExecutionNetworkKind, a7 as ToolExecutionNetworkScope, a8 as isDeeplineExtractorTarget } from './compiler-manifest-CGZadg-v.mjs';
|
|
3
3
|
import '@sinclair/typebox';
|
|
4
4
|
|
|
5
5
|
type PlayRuntimeSelection = {
|
|
@@ -1898,6 +1898,25 @@ type PlaySecretMetadata = {
|
|
|
1898
1898
|
type RunsNamespace = {
|
|
1899
1899
|
/** Get current run status by public run id. */
|
|
1900
1900
|
get: (runId: string, options?: RunsGetOptions) => Promise<PlayStatus>;
|
|
1901
|
+
/** Explicitly read the retained original input (may include customer data). */
|
|
1902
|
+
input: (runId: string) => Promise<{
|
|
1903
|
+
runId: string;
|
|
1904
|
+
input: Record<string, unknown> | unknown[];
|
|
1905
|
+
bytes: number;
|
|
1906
|
+
sha256: string | null;
|
|
1907
|
+
replayedFromRunId: string | null;
|
|
1908
|
+
}>;
|
|
1909
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
1910
|
+
rerun: (runId: string) => Promise<{
|
|
1911
|
+
runId: string;
|
|
1912
|
+
replayedFromRunId: string;
|
|
1913
|
+
revisionId: string | null;
|
|
1914
|
+
status: string;
|
|
1915
|
+
next: {
|
|
1916
|
+
inspect: string;
|
|
1917
|
+
input: string;
|
|
1918
|
+
};
|
|
1919
|
+
}>;
|
|
1901
1920
|
/** List runs for one play, optionally filtered by status. */
|
|
1902
1921
|
list: (options: RunsListOptions) => Promise<PlayRunListItem[]>;
|
|
1903
1922
|
/** Stream run events and return the latest/terminal run status. */
|
|
@@ -2984,6 +3003,25 @@ declare class DeeplineClient {
|
|
|
2984
3003
|
* tail to completion. Abort via `options.signal` to stop waiting.
|
|
2985
3004
|
*/
|
|
2986
3005
|
tailRun(runId: string, options?: RunsTailOptions): Promise<PlayStatus>;
|
|
3006
|
+
/** Get the exact original input retained for a run. This is intentionally separate from status. */
|
|
3007
|
+
getRunInput(runId: string): Promise<{
|
|
3008
|
+
runId: string;
|
|
3009
|
+
input: Record<string, unknown> | unknown[];
|
|
3010
|
+
bytes: number;
|
|
3011
|
+
sha256: string | null;
|
|
3012
|
+
replayedFromRunId: string | null;
|
|
3013
|
+
}>;
|
|
3014
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
3015
|
+
rerun(runId: string): Promise<{
|
|
3016
|
+
runId: string;
|
|
3017
|
+
replayedFromRunId: string;
|
|
3018
|
+
revisionId: string | null;
|
|
3019
|
+
status: string;
|
|
3020
|
+
next: {
|
|
3021
|
+
inspect: string;
|
|
3022
|
+
input: string;
|
|
3023
|
+
};
|
|
3024
|
+
}>;
|
|
2987
3025
|
/**
|
|
2988
3026
|
* Fetch persisted logs for a run using the public runs resource model.
|
|
2989
3027
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { e as PlayRuntimeBackendId, c as PlayCompilerManifest, D as DeeplineError, f as ToolExecutionError, g as ToolExecutionErrorOptions, h as PlayAuthoringColumnMap, i as PlayAuthoringColumnResolver, j as PlayAuthoringRuntimeContext, k as PlayAuthoringConditionalStepResolver, l as PlayAuthoringCsvInput, m as PlayAuthoringCsvOptions, n as PlayAuthoringDatasetBuilder, o as PlayAuthoringDatasetColumnDefinition, p as PlayAuthoringDatasetColumnRunInput, q as ToolExecuteResult, r as PlayAuthoringReferenceLike, s as PlayReturnObject$1, t as PlayAuthoringDefineConfig, u as PlayAuthoringDefinedPlay, v as PlayAuthoringFetchOptions, w as PlayAuthoringFileInput, x as PlayAuthoringBindings, y as PlayAuthoringCallExecution, z as PlayAuthoringCallOptions, A as PlayAuthoringFetchResponse, B as PlayAuthoringInputContract, C as PlayAuthoringStepProgramStep, E as PlayAuthoringRuntimeStepOptions, F as PlaySqlListenerDeclaration, G as PlaySqlListenerEvent, H as PlaySqlListenerOperation, I as PlaySqlQuery, J as PlayAuthoringStepOptions, K as PlayAuthoringStepProgram, L as PlayAuthoringStepProgramResolver, M as PlayAuthoringStepResolver, N as PlayToolExecutionRequest } from './compiler-manifest-
|
|
2
|
-
export { O as DEEPLINE_EXTRACTOR_TARGETS, Q as DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS, R as DeeplineEmailStatusGetterValue, S as DeeplineExtractorTarget, U as DeeplineGetterValue, V as DeeplineGetterValueMap, W as JOB_CHANGE_STATUS_VALUES, X as JobChangeStatus, Y as PHONE_STATUS_VALUES, Z as PhoneStatus, _ as PlayDataset, $ as PlayDatasetInput, a0 as PreviousCell, a1 as ProviderTransientError, a2 as ProviderTransientErrorCategory, a3 as ToolExecutionErrorCategory, a4 as ToolExecutionErrorOrigin, a5 as ToolExecutionFailureV1, a6 as ToolExecutionNetworkKind, a7 as ToolExecutionNetworkScope, a8 as isDeeplineExtractorTarget } from './compiler-manifest-
|
|
1
|
+
import { e as PlayRuntimeBackendId, c as PlayCompilerManifest, D as DeeplineError, f as ToolExecutionError, g as ToolExecutionErrorOptions, h as PlayAuthoringColumnMap, i as PlayAuthoringColumnResolver, j as PlayAuthoringRuntimeContext, k as PlayAuthoringConditionalStepResolver, l as PlayAuthoringCsvInput, m as PlayAuthoringCsvOptions, n as PlayAuthoringDatasetBuilder, o as PlayAuthoringDatasetColumnDefinition, p as PlayAuthoringDatasetColumnRunInput, q as ToolExecuteResult, r as PlayAuthoringReferenceLike, s as PlayReturnObject$1, t as PlayAuthoringDefineConfig, u as PlayAuthoringDefinedPlay, v as PlayAuthoringFetchOptions, w as PlayAuthoringFileInput, x as PlayAuthoringBindings, y as PlayAuthoringCallExecution, z as PlayAuthoringCallOptions, A as PlayAuthoringFetchResponse, B as PlayAuthoringInputContract, C as PlayAuthoringStepProgramStep, E as PlayAuthoringRuntimeStepOptions, F as PlaySqlListenerDeclaration, G as PlaySqlListenerEvent, H as PlaySqlListenerOperation, I as PlaySqlQuery, J as PlayAuthoringStepOptions, K as PlayAuthoringStepProgram, L as PlayAuthoringStepProgramResolver, M as PlayAuthoringStepResolver, N as PlayToolExecutionRequest } from './compiler-manifest-CGZadg-v.js';
|
|
2
|
+
export { O as DEEPLINE_EXTRACTOR_TARGETS, Q as DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS, R as DeeplineEmailStatusGetterValue, S as DeeplineExtractorTarget, U as DeeplineGetterValue, V as DeeplineGetterValueMap, W as JOB_CHANGE_STATUS_VALUES, X as JobChangeStatus, Y as PHONE_STATUS_VALUES, Z as PhoneStatus, _ as PlayDataset, $ as PlayDatasetInput, a0 as PreviousCell, a1 as ProviderTransientError, a2 as ProviderTransientErrorCategory, a3 as ToolExecutionErrorCategory, a4 as ToolExecutionErrorOrigin, a5 as ToolExecutionFailureV1, a6 as ToolExecutionNetworkKind, a7 as ToolExecutionNetworkScope, a8 as isDeeplineExtractorTarget } from './compiler-manifest-CGZadg-v.js';
|
|
3
3
|
import '@sinclair/typebox';
|
|
4
4
|
|
|
5
5
|
type PlayRuntimeSelection = {
|
|
@@ -1898,6 +1898,25 @@ type PlaySecretMetadata = {
|
|
|
1898
1898
|
type RunsNamespace = {
|
|
1899
1899
|
/** Get current run status by public run id. */
|
|
1900
1900
|
get: (runId: string, options?: RunsGetOptions) => Promise<PlayStatus>;
|
|
1901
|
+
/** Explicitly read the retained original input (may include customer data). */
|
|
1902
|
+
input: (runId: string) => Promise<{
|
|
1903
|
+
runId: string;
|
|
1904
|
+
input: Record<string, unknown> | unknown[];
|
|
1905
|
+
bytes: number;
|
|
1906
|
+
sha256: string | null;
|
|
1907
|
+
replayedFromRunId: string | null;
|
|
1908
|
+
}>;
|
|
1909
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
1910
|
+
rerun: (runId: string) => Promise<{
|
|
1911
|
+
runId: string;
|
|
1912
|
+
replayedFromRunId: string;
|
|
1913
|
+
revisionId: string | null;
|
|
1914
|
+
status: string;
|
|
1915
|
+
next: {
|
|
1916
|
+
inspect: string;
|
|
1917
|
+
input: string;
|
|
1918
|
+
};
|
|
1919
|
+
}>;
|
|
1901
1920
|
/** List runs for one play, optionally filtered by status. */
|
|
1902
1921
|
list: (options: RunsListOptions) => Promise<PlayRunListItem[]>;
|
|
1903
1922
|
/** Stream run events and return the latest/terminal run status. */
|
|
@@ -2984,6 +3003,25 @@ declare class DeeplineClient {
|
|
|
2984
3003
|
* tail to completion. Abort via `options.signal` to stop waiting.
|
|
2985
3004
|
*/
|
|
2986
3005
|
tailRun(runId: string, options?: RunsTailOptions): Promise<PlayStatus>;
|
|
3006
|
+
/** Get the exact original input retained for a run. This is intentionally separate from status. */
|
|
3007
|
+
getRunInput(runId: string): Promise<{
|
|
3008
|
+
runId: string;
|
|
3009
|
+
input: Record<string, unknown> | unknown[];
|
|
3010
|
+
bytes: number;
|
|
3011
|
+
sha256: string | null;
|
|
3012
|
+
replayedFromRunId: string | null;
|
|
3013
|
+
}>;
|
|
3014
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
3015
|
+
rerun(runId: string): Promise<{
|
|
3016
|
+
runId: string;
|
|
3017
|
+
replayedFromRunId: string;
|
|
3018
|
+
revisionId: string | null;
|
|
3019
|
+
status: string;
|
|
3020
|
+
next: {
|
|
3021
|
+
inspect: string;
|
|
3022
|
+
input: string;
|
|
3023
|
+
};
|
|
3024
|
+
}>;
|
|
2987
3025
|
/**
|
|
2988
3026
|
* Fetch persisted logs for a run using the public runs resource model.
|
|
2989
3027
|
*
|
package/dist/index.js
CHANGED
|
@@ -763,7 +763,7 @@ var SDK_RELEASE = {
|
|
|
763
763
|
// 0.2.0 makes Dataset Handles uniformly async-only after 0.1.320 briefly
|
|
764
764
|
// exposed storage-dependent synchronous access. This deliberate minor
|
|
765
765
|
// release keeps lazy paging semantics independent of row residency.
|
|
766
|
-
version: "0.2.
|
|
766
|
+
version: "0.2.23",
|
|
767
767
|
contracts: {
|
|
768
768
|
api: {
|
|
769
769
|
name: "sdk-http-api",
|
|
@@ -3494,6 +3494,8 @@ var DeeplineClient = class {
|
|
|
3494
3494
|
list: (options2) => this.listRuns(options2),
|
|
3495
3495
|
tail: (runId, options2) => this.tailRun(runId, options2),
|
|
3496
3496
|
logs: (runId, options2) => this.getRunLogs(runId, options2),
|
|
3497
|
+
input: (runId) => this.getRunInput(runId),
|
|
3498
|
+
rerun: (runId) => this.rerun(runId),
|
|
3497
3499
|
exportDatasetRows: (input) => this.getPlaySheetRows(input),
|
|
3498
3500
|
stop: (runId, options2) => this.stopRun(runId, options2),
|
|
3499
3501
|
stopAll: (options2) => this.stopAllRuns(options2)
|
|
@@ -4898,6 +4900,17 @@ var DeeplineClient = class {
|
|
|
4898
4900
|
await sleep2(delayMs);
|
|
4899
4901
|
}
|
|
4900
4902
|
}
|
|
4903
|
+
/** Get the exact original input retained for a run. This is intentionally separate from status. */
|
|
4904
|
+
async getRunInput(runId) {
|
|
4905
|
+
return this.http.get(`/api/v2/runs/${encodeURIComponent(runId)}/input`);
|
|
4906
|
+
}
|
|
4907
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
4908
|
+
async rerun(runId) {
|
|
4909
|
+
return this.http.post(
|
|
4910
|
+
`/api/v2/runs/${encodeURIComponent(runId)}/rerun`,
|
|
4911
|
+
{}
|
|
4912
|
+
);
|
|
4913
|
+
}
|
|
4901
4914
|
/**
|
|
4902
4915
|
* Fetch persisted logs for a run using the public runs resource model.
|
|
4903
4916
|
*
|
package/dist/index.mjs
CHANGED
|
@@ -689,7 +689,7 @@ var SDK_RELEASE = {
|
|
|
689
689
|
// 0.2.0 makes Dataset Handles uniformly async-only after 0.1.320 briefly
|
|
690
690
|
// exposed storage-dependent synchronous access. This deliberate minor
|
|
691
691
|
// release keeps lazy paging semantics independent of row residency.
|
|
692
|
-
version: "0.2.
|
|
692
|
+
version: "0.2.23",
|
|
693
693
|
contracts: {
|
|
694
694
|
api: {
|
|
695
695
|
name: "sdk-http-api",
|
|
@@ -3420,6 +3420,8 @@ var DeeplineClient = class {
|
|
|
3420
3420
|
list: (options2) => this.listRuns(options2),
|
|
3421
3421
|
tail: (runId, options2) => this.tailRun(runId, options2),
|
|
3422
3422
|
logs: (runId, options2) => this.getRunLogs(runId, options2),
|
|
3423
|
+
input: (runId) => this.getRunInput(runId),
|
|
3424
|
+
rerun: (runId) => this.rerun(runId),
|
|
3423
3425
|
exportDatasetRows: (input) => this.getPlaySheetRows(input),
|
|
3424
3426
|
stop: (runId, options2) => this.stopRun(runId, options2),
|
|
3425
3427
|
stopAll: (options2) => this.stopAllRuns(options2)
|
|
@@ -4824,6 +4826,17 @@ var DeeplineClient = class {
|
|
|
4824
4826
|
await sleep2(delayMs);
|
|
4825
4827
|
}
|
|
4826
4828
|
}
|
|
4829
|
+
/** Get the exact original input retained for a run. This is intentionally separate from status. */
|
|
4830
|
+
async getRunInput(runId) {
|
|
4831
|
+
return this.http.get(`/api/v2/runs/${encodeURIComponent(runId)}/input`);
|
|
4832
|
+
}
|
|
4833
|
+
/** Start a fresh run from a prior run's retained input and pinned revision. */
|
|
4834
|
+
async rerun(runId) {
|
|
4835
|
+
return this.http.post(
|
|
4836
|
+
`/api/v2/runs/${encodeURIComponent(runId)}/rerun`,
|
|
4837
|
+
{}
|
|
4838
|
+
);
|
|
4839
|
+
}
|
|
4827
4840
|
/**
|
|
4828
4841
|
* Fetch persisted logs for a run using the public runs resource model.
|
|
4829
4842
|
*
|
|
@@ -211,8 +211,8 @@
|
|
|
211
211
|
"dist/cli/index.d.ts",
|
|
212
212
|
"dist/cli/index.js",
|
|
213
213
|
"dist/cli/index.mjs",
|
|
214
|
-
"dist/compiler-manifest-
|
|
215
|
-
"dist/compiler-manifest-
|
|
214
|
+
"dist/compiler-manifest-CGZadg-v.d.mts",
|
|
215
|
+
"dist/compiler-manifest-CGZadg-v.d.ts",
|
|
216
216
|
"dist/helpers.d.mts",
|
|
217
217
|
"dist/helpers.d.ts",
|
|
218
218
|
"dist/helpers.js",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { T as ToolExecutionErrorSchemaVersion, P as PlayAuthoringContractEdition, a as PlayArtifactKind$1, b as PlaySandboxRuntimeDeclaration, c as PlayCompilerManifest } from '../compiler-manifest-
|
|
2
|
-
export { d as PLAY_ARTIFACT_KINDS } from '../compiler-manifest-
|
|
1
|
+
import { T as ToolExecutionErrorSchemaVersion, P as PlayAuthoringContractEdition, a as PlayArtifactKind$1, b as PlaySandboxRuntimeDeclaration, c as PlayCompilerManifest } from '../compiler-manifest-CGZadg-v.mjs';
|
|
2
|
+
export { d as PLAY_ARTIFACT_KINDS } from '../compiler-manifest-CGZadg-v.mjs';
|
|
3
3
|
import '@sinclair/typebox';
|
|
4
4
|
|
|
5
5
|
type PlayPackageImport = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { T as ToolExecutionErrorSchemaVersion, P as PlayAuthoringContractEdition, a as PlayArtifactKind$1, b as PlaySandboxRuntimeDeclaration, c as PlayCompilerManifest } from '../compiler-manifest-
|
|
2
|
-
export { d as PLAY_ARTIFACT_KINDS } from '../compiler-manifest-
|
|
1
|
+
import { T as ToolExecutionErrorSchemaVersion, P as PlayAuthoringContractEdition, a as PlayArtifactKind$1, b as PlaySandboxRuntimeDeclaration, c as PlayCompilerManifest } from '../compiler-manifest-CGZadg-v.js';
|
|
2
|
+
export { d as PLAY_ARTIFACT_KINDS } from '../compiler-manifest-CGZadg-v.js';
|
|
3
3
|
import '@sinclair/typebox';
|
|
4
4
|
|
|
5
5
|
type PlayPackageImport = {
|
|
@@ -3468,10 +3468,10 @@ var PLAY_AUTHORING_FIELD_REGISTRY = {
|
|
|
3468
3468
|
},
|
|
3469
3469
|
referenceType: "string",
|
|
3470
3470
|
required: true,
|
|
3471
|
-
resolution: "
|
|
3471
|
+
resolution: "runtime-dynamic",
|
|
3472
3472
|
issueCode: "play_authoring_run_play_option_invalid",
|
|
3473
3473
|
description: "Stable identity for one inline child Play call.",
|
|
3474
|
-
errorMessage: "ctx.runPlay key must be a non-empty
|
|
3474
|
+
errorMessage: "ctx.runPlay key must be a non-empty string."
|
|
3475
3475
|
},
|
|
3476
3476
|
"ctx.runPlay.playRef": {
|
|
3477
3477
|
schema: Type.Union([
|