deepline 0.3.393 → 0.3.394
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/release.ts +1 -1
- package/dist/bundling-sources/shared_libs/play-runtime/context.ts +477 -10
- package/dist/bundling-sources/shared_libs/play-runtime/ctx-types.ts +5 -1
- package/dist/bundling-sources/shared_libs/play-runtime/durable-call-policy.ts +28 -0
- package/dist/bundling-sources/shared_libs/play-runtime/freshness-receipt-execution.ts +251 -0
- package/dist/bundling-sources/shared_libs/play-runtime/play-runtime-semantics.ts +12 -1
- package/dist/bundling-sources/shared_libs/play-runtime/runner-app/index.ts +10 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-api.ts +25 -16
- package/dist/bundling-sources/shared_libs/play-runtime/tool-result.ts +1 -0
- package/dist/bundling-sources/shared_libs/plays/authoring-contract.ts +69 -22
- package/dist/bundling-sources/shared_libs/plays/core.ts +1 -1
- package/dist/bundling-sources/shared_libs/plays/tool-result-types.ts +18 -0
- package/dist/cli/auth-IHKISLJQ.js +39 -0
- package/dist/cli/{auth-5PXHA232.mjs → auth-OSXDAVCF.mjs} +4 -4
- package/dist/cli/{billing-JFB2XLSO.js → billing-EKLYOXUY.js} +75 -75
- package/dist/cli/{billing-Z2N7ZAGM.mjs → billing-ZNNKX3UR.mjs} +4 -4
- package/dist/cli/{chunk-OXNOAD6Y.js → chunk-2MDDA7A4.js} +26 -26
- package/dist/cli/{chunk-PTDECJGP.js → chunk-354JCXA2.js} +50 -50
- package/dist/cli/{chunk-RKMB3N7K.mjs → chunk-3HU47EGZ.mjs} +48 -9
- package/dist/cli/{chunk-6I73X254.mjs → chunk-3HWALOL2.mjs} +1 -1
- package/dist/cli/{chunk-VIQJIX2P.js → chunk-4P27AXEA.js} +65 -65
- package/dist/cli/{chunk-UOGZUA24.mjs → chunk-5BB2RGAX.mjs} +18 -8
- package/dist/cli/{chunk-RWHWF5ZJ.js → chunk-6YAUMG27.js} +1 -1
- package/dist/cli/{chunk-HLEESTCH.mjs → chunk-BP33SIZF.mjs} +1 -1
- package/dist/cli/{chunk-CDFH2DYL.js → chunk-CS6RAIVY.js} +4 -4
- package/dist/cli/{chunk-2HAD745V.js → chunk-E23BQ5SC.js} +9 -9
- package/dist/cli/{chunk-LMMEAMA7.mjs → chunk-FJGW5GXU.mjs} +1 -1
- package/dist/cli/{chunk-Q26LUSQ2.mjs → chunk-JHIJIHFB.mjs} +1 -1
- package/dist/cli/{chunk-PWSWAN7Q.js → chunk-KB4SDX5S.js} +48 -9
- package/dist/cli/{chunk-M7Y7JYZX.js → chunk-KGNTKMRG.js} +6 -6
- package/dist/cli/{chunk-4XX6443T.js → chunk-KI635JN4.js} +59 -59
- package/dist/cli/{chunk-Z3OOZM5L.js → chunk-KIUMEOM5.js} +8 -8
- package/dist/cli/{chunk-KIYU2TGL.mjs → chunk-M57J2SK4.mjs} +2 -2
- package/dist/cli/{chunk-FQ6VHPW4.mjs → chunk-MFB2VKBO.mjs} +2 -2
- package/dist/cli/{chunk-MS6GUPBB.js → chunk-MH73HMPV.js} +3 -3
- package/dist/cli/{chunk-AARX5L4B.js → chunk-MLPU5SMZ.js} +2 -2
- package/dist/cli/{chunk-5PRVMXKB.mjs → chunk-NR3DFKNF.mjs} +1 -1
- package/dist/cli/{chunk-W4WOMXR3.js → chunk-QIQBYKLB.js} +15 -15
- package/dist/cli/{chunk-VIWE6WRK.js → chunk-RBJYWRCF.js} +260 -250
- package/dist/cli/{chunk-LZPCDB7U.mjs → chunk-TJI2EN6K.mjs} +1 -1
- package/dist/cli/{chunk-4TCT77UF.js → chunk-URWF7NGQ.js} +6 -1
- package/dist/cli/{chunk-5KWKZIQR.mjs → chunk-UXFSWG3Q.mjs} +4 -4
- package/dist/cli/{chunk-L2SYLGRP.js → chunk-VK6FYZLP.js} +8 -8
- package/dist/cli/{chunk-7HR7BGZL.mjs → chunk-X63FDZJZ.mjs} +3 -3
- package/dist/cli/{chunk-4PT2VA3A.mjs → chunk-XRQ2AQL7.mjs} +2 -2
- package/dist/cli/{chunk-STNYIMIV.mjs → chunk-XXUDVEXK.mjs} +6 -6
- package/dist/cli/{chunk-PQSA443V.mjs → chunk-ZI2ZNDJK.mjs} +6 -1
- package/dist/cli/{chunk-2LGC4EFT.mjs → chunk-ZYBGA4AR.mjs} +3 -3
- package/dist/cli/command-docs.js +2 -2
- package/dist/cli/command-docs.mjs +1 -1
- package/dist/cli/{csv-KJWZHKCH.mjs → csv-5AXRB35H.mjs} +3 -3
- package/dist/cli/{csv-P3Z3YE7H.js → csv-LU7O75WE.js} +12 -12
- package/dist/cli/{db-NCM4CQIS.mjs → db-7XP5UWEW.mjs} +4 -4
- package/dist/cli/{db-NUZGJNQC.js → db-F7YTFKVM.js} +29 -29
- package/dist/cli/{describe-YGSEN5WC.js → describe-FRH32RDV.js} +20 -20
- package/dist/cli/{describe-WT6MM2GO.mjs → describe-K4ES5LIL.mjs} +10 -10
- package/dist/cli/{executions-XS2IPJ4W.mjs → executions-IEHEHJUO.mjs} +4 -4
- package/dist/cli/{executions-PCOLHN7Q.js → executions-RZV5XPT2.js} +6 -6
- package/dist/cli/{feedback-4MSH7TFU.js → feedback-3P65QTX3.js} +7 -7
- package/dist/cli/{feedback-CCLTS5SV.mjs → feedback-FPUVZBAN.mjs} +3 -3
- package/dist/cli/{git-K2DHPMPC.mjs → git-GLVVP7TY.mjs} +4 -4
- package/dist/cli/git-MFFAWVVX.js +23 -0
- package/dist/cli/index.js +95 -95
- package/dist/cli/index.mjs +33 -33
- package/dist/cli/{legacy-noops-B5S4AR3P.mjs → legacy-noops-3MOI6NBM.mjs} +4 -4
- package/dist/cli/{legacy-noops-GPNOPFXV.js → legacy-noops-XKSGZR7Q.js} +7 -7
- package/dist/cli/{monitors-JLMAIPRG.mjs → monitors-FTBGNEFG.mjs} +4 -4
- package/dist/cli/{monitors-ZAWD7NSN.js → monitors-NZ2DYNST.js} +85 -85
- package/dist/cli/{org-P2KN4CES.js → org-MCKDQXIV.js} +64 -64
- package/dist/cli/{org-T3JTHP4G.mjs → org-V2J5RBCN.mjs} +4 -4
- package/dist/cli/{play-NK6BLRGL.mjs → play-AJFGME3B.mjs} +9 -9
- package/dist/cli/play-WLSN2EO2.js +158 -0
- package/dist/cli/{providers-5QRZN3DT.js → providers-2JEZ2264.js} +7 -7
- package/dist/cli/{providers-3NQRA7IT.mjs → providers-I6RQJZFZ.mjs} +4 -4
- package/dist/cli/{quickstart-PIA2JGPV.mjs → quickstart-BIDQDMO4.mjs} +3 -3
- package/dist/cli/{quickstart-R7NUZGNW.js → quickstart-GJ2RPDU3.js} +5 -5
- package/dist/cli/search-5VN4YD4I.js +27 -0
- package/dist/cli/{search-AIDIIGLY.mjs → search-ELRXFWG5.mjs} +5 -5
- package/dist/cli/{secrets-BT3PGMWN.js → secrets-53IT6VXD.js} +13 -13
- package/dist/cli/{secrets-OQNHL45O.mjs → secrets-SQXGZXIC.mjs} +4 -4
- package/dist/cli/{sessions-SF7WJPJP.mjs → sessions-2X5QF7SL.mjs} +4 -4
- package/dist/cli/{sessions-EYXWOSWK.js → sessions-CAV5M77Y.js} +5 -5
- package/dist/cli/{settings-BA3GHBOD.js → settings-532WNAZO.js} +74 -74
- package/dist/cli/{settings-Y57JTFDD.mjs → settings-7P67VGCJ.mjs} +7 -7
- package/dist/cli/{setup-RERXYC66.js → setup-6L2VSUWJ.js} +41 -41
- package/dist/cli/{setup-7GR5GBHA.mjs → setup-QGGBV2LE.mjs} +6 -6
- package/dist/cli/{skills-SJWIQAV5.mjs → skills-3FE62WBG.mjs} +4 -4
- package/dist/cli/skills-S6NPZAN7.js +28 -0
- package/dist/cli/tools-647RLXQS.js +41 -0
- package/dist/cli/{tools-ZF3JXPNL.mjs → tools-DMR25DEF.mjs} +7 -7
- package/dist/cli/{update-FFFYQAOJ.mjs → update-6RZMHJZP.mjs} +6 -6
- package/dist/cli/update-WVTSC3EM.js +28 -0
- package/dist/cli/{workflow-XVFEEGAS.mjs → workflow-L2DQRE6R.mjs} +5 -5
- package/dist/cli/{workflow-SZJVQH4T.js → workflow-TX4F2PIX.js} +15 -15
- package/dist/{client-DU5dtHDy.d.mts → client-BktIPdIj.d.mts} +1 -1
- package/dist/{client-mCE88hC4.d.ts → client-C3O1Ipf3.d.ts} +1 -1
- package/dist/{compiler-manifest-DE4RdAiY.d.ts → compiler-manifest-DLxUY5kI.d.mts} +65 -11
- package/dist/{compiler-manifest-DE4RdAiY.d.mts → compiler-manifest-DLxUY5kI.d.ts} +65 -11
- package/dist/{index-Bi-f7HFT.d.ts → index-B_GM9E3q.d.ts} +1 -1
- package/dist/{index-BI6nWgaV.d.mts → index-SCb0NvDb.d.mts} +1 -1
- package/dist/index.d.mts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +7 -7
- package/dist/index.mjs +4 -4
- package/dist/install-integrity.json +85 -84
- package/dist/plays/bundle-play-file.d.mts +3 -3
- package/dist/plays/bundle-play-file.d.ts +3 -3
- package/dist/plays/bundle-play-file.mjs +2 -2
- package/dist/plays/run-request.d.mts +2 -2
- package/dist/plays/run-request.d.ts +2 -2
- package/dist/release.d.mts +1 -1
- package/dist/release.d.ts +1 -1
- package/dist/release.js +2 -2
- package/dist/release.mjs +1 -1
- package/package.json +1 -1
- package/dist/cli/auth-P3MVDTXM.js +0 -39
- package/dist/cli/git-RNM45FX4.js +0 -23
- package/dist/cli/play-PDXR6JFB.js +0 -158
- package/dist/cli/search-QRWL7MFM.js +0 -27
- package/dist/cli/skills-V7EY75HB.js +0 -28
- package/dist/cli/tools-H5HLBCHH.js +0 -41
- package/dist/cli/update-472HA3LT.js +0 -28
|
@@ -13,17 +13,17 @@ var _chunkAID3OYVJjs = require('./chunk-AID3OYVJ.js');
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunkMH73HMPVjs = require('./chunk-MH73HMPV.js');
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
var _chunkGSK6NHVMjs = require('./chunk-GSK6NHVM.js');
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
var
|
|
22
|
+
var _chunkVK6FYZLPjs = require('./chunk-VK6FYZLP.js');
|
|
23
23
|
|
|
24
24
|
|
|
25
25
|
|
|
26
|
-
var
|
|
26
|
+
var _chunk2MDDA7A4js = require('./chunk-2MDDA7A4.js');
|
|
27
27
|
|
|
28
28
|
|
|
29
29
|
|
|
@@ -42,7 +42,7 @@ var _chunkGEJDBXXMjs = require('./chunk-GEJDBXXM.js');
|
|
|
42
42
|
|
|
43
43
|
|
|
44
44
|
|
|
45
|
-
var
|
|
45
|
+
var _chunkE23BQ5SCjs = require('./chunk-E23BQ5SC.js');
|
|
46
46
|
|
|
47
47
|
|
|
48
48
|
|
|
@@ -75,10 +75,10 @@ var _chunkWJYPBHTEjs = require('./chunk-WJYPBHTE.js');
|
|
|
75
75
|
|
|
76
76
|
|
|
77
77
|
|
|
78
|
-
var
|
|
78
|
+
var _chunkKGNTKMRGjs = require('./chunk-KGNTKMRG.js');
|
|
79
79
|
|
|
80
80
|
|
|
81
|
-
var
|
|
81
|
+
var _chunkCS6RAIVYjs = require('./chunk-CS6RAIVY.js');
|
|
82
82
|
|
|
83
83
|
|
|
84
84
|
var _chunk7P5AA3SNjs = require('./chunk-7P5AA3SN.js');
|
|
@@ -2062,7 +2062,7 @@ function resolveField(key, command) {
|
|
|
2062
2062
|
function printSettings(result, json, name) {
|
|
2063
2063
|
result = { ...result, settings: parsePlaySettings(result.settings) };
|
|
2064
2064
|
const selected = fields.filter(([key]) => !name || key === name);
|
|
2065
|
-
|
|
2065
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
2066
2066
|
{
|
|
2067
2067
|
...result,
|
|
2068
2068
|
settings: Object.fromEntries(
|
|
@@ -2106,7 +2106,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2106
2106
|
valueSyntax: field.cli.valueSyntax,
|
|
2107
2107
|
examples: field.cli.examples
|
|
2108
2108
|
}));
|
|
2109
|
-
|
|
2109
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
2110
2110
|
{
|
|
2111
2111
|
fields: descriptions,
|
|
2112
2112
|
render: {
|
|
@@ -2131,7 +2131,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2131
2131
|
async (options, command) => {
|
|
2132
2132
|
if (options.name !== void 0) resolveField(options.name, command);
|
|
2133
2133
|
printSettings(
|
|
2134
|
-
await new (0,
|
|
2134
|
+
await new (0, _chunkE23BQ5SCjs.DeeplineClient)().getPlaySettings(options.play),
|
|
2135
2135
|
options.json,
|
|
2136
2136
|
options.name
|
|
2137
2137
|
);
|
|
@@ -2162,7 +2162,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2162
2162
|
);
|
|
2163
2163
|
}
|
|
2164
2164
|
if (options.dryRun) {
|
|
2165
|
-
|
|
2165
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
2166
2166
|
{
|
|
2167
2167
|
dryRun: true,
|
|
2168
2168
|
play,
|
|
@@ -2183,7 +2183,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2183
2183
|
return;
|
|
2184
2184
|
}
|
|
2185
2185
|
printSettings(
|
|
2186
|
-
await new (0,
|
|
2186
|
+
await new (0, _chunkE23BQ5SCjs.DeeplineClient)().updatePlaySettings(play, patch),
|
|
2187
2187
|
options.json
|
|
2188
2188
|
);
|
|
2189
2189
|
};
|
|
@@ -2209,13 +2209,13 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2209
2209
|
"--root must be person or team; --limit must be 1\u2013100.",
|
|
2210
2210
|
{ exitCode: 2 }
|
|
2211
2211
|
);
|
|
2212
|
-
const page = await new (0,
|
|
2212
|
+
const page = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().listPlaySettingsPaths({
|
|
2213
2213
|
root: options.root,
|
|
2214
2214
|
limit,
|
|
2215
2215
|
cursor: options.cursor
|
|
2216
2216
|
});
|
|
2217
2217
|
const nextCommand = page.hasMore ? `deepline plays settings paths --cursor '${page.cursor}'${options.root ? ` --root ${options.root}` : ""}` : null;
|
|
2218
|
-
|
|
2218
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
2219
2219
|
{
|
|
2220
2220
|
...page,
|
|
2221
2221
|
nextCommand,
|
|
@@ -2266,7 +2266,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2266
2266
|
root: _nullishCoalesce(_optionalChain([toPath, 'optionalAccess', _13 => _13.root]), () => ( "person")),
|
|
2267
2267
|
folders: _nullishCoalesce(_optionalChain([toPath, 'optionalAccess', _14 => _14.folders]), () => ( []))
|
|
2268
2268
|
};
|
|
2269
|
-
const client = new (0,
|
|
2269
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
2270
2270
|
const paths = [];
|
|
2271
2271
|
let cursor;
|
|
2272
2272
|
do {
|
|
@@ -2328,7 +2328,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2328
2328
|
moved.push(move.playName);
|
|
2329
2329
|
}
|
|
2330
2330
|
}
|
|
2331
|
-
|
|
2331
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
2332
2332
|
{
|
|
2333
2333
|
dryRun: Boolean(options.dryRun),
|
|
2334
2334
|
from: options.from,
|
|
@@ -2456,7 +2456,7 @@ function triggerLines(view) {
|
|
|
2456
2456
|
return lines;
|
|
2457
2457
|
}
|
|
2458
2458
|
function printView(view, json) {
|
|
2459
|
-
|
|
2459
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
2460
2460
|
{
|
|
2461
2461
|
...view,
|
|
2462
2462
|
render: {
|
|
@@ -2469,7 +2469,7 @@ function printView(view, json) {
|
|
|
2469
2469
|
);
|
|
2470
2470
|
}
|
|
2471
2471
|
function printResult(result, json) {
|
|
2472
|
-
|
|
2472
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
2473
2473
|
{
|
|
2474
2474
|
...result,
|
|
2475
2475
|
render: {
|
|
@@ -2499,7 +2499,7 @@ async function mutate(command, options, build) {
|
|
|
2499
2499
|
usage(command, `Invalid trigger: ${formatPlayTriggerConfigError(error)}`);
|
|
2500
2500
|
}
|
|
2501
2501
|
if (options.dryRun) {
|
|
2502
|
-
|
|
2502
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
2503
2503
|
{
|
|
2504
2504
|
dryRun: true,
|
|
2505
2505
|
play: options.play,
|
|
@@ -2518,7 +2518,7 @@ async function mutate(command, options, build) {
|
|
|
2518
2518
|
return;
|
|
2519
2519
|
}
|
|
2520
2520
|
printResult(
|
|
2521
|
-
await new (0,
|
|
2521
|
+
await new (0, _chunkE23BQ5SCjs.DeeplineClient)().updatePlayTriggerConfig(options.play, update),
|
|
2522
2522
|
options.json
|
|
2523
2523
|
);
|
|
2524
2524
|
}
|
|
@@ -2551,7 +2551,7 @@ function registerPlayTriggerConfigCommands(plays) {
|
|
|
2551
2551
|
}).addHelpText("after", help2);
|
|
2552
2552
|
trigger.command("get").description("Show the cron and webhook triggers of a Play.").requiredOption("--play <play>", "Play to read").option("--json", "Emit JSON").addHelpText("after", help2).action(async (options) => {
|
|
2553
2553
|
printView(
|
|
2554
|
-
await new (0,
|
|
2554
|
+
await new (0, _chunkE23BQ5SCjs.DeeplineClient)().getPlayTriggerConfig(options.play),
|
|
2555
2555
|
options.json
|
|
2556
2556
|
);
|
|
2557
2557
|
});
|
|
@@ -2595,7 +2595,7 @@ function registerPlayTriggerConfigCommands(plays) {
|
|
|
2595
2595
|
if (options.auth === void 0) {
|
|
2596
2596
|
if (secrets.length || options.header || options.signaturePrefix)
|
|
2597
2597
|
usage(setWebhook, "--secret/--header need --auth.");
|
|
2598
|
-
const current = await new (0,
|
|
2598
|
+
const current = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().getPlayTriggerConfig(
|
|
2599
2599
|
options.play
|
|
2600
2600
|
);
|
|
2601
2601
|
return {
|
|
@@ -2672,7 +2672,7 @@ var KIND_DESCRIPTIONS = {
|
|
|
2672
2672
|
"receipt.skipped": "Saved work result: skipped.",
|
|
2673
2673
|
"runtime.event": "Other event."
|
|
2674
2674
|
};
|
|
2675
|
-
var RUN_LOGS_KIND_HELP =
|
|
2675
|
+
var RUN_LOGS_KIND_HELP = _chunkE23BQ5SCjs.RUN_EVENT_SEARCH_KIND_VALUES.map((kind) => ({
|
|
2676
2676
|
kind,
|
|
2677
2677
|
description: KIND_DESCRIPTIONS[kind]
|
|
2678
2678
|
}));
|
|
@@ -2809,9 +2809,9 @@ function configureRunQueryCommandErrors(command, resource) {
|
|
|
2809
2809
|
const args = program.args;
|
|
2810
2810
|
if (error.exitCode !== 0 && (resource === "events" || requestsStructuredLogs(args))) {
|
|
2811
2811
|
error.exitCode = 2;
|
|
2812
|
-
if (
|
|
2813
|
-
|
|
2814
|
-
Object.assign(new (0,
|
|
2812
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args) || command.optsWithGlobals().json === true) {
|
|
2813
|
+
_chunkKGNTKMRGjs.printJsonError.call(void 0,
|
|
2814
|
+
Object.assign(new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(error.message), {
|
|
2815
2815
|
exitCode: 2,
|
|
2816
2816
|
retryable: false
|
|
2817
2817
|
})
|
|
@@ -2855,14 +2855,14 @@ function parseQuery(args, resource) {
|
|
|
2855
2855
|
if (VALUE_FLAGS.has(flag)) {
|
|
2856
2856
|
const value = equals > 0 ? arg.slice(equals + 1) : args[++index];
|
|
2857
2857
|
if (!value || equals < 0 && value.startsWith("--") && flag !== "--query" && flag !== "--where") {
|
|
2858
|
-
throw new (0,
|
|
2858
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2859
2859
|
`${flag} requires a value. Use ${flag} <value>.`
|
|
2860
2860
|
);
|
|
2861
2861
|
}
|
|
2862
2862
|
if (flag === "--sum") sums.push(value);
|
|
2863
2863
|
else {
|
|
2864
2864
|
if (values[flag] !== void 0) {
|
|
2865
|
-
throw new (0,
|
|
2865
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2866
2866
|
`${flag} may only be supplied once.`
|
|
2867
2867
|
);
|
|
2868
2868
|
}
|
|
@@ -2876,12 +2876,12 @@ function parseQuery(args, resource) {
|
|
|
2876
2876
|
}
|
|
2877
2877
|
if (arg.startsWith("-")) {
|
|
2878
2878
|
const correction = flag === "--log-level" ? "Use --level for structured severity filtering." : flag === "--out" || flag === "--failed" || flag === "--all" ? "Use this flag with a plain runs logs <run-id> text read." : "Use --step, --level, --query, --where, --count, --group-by or --fields; see runs logs --help.";
|
|
2879
|
-
throw new (0,
|
|
2879
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2880
2880
|
`Unsupported query flag ${flag}. ${correction}`
|
|
2881
2881
|
);
|
|
2882
2882
|
}
|
|
2883
2883
|
if (runId !== void 0) {
|
|
2884
|
-
throw new (0,
|
|
2884
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2885
2885
|
`Unexpected argument ${JSON.stringify(arg)}. Supply one run ID.`
|
|
2886
2886
|
);
|
|
2887
2887
|
}
|
|
@@ -2889,7 +2889,7 @@ function parseQuery(args, resource) {
|
|
|
2889
2889
|
}
|
|
2890
2890
|
if (switches.has("--fields")) {
|
|
2891
2891
|
if (runId !== void 0) {
|
|
2892
|
-
throw new (0,
|
|
2892
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2893
2893
|
"--fields does not use a run ID. Omit the positional run ID."
|
|
2894
2894
|
);
|
|
2895
2895
|
}
|
|
@@ -2902,18 +2902,18 @@ function parseQuery(args, resource) {
|
|
|
2902
2902
|
)
|
|
2903
2903
|
];
|
|
2904
2904
|
if (incompatible.length) {
|
|
2905
|
-
throw new (0,
|
|
2905
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2906
2906
|
`--fields cannot be combined with ${incompatible.join(", ")}. Use --fields alone to discover the query contract.`
|
|
2907
2907
|
);
|
|
2908
2908
|
}
|
|
2909
2909
|
}
|
|
2910
2910
|
if (switches.has("--count") && values["--group-by"] !== void 0) {
|
|
2911
|
-
throw new (0,
|
|
2911
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2912
2912
|
"--count cannot be combined with --group-by. Use --group-by for counts per group."
|
|
2913
2913
|
);
|
|
2914
2914
|
}
|
|
2915
2915
|
if (sums.length && switches.has("--count")) {
|
|
2916
|
-
throw new (0,
|
|
2916
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2917
2917
|
"--sum cannot be combined with --count. Use --sum for the exact count and numeric total."
|
|
2918
2918
|
);
|
|
2919
2919
|
}
|
|
@@ -2921,7 +2921,7 @@ function parseQuery(args, resource) {
|
|
|
2921
2921
|
if (operation === "count") {
|
|
2922
2922
|
for (const flag of ["--limit", "--cursor", "--payloads"]) {
|
|
2923
2923
|
if (values[flag] !== void 0 || switches.has(flag)) {
|
|
2924
|
-
throw new (0,
|
|
2924
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2925
2925
|
`--count cannot be combined with ${flag}. Remove ${flag} to count all matching retained records.`
|
|
2926
2926
|
);
|
|
2927
2927
|
}
|
|
@@ -2956,16 +2956,16 @@ function parseQuery(args, resource) {
|
|
|
2956
2956
|
];
|
|
2957
2957
|
}
|
|
2958
2958
|
}
|
|
2959
|
-
const request =
|
|
2959
|
+
const request = _chunkE23BQ5SCjs.normalizeRunEventOperationRequest.call(void 0, body);
|
|
2960
2960
|
const namespace = _nullishCoalesce(values["--runtime-namespace"], () => ( (process.env.DEEPLINE_RUNTIME_ENVIRONMENT === "preview" ? process.env.DEEPLINE_RUNTIME_NAMESPACE : void 0)));
|
|
2961
2961
|
const backend = values["--runtime-backend"];
|
|
2962
2962
|
if (backend && backend !== "daytona" && backend !== "modal") {
|
|
2963
|
-
throw new (0,
|
|
2963
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2964
2964
|
"--runtime-backend must be daytona or modal."
|
|
2965
2965
|
);
|
|
2966
2966
|
}
|
|
2967
2967
|
if (backend && !namespace) {
|
|
2968
|
-
throw new (0,
|
|
2968
|
+
throw new (0, _chunkE23BQ5SCjs.RunEventQueryInputError)(
|
|
2969
2969
|
"--runtime-backend requires --runtime-namespace."
|
|
2970
2970
|
);
|
|
2971
2971
|
}
|
|
@@ -3012,12 +3012,12 @@ async function handleRunEventQuery(args, resource = "logs") {
|
|
|
3012
3012
|
const failure = error instanceof Error ? error : new Error(String(error));
|
|
3013
3013
|
const record3 = failure;
|
|
3014
3014
|
const status = record3.statusCode;
|
|
3015
|
-
const exitCode = error instanceof
|
|
3015
|
+
const exitCode = error instanceof _chunkE23BQ5SCjs.RunEventQueryInputError || status === 400 || status === 422 || record3.code === "INVALID_RUNTIME_SELECTION" ? 2 : status === 401 || status === 403 || record3.code === "CONFIG_ERROR" || record3.code === "RUNTIME_ENVIRONMENT_TOKEN_REQUIRED" ? 3 : status === 404 ? 4 : 5;
|
|
3016
3016
|
const diagnostic = Object.assign(failure, {
|
|
3017
3017
|
exitCode,
|
|
3018
3018
|
retryable: exitCode === 5
|
|
3019
3019
|
});
|
|
3020
|
-
if (
|
|
3020
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) _chunkKGNTKMRGjs.printJsonError.call(void 0, diagnostic);
|
|
3021
3021
|
else console.error(`Error: ${diagnostic.message}`);
|
|
3022
3022
|
return exitCode;
|
|
3023
3023
|
}
|
|
@@ -3032,7 +3032,7 @@ async function executeRunEventQuery(args, resource) {
|
|
|
3032
3032
|
...criteria
|
|
3033
3033
|
} = request;
|
|
3034
3034
|
const options = { ...criteria, ...runtime ? { runtime } : {} };
|
|
3035
|
-
const client = new (0,
|
|
3035
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
3036
3036
|
let result;
|
|
3037
3037
|
if (request.operation === "fields") {
|
|
3038
3038
|
result = await client.runs[resource].fields(runtime ? { runtime } : {});
|
|
@@ -3098,13 +3098,13 @@ async function executeRunEventQuery(args, resource) {
|
|
|
3098
3098
|
lines.push(`Next page: ${nextPage}`);
|
|
3099
3099
|
}
|
|
3100
3100
|
}
|
|
3101
|
-
|
|
3101
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
3102
3102
|
{
|
|
3103
3103
|
...result,
|
|
3104
3104
|
...nextPage ? { next: { page: nextPage } } : {},
|
|
3105
3105
|
render: { sections: [{ title: `run ${resource}`, lines }] }
|
|
3106
3106
|
},
|
|
3107
|
-
{ json:
|
|
3107
|
+
{ json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args), text: `${lines.join("\n")}
|
|
3108
3108
|
` }
|
|
3109
3109
|
);
|
|
3110
3110
|
return 0;
|
|
@@ -3924,7 +3924,7 @@ function checkedRunExample(plays, target) {
|
|
|
3924
3924
|
const quote = (value) => `'${value.replace(/'/g, `'\\''`)}'`;
|
|
3925
3925
|
const base = `deepline plays run --file ${quote(target)}`;
|
|
3926
3926
|
return {
|
|
3927
|
-
command: `${base}${
|
|
3927
|
+
command: `${base}${_chunkE23BQ5SCjs.playInputExampleArgs.call(void 0, schema)}`,
|
|
3928
3928
|
note: "Runs the local file without publishing and may spend credits. Supply the indicated file; JSON input must match inputSchema."
|
|
3929
3929
|
};
|
|
3930
3930
|
}
|
|
@@ -4022,7 +4022,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4022
4022
|
...text.split(/\r?\n/).map((key) => key.trim()).filter(Boolean)
|
|
4023
4023
|
);
|
|
4024
4024
|
}
|
|
4025
|
-
const response = await new (0,
|
|
4025
|
+
const response = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().runs.getReceipts(runId, {
|
|
4026
4026
|
keys
|
|
4027
4027
|
});
|
|
4028
4028
|
const failed = response.receipts.filter(
|
|
@@ -4034,7 +4034,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4034
4034
|
JSON.stringify(response, null, 2) + "\n",
|
|
4035
4035
|
{ flag: "wx", mode: 384 }
|
|
4036
4036
|
);
|
|
4037
|
-
|
|
4037
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
4038
4038
|
{
|
|
4039
4039
|
runId,
|
|
4040
4040
|
out: options.out,
|
|
@@ -4044,7 +4044,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4044
4044
|
{ json: true }
|
|
4045
4045
|
);
|
|
4046
4046
|
} else {
|
|
4047
|
-
|
|
4047
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, { ...response }, { json: true });
|
|
4048
4048
|
}
|
|
4049
4049
|
if (failed)
|
|
4050
4050
|
process.exitCode = response.receipts.some(
|
|
@@ -4083,7 +4083,7 @@ includes nextCommand when another page is available.
|
|
|
4083
4083
|
{ exitCode: 2 }
|
|
4084
4084
|
);
|
|
4085
4085
|
}
|
|
4086
|
-
const page = await new (0,
|
|
4086
|
+
const page = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().runs.children(parentRunId, {
|
|
4087
4087
|
launchKey: options.launchKey,
|
|
4088
4088
|
...options.cursor !== void 0 ? { cursor: options.cursor } : {},
|
|
4089
4089
|
limit
|
|
@@ -4098,7 +4098,7 @@ includes nextCommand when another page is available.
|
|
|
4098
4098
|
"--limit",
|
|
4099
4099
|
String(limit)
|
|
4100
4100
|
].join(" ") : null;
|
|
4101
|
-
|
|
4101
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
4102
4102
|
{
|
|
4103
4103
|
parentRunId,
|
|
4104
4104
|
launchKey: options.launchKey,
|
|
@@ -4134,7 +4134,7 @@ async function handleRunsHistory(options) {
|
|
|
4134
4134
|
throw new Error("--limit must be a positive integer.");
|
|
4135
4135
|
}
|
|
4136
4136
|
}
|
|
4137
|
-
const page = await new (0,
|
|
4137
|
+
const page = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().runs.history({
|
|
4138
4138
|
cursor: options.cursor,
|
|
4139
4139
|
orgId: options.org,
|
|
4140
4140
|
search: options.search,
|
|
@@ -4150,7 +4150,7 @@ async function handleRunsHistory(options) {
|
|
|
4150
4150
|
);
|
|
4151
4151
|
}
|
|
4152
4152
|
if (page.hasMore) lines.push(`Next cursor: ${page.nextCursor}`);
|
|
4153
|
-
|
|
4153
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
4154
4154
|
{ ...page, render: { sections: [{ title: "Run history", lines }] } },
|
|
4155
4155
|
options.json ? { json: true } : {}
|
|
4156
4156
|
);
|
|
@@ -4202,12 +4202,12 @@ async function runRunsRerunCommand(runId, options) {
|
|
|
4202
4202
|
return 1;
|
|
4203
4203
|
}
|
|
4204
4204
|
}
|
|
4205
|
-
const result = await new (0,
|
|
4205
|
+
const result = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().runs.rerun(runId, {
|
|
4206
4206
|
...idempotencyKey === void 0 ? {} : { idempotencyKey },
|
|
4207
4207
|
...inputOverrides === void 0 ? {} : { inputOverrides }
|
|
4208
4208
|
});
|
|
4209
|
-
if (
|
|
4210
|
-
|
|
4209
|
+
if (_chunkKGNTKMRGjs.shouldEmitJson.call(void 0, options.json)) {
|
|
4210
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, result, { json: true });
|
|
4211
4211
|
} else {
|
|
4212
4212
|
console.log(
|
|
4213
4213
|
result.deduplicated === true ? `
|
|
@@ -4475,7 +4475,7 @@ function projectRunDatasetCell(value) {
|
|
|
4475
4475
|
const logicalValue = parseSerializedDatasetValue(value);
|
|
4476
4476
|
if (logicalValue === null || logicalValue === void 0) return logicalValue;
|
|
4477
4477
|
if (typeof logicalValue === "object") {
|
|
4478
|
-
return
|
|
4478
|
+
return _chunkKGNTKMRGjs.csvSafeJsonString.call(void 0, canonicalDatasetJson(logicalValue));
|
|
4479
4479
|
}
|
|
4480
4480
|
return logicalValue;
|
|
4481
4481
|
}
|
|
@@ -5352,7 +5352,7 @@ function stringValue(value) {
|
|
|
5352
5352
|
var EXTRACTED_GETTER_ERROR_HINT = "Deepline hint: extractedValues/extractedLists .get() only works for declared Deepline getters listed by `deepline describe <tool>`. Read tool-specific fields from `toolExecutionResult.toolResponse.rawV2` using the nesting shown in the response example, and use `toolExecutionResult.extractedLists.<name>.get()` for declared row/list outputs.";
|
|
5353
5353
|
var DATASET_API_HINT = "Deepline hint: PlayDataset is lazy, durable, and async-only. Use `.count()`, `.first()`, `.at(index)`, `.peek(n)`, `.materialize(limit)`, or async iteration; do not use `.length`, numeric indexing, spread, synchronous iteration, `.rows`, or `.toArray()`.";
|
|
5354
5354
|
var ROW_PROPERTY_HINT = "Deepline hint: this row type only contains fields produced by the CSV/schema and previous map steps. Check source column casing and the exact output field names from earlier steps before scaling.";
|
|
5355
|
-
var TOOLS_EXECUTE_SIGNATURE_HINT = "Deepline hint: ctx.tools.execute requires a request object: `ctx.tools.execute({ id, tool, input, description })`. The stable `id` is required for logs, metadata, and result-cache identity; terminal cache reuse is based on play, tool, semantic input, auth scope, provider action version, and cache policy.";
|
|
5355
|
+
var TOOLS_EXECUTE_SIGNATURE_HINT = "Deepline hint: ctx.tools.execute requires a request object: `ctx.tools.execute({ id, tool, input, description })`. The stable `id` is required for logs, metadata, and result-cache identity; terminal cache reuse is based on play, tool, semantic input, auth scope, provider action version, and cache policy. In authoring edition 11, also choose `staleAfterSeconds`: `0` for fresh logical work, a positive integer for the maximum reusable result age in seconds, or `null` for indefinite result reuse.";
|
|
5356
5356
|
var RUN_PLAY_SIGNATURE_HINT = "Deepline hint: ctx.runPlay uses a stable key plus a composable child play reference. Direct-run-only or dataset-backed batch plays must be run directly, exported, then consumed by a separate play.";
|
|
5357
5357
|
var MAP_BACKED_CHILD_HINT = "Deepline hint: dataset-backed child plays own durable table state and cannot be called from another play. Run that play directly, export its dataset, then pass the CSV to the next play.";
|
|
5358
5358
|
function sourceLineForError(sourceCode, error) {
|
|
@@ -6009,10 +6009,10 @@ function resolveOwnedPlayReferenceName(reference, ownerSlug) {
|
|
|
6009
6009
|
// ../plays/deploy/run-deployment.ts
|
|
6010
6010
|
var RUN_PLAY_METHOD_NAMES = /* @__PURE__ */ new Set(["runPlay", "runPlayAsync"]);
|
|
6011
6011
|
function isRunPlayReceiver(node) {
|
|
6012
|
-
return
|
|
6012
|
+
return _chunkMH73HMPVjs.isAstNode.call(void 0, node) && node.type === "Identifier" && typeof node.name === "string" && (node.name === "ctx" || node.name.endsWith("Ctx"));
|
|
6013
6013
|
}
|
|
6014
6014
|
function stringLiteralValue(node) {
|
|
6015
|
-
if (!
|
|
6015
|
+
if (!_chunkMH73HMPVjs.isAstNode.call(void 0, node)) return null;
|
|
6016
6016
|
if (node.type === "Literal" && typeof node.value === "string") {
|
|
6017
6017
|
return node.value;
|
|
6018
6018
|
}
|
|
@@ -6023,12 +6023,12 @@ function stringLiteralValue(node) {
|
|
|
6023
6023
|
return null;
|
|
6024
6024
|
}
|
|
6025
6025
|
async function extractRunPlayStringTargets(sourceCode) {
|
|
6026
|
-
const program =
|
|
6026
|
+
const program = _chunkMH73HMPVjs.parsePlaySourceForAnalysis.call(void 0, sourceCode);
|
|
6027
6027
|
if (!program) return await _asyncNullishCoalesce(await extractWithCompiler(sourceCode), async () => ( []));
|
|
6028
6028
|
const targets = /* @__PURE__ */ new Set();
|
|
6029
6029
|
const visit = (node) => {
|
|
6030
6030
|
const callee = node.callee;
|
|
6031
|
-
if (node.type === "CallExpression" &&
|
|
6031
|
+
if (node.type === "CallExpression" && _chunkMH73HMPVjs.isAstNode.call(void 0, callee) && callee.type === "MemberExpression" && callee.computed !== true && _chunkMH73HMPVjs.isAstNode.call(void 0, callee.property) && RUN_PLAY_METHOD_NAMES.has(String(callee.property.name)) && isRunPlayReceiver(callee.object) && Array.isArray(node.arguments)) {
|
|
6032
6032
|
const playRef = stringLiteralValue(node.arguments[1]);
|
|
6033
6033
|
const ownedName = playRef === null ? null : resolveOwnedPlayReferenceName(playRef);
|
|
6034
6034
|
if (ownedName) targets.add(ownedName);
|
|
@@ -6036,7 +6036,7 @@ async function extractRunPlayStringTargets(sourceCode) {
|
|
|
6036
6036
|
for (const [key, value] of Object.entries(node)) {
|
|
6037
6037
|
if (key === "loc") continue;
|
|
6038
6038
|
for (const child of Array.isArray(value) ? value : [value]) {
|
|
6039
|
-
if (
|
|
6039
|
+
if (_chunkMH73HMPVjs.isAstNode.call(void 0, child)) visit(child);
|
|
6040
6040
|
}
|
|
6041
6041
|
}
|
|
6042
6042
|
};
|
|
@@ -6902,7 +6902,7 @@ function renderOutcome(outcome) {
|
|
|
6902
6902
|
function printResult2(input) {
|
|
6903
6903
|
const failed = input.status === "failed" || input.status === "cancelled";
|
|
6904
6904
|
if (failed) process.exitCode = 1;
|
|
6905
|
-
|
|
6905
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
6906
6906
|
{
|
|
6907
6907
|
deployment: { ...input.deployment, status: input.status },
|
|
6908
6908
|
plays: input.outcomes,
|
|
@@ -6927,7 +6927,7 @@ async function handlePlaysDeploy(directory, options) {
|
|
|
6927
6927
|
const root = await _promises.realpath.call(void 0, _path.resolve.call(void 0, _nullishCoalesce(directory, () => ( ".")))).catch(() => {
|
|
6928
6928
|
throw new Error(`No such directory: ${_path.resolve.call(void 0, _nullishCoalesce(directory, () => ( ".")))}`);
|
|
6929
6929
|
});
|
|
6930
|
-
const { http, config } =
|
|
6930
|
+
const { http, config } = _chunkKGNTKMRGjs.getAuthedHttpClient.call(void 0, );
|
|
6931
6931
|
const deliveryId = `local:${_crypto.randomUUID.call(void 0, )}`;
|
|
6932
6932
|
const startDeployment = () => http.post("/api/v2/deployments", {
|
|
6933
6933
|
deliveryId,
|
|
@@ -6954,7 +6954,7 @@ async function handlePlaysDeploy(directory, options) {
|
|
|
6954
6954
|
},
|
|
6955
6955
|
{
|
|
6956
6956
|
bundle: bundleDeployPlayFile,
|
|
6957
|
-
fetchImpl:
|
|
6957
|
+
fetchImpl: _chunkCS6RAIVYjs.fetchWithDeploymentProtection,
|
|
6958
6958
|
// The plays are already here: "opening" the source is naming it.
|
|
6959
6959
|
openSource: async () => ({
|
|
6960
6960
|
open: async () => ({ repoRoot: root })
|
|
@@ -7522,7 +7522,7 @@ function parseInputFlagValue(raw) {
|
|
|
7522
7522
|
return raw;
|
|
7523
7523
|
}
|
|
7524
7524
|
function parsePlayRunOptions(args, initialInput = null) {
|
|
7525
|
-
const selection =
|
|
7525
|
+
const selection = _chunkKGNTKMRGjs.parseJsonFields.call(void 0, args, "run");
|
|
7526
7526
|
args = selection.args;
|
|
7527
7527
|
const usage2 = "Usage: deepline plays run <play-name> [--input '{...}'] [--run-id-file <path>] [--no-wait] [--tail-timeout-ms 30000] [--force] [--open] [--full] [--<input> value]\n deepline plays run <play-file.ts> [--input '{...}'] [--run-id-file <path>] [--no-wait] [--tail-timeout-ms 30000] [--force] [--open] [--full] [--<input> value]\n deepline plays run --file <play-file.ts> [--input '{...}'] [--profile <id>] [--run-id-file <path>] [--no-wait] [--tail-timeout-ms 30000] [--force] [--open] [--full] [--<input> value]\n deepline plays run --name <name> [--input '{...}'] [--profile <id>] [--live|--latest|--revision-id <id>] [--run-id-file <path>] [--no-wait] [--tail-timeout-ms 30000] [--force] [--open] [--json] [--full] [--<input> value]\n Runs use the Absurd CJS runtime.\n --header '<name>: <value>' may repeat; each is sent on every request for this run.\n Unknown --<input> value flags, such as --limit 5, are passed into play input.\nRun `deepline plays run --help` for idempotent call caching and ctx.dataset guidance.";
|
|
7528
7528
|
let filePath = null;
|
|
@@ -7534,7 +7534,7 @@ function parsePlayRunOptions(args, initialInput = null) {
|
|
|
7534
7534
|
let revisionSelector = null;
|
|
7535
7535
|
const watch = !args.includes("--no-wait");
|
|
7536
7536
|
const dryRun = args.includes("--dry-run");
|
|
7537
|
-
let jsonOutput = dryRun ?
|
|
7537
|
+
let jsonOutput = dryRun ? _chunkKGNTKMRGjs.argsWantJson.call(void 0, args) : watch ? args.includes("--json") : _chunkKGNTKMRGjs.argsWantJson.call(void 0, args);
|
|
7538
7538
|
const fullJson = args.includes("--full");
|
|
7539
7539
|
const force = args.includes("--force");
|
|
7540
7540
|
const forceToolRefresh = args.includes("--force-tool-refresh");
|
|
@@ -7597,7 +7597,7 @@ function parsePlayRunOptions(args, initialInput = null) {
|
|
|
7597
7597
|
"--log-level requires one of: debug, info, warn, error."
|
|
7598
7598
|
);
|
|
7599
7599
|
}
|
|
7600
|
-
const parsed =
|
|
7600
|
+
const parsed = _chunkE23BQ5SCjs.parseLogLevel.call(void 0, value);
|
|
7601
7601
|
if (!parsed) {
|
|
7602
7602
|
throw new Error(
|
|
7603
7603
|
`Unsupported --log-level ${JSON.stringify(value)}. Use debug, info, warn, or error.`
|
|
@@ -7634,7 +7634,7 @@ function parsePlayRunOptions(args, initialInput = null) {
|
|
|
7634
7634
|
throw new Error("--profile requires an execution profile id.");
|
|
7635
7635
|
}
|
|
7636
7636
|
profile = value.trim();
|
|
7637
|
-
|
|
7637
|
+
_chunkMH73HMPVjs.resolveEnabledExecutionProfile.call(void 0, profile);
|
|
7638
7638
|
index += 1;
|
|
7639
7639
|
continue;
|
|
7640
7640
|
}
|
|
@@ -7880,7 +7880,7 @@ function resolvePlayRunCliOptions(target, options, inputArgs = []) {
|
|
|
7880
7880
|
if (dryRun && resolvedTarget.kind !== "file")
|
|
7881
7881
|
throw new Error("--dry-run currently requires a local Play file.");
|
|
7882
7882
|
const profile = _nullishCoalesce(_optionalChain([stringOption, 'call', _237 => _237(options.profile, "--profile"), 'optionalAccess', _238 => _238.trim, 'call', _239 => _239()]), () => ( base.profile));
|
|
7883
|
-
if (profile !== null)
|
|
7883
|
+
if (profile !== null) _chunkMH73HMPVjs.resolveEnabledExecutionProfile.call(void 0, profile);
|
|
7884
7884
|
const countOption = (value, flag) => {
|
|
7885
7885
|
if (value === void 0) return void 0;
|
|
7886
7886
|
if (!/^[1-9]\d*$/.test(value))
|
|
@@ -7915,7 +7915,7 @@ function resolvePlayRunCliOptions(target, options, inputArgs = []) {
|
|
|
7915
7915
|
const hasExplicitLogLevel = options.logLevel !== void 0 || inputArgs.some(
|
|
7916
7916
|
(arg) => arg === "--log-level" || arg.startsWith("--log-level=")
|
|
7917
7917
|
);
|
|
7918
|
-
let logLevel = options.logLevel === void 0 ? base.logLevel :
|
|
7918
|
+
let logLevel = options.logLevel === void 0 ? base.logLevel : _chunkE23BQ5SCjs.parseLogLevel.call(void 0, options.logLevel);
|
|
7919
7919
|
if (!logLevel)
|
|
7920
7920
|
throw new Error("--log-level requires one of: debug, info, warn, error.");
|
|
7921
7921
|
const debugAlias = options.logs || options.debug === true || inputArgs.some(
|
|
@@ -7929,13 +7929,13 @@ function resolvePlayRunCliOptions(target, options, inputArgs = []) {
|
|
|
7929
7929
|
if (debugAlias || debugMapLatency && logLevel === "info")
|
|
7930
7930
|
logLevel = "debug";
|
|
7931
7931
|
const fullJson = _nullishCoalesce(options.full, () => ( base.fullJson));
|
|
7932
|
-
const jsonFields = options.json === void 0 ? base.jsonFields :
|
|
7933
|
-
[...fullJson ? ["--full"] : [], ...
|
|
7932
|
+
const jsonFields = options.json === void 0 ? base.jsonFields : _chunkKGNTKMRGjs.parseJsonFields.call(void 0,
|
|
7933
|
+
[...fullJson ? ["--full"] : [], ..._chunkKGNTKMRGjs.jsonFieldArgs.call(void 0, options.json)],
|
|
7934
7934
|
"run"
|
|
7935
7935
|
).fields;
|
|
7936
7936
|
const watch = options.wait === false ? false : base.watch;
|
|
7937
7937
|
const explicitJson = options.json !== void 0 ? options.json !== false : base.jsonOutput;
|
|
7938
|
-
const jsonOutput = dryRun || !watch ? explicitJson ||
|
|
7938
|
+
const jsonOutput = dryRun || !watch ? explicitJson || _chunkKGNTKMRGjs.argsWantJson.call(void 0, []) : explicitJson;
|
|
7939
7939
|
const verboseLogs = Boolean(
|
|
7940
7940
|
debugAlias || logLevel === "debug" || debugMapLatency
|
|
7941
7941
|
);
|
|
@@ -7982,7 +7982,7 @@ function playAuthoringGraphPath(parent, filePath) {
|
|
|
7982
7982
|
// src/cli/renderers/local-play-execution.ts
|
|
7983
7983
|
function renderLocalPlayExecutionPlan(plan, options = {}) {
|
|
7984
7984
|
if (options.dryRun) {
|
|
7985
|
-
|
|
7985
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, { dryRun: true, ...plan }, { json: options.json });
|
|
7986
7986
|
return;
|
|
7987
7987
|
}
|
|
7988
7988
|
process.stderr.write(`Local Play execution plan: ${JSON.stringify(plan)}
|
|
@@ -8529,7 +8529,7 @@ function buildMissingDefinePlayError(filePath) {
|
|
|
8529
8529
|
);
|
|
8530
8530
|
}
|
|
8531
8531
|
function extractPlayName(code, filePath) {
|
|
8532
|
-
const definedPlayName =
|
|
8532
|
+
const definedPlayName = _chunkMH73HMPVjs.extractDefinedPlayName.call(void 0, code);
|
|
8533
8533
|
if (definedPlayName) {
|
|
8534
8534
|
return definedPlayName;
|
|
8535
8535
|
}
|
|
@@ -8758,12 +8758,12 @@ function unresolvedPackagedFilesMessage(node) {
|
|
|
8758
8758
|
const details = node.unresolvedFileReferences.map((unresolved) => `${unresolved.sourceFragment}: ${unresolved.message}`).join("; ");
|
|
8759
8759
|
return `Failed to package local ctx.csv(...) files in ${node.filePath}: ${details}`;
|
|
8760
8760
|
}
|
|
8761
|
-
async function collectBundledPlayGraph(entryFile, profile = null, entryExportName =
|
|
8761
|
+
async function collectBundledPlayGraph(entryFile, profile = null, entryExportName = _chunkMH73HMPVjs.PLAY_DEFAULT_EXPORT, options = {}) {
|
|
8762
8762
|
const playBundler = await loadPlayBundler();
|
|
8763
8763
|
const nodes = /* @__PURE__ */ new Map();
|
|
8764
8764
|
const diagnostics = [];
|
|
8765
8765
|
const visited = /* @__PURE__ */ new Set();
|
|
8766
|
-
const artifactKind =
|
|
8766
|
+
const artifactKind = _chunkMH73HMPVjs.resolveEnabledExecutionProfile.call(void 0, profile).artifactKind;
|
|
8767
8767
|
const rootPath = normalizePlayPath(entryFile);
|
|
8768
8768
|
const visit = async (filePath) => {
|
|
8769
8769
|
const absolutePath = normalizePlayPath(filePath);
|
|
@@ -8772,7 +8772,7 @@ async function collectBundledPlayGraph(entryFile, profile = null, entryExportNam
|
|
|
8772
8772
|
const bundleResult = await playBundler.bundlePlayFile(absolutePath, {
|
|
8773
8773
|
target: artifactKind,
|
|
8774
8774
|
...options.cache === false ? { cache: false } : {},
|
|
8775
|
-
...absolutePath === rootPath && entryExportName !==
|
|
8775
|
+
...absolutePath === rootPath && entryExportName !== _chunkMH73HMPVjs.PLAY_DEFAULT_EXPORT ? { exportName: entryExportName } : {}
|
|
8776
8776
|
});
|
|
8777
8777
|
if (bundleResult.success === false) {
|
|
8778
8778
|
diagnostics.push(
|
|
@@ -8946,7 +8946,7 @@ function playStatusErrorText(status) {
|
|
|
8946
8946
|
function isRetryablePendingStartFailure(status) {
|
|
8947
8947
|
if (status.status !== "failed") return false;
|
|
8948
8948
|
if (status.runId && status.runId !== "pending") return false;
|
|
8949
|
-
return
|
|
8949
|
+
return _chunkE23BQ5SCjs.isTransientPlayRunReadError.call(void 0, new Error(playStatusErrorText(status)));
|
|
8950
8950
|
}
|
|
8951
8951
|
function pendingStartFailureStatus(input) {
|
|
8952
8952
|
const message = input.error instanceof Error ? input.error.message : String(input.error);
|
|
@@ -8973,13 +8973,13 @@ var PLAY_PROGRESS_HEARTBEAT_INTERVAL_MS = 15e3;
|
|
|
8973
8973
|
var PLAY_STATUS_HEARTBEAT_INTERVAL_MS = 15e3;
|
|
8974
8974
|
function watchSurfaceReaches(state, provenance, level) {
|
|
8975
8975
|
const minimumLevel = _nullishCoalesce(state.logLevel, () => ( (state.verbose ? "debug" : "info")));
|
|
8976
|
-
if (!
|
|
8976
|
+
if (!_chunkE23BQ5SCjs.logLevelReaches.call(void 0, level, minimumLevel)) {
|
|
8977
8977
|
return false;
|
|
8978
8978
|
}
|
|
8979
|
-
if (
|
|
8979
|
+
if (_chunkE23BQ5SCjs.logProvenanceReaches.call(void 0, provenance, "watch")) {
|
|
8980
8980
|
return true;
|
|
8981
8981
|
}
|
|
8982
|
-
return state.verbose === true &&
|
|
8982
|
+
return state.verbose === true && _chunkE23BQ5SCjs.logProvenanceReaches.call(void 0, provenance, "debug");
|
|
8983
8983
|
}
|
|
8984
8984
|
function getEventPayload(event) {
|
|
8985
8985
|
return event.payload && typeof event.payload === "object" ? event.payload : {};
|
|
@@ -9486,7 +9486,7 @@ function resolveRunPlayName(status, runId) {
|
|
|
9486
9486
|
}
|
|
9487
9487
|
function openPlayDashboard(dashboardUrl, open2) {
|
|
9488
9488
|
if (open2 && dashboardUrl) {
|
|
9489
|
-
|
|
9489
|
+
_chunkKGNTKMRGjs.openInBrowser.call(void 0, dashboardUrl);
|
|
9490
9490
|
}
|
|
9491
9491
|
}
|
|
9492
9492
|
function printPlayLogLines(input) {
|
|
@@ -9548,7 +9548,7 @@ async function waitForPlayCompletionByWatch(input) {
|
|
|
9548
9548
|
billing: false
|
|
9549
9549
|
});
|
|
9550
9550
|
} catch (error) {
|
|
9551
|
-
if (
|
|
9551
|
+
if (_chunkE23BQ5SCjs.isTransientPlayRunReadError.call(void 0, error) || isAdmittedRunVisibilityDelay(error)) {
|
|
9552
9552
|
return null;
|
|
9553
9553
|
}
|
|
9554
9554
|
throw error;
|
|
@@ -9746,7 +9746,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9746
9746
|
billing: false
|
|
9747
9747
|
});
|
|
9748
9748
|
} catch (error) {
|
|
9749
|
-
if (
|
|
9749
|
+
if (_chunkE23BQ5SCjs.isTransientPlayRunReadError.call(void 0, error)) {
|
|
9750
9750
|
return null;
|
|
9751
9751
|
}
|
|
9752
9752
|
throw error;
|
|
@@ -9954,7 +9954,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9954
9954
|
lastPhase
|
|
9955
9955
|
});
|
|
9956
9956
|
}
|
|
9957
|
-
if (lastKnownWorkflowId &&
|
|
9957
|
+
if (lastKnownWorkflowId && _chunkE23BQ5SCjs.isTransientPlayRunReadError.call(void 0, error)) {
|
|
9958
9958
|
if (timeout) {
|
|
9959
9959
|
clearTimeout(timeout);
|
|
9960
9960
|
}
|
|
@@ -9990,7 +9990,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9990
9990
|
onRunAdmitted: confirmAdmission
|
|
9991
9991
|
});
|
|
9992
9992
|
}
|
|
9993
|
-
if (!lastKnownWorkflowId &&
|
|
9993
|
+
if (!lastKnownWorkflowId && _chunkE23BQ5SCjs.isTransientPlayRunReadError.call(void 0, error)) {
|
|
9994
9994
|
_chunkAYHLUHE5js.recordCliTrace.call(void 0, {
|
|
9995
9995
|
phase: "cli.play_start_stream_transient_failure",
|
|
9996
9996
|
ms: Date.now() - startedAt,
|
|
@@ -10089,7 +10089,7 @@ var BULKY_RETURN_KEYS = /* @__PURE__ */ new Set([
|
|
|
10089
10089
|
"logs"
|
|
10090
10090
|
]);
|
|
10091
10091
|
function formatPlayLogLine(rawLine, state) {
|
|
10092
|
-
const classified =
|
|
10092
|
+
const classified = _chunkE23BQ5SCjs.classifyLogLine.call(void 0, rawLine);
|
|
10093
10093
|
const line = classified.line;
|
|
10094
10094
|
const timestampMatch = line.match(/^\[([^\]]+)\]\s*(.*)$/);
|
|
10095
10095
|
const parsedTimestamp = _optionalChain([timestampMatch, 'optionalAccess', _317 => _317[1]]) ? new Date(timestampMatch[1]) : null;
|
|
@@ -10104,14 +10104,14 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
10104
10104
|
if (!state.verbose && isProviderRowWaitLogLine(line)) return null;
|
|
10105
10105
|
const providerWait = formatProviderCapacityWaitLogLine(line);
|
|
10106
10106
|
if (providerWait && !state.verbose) {
|
|
10107
|
-
return
|
|
10107
|
+
return _chunkE23BQ5SCjs.logLevelReaches.call(void 0, "warn", _nullishCoalesce(state.logLevel, () => ( "info"))) ? `${prefix}${providerWait}` : null;
|
|
10108
10108
|
}
|
|
10109
10109
|
const mapProgress = formatMapProgressDiagnosticLogLine(line);
|
|
10110
10110
|
if (mapProgress && !state.verbose) {
|
|
10111
|
-
return
|
|
10111
|
+
return _chunkE23BQ5SCjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info"))) ? `${prefix}${mapProgress}` : null;
|
|
10112
10112
|
}
|
|
10113
10113
|
if (/\[worker\] picked up run\b/.test(message)) {
|
|
10114
|
-
if (!
|
|
10114
|
+
if (!_chunkE23BQ5SCjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
10115
10115
|
return null;
|
|
10116
10116
|
}
|
|
10117
10117
|
if (state.emittedRunnerStarted) {
|
|
@@ -10124,7 +10124,7 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
10124
10124
|
/^Starting map over (\d+) items with (\d+) fields \(key: ([^;]+); (\d+) already satisfied; (\d+) pending\)$/
|
|
10125
10125
|
);
|
|
10126
10126
|
if (mapStart) {
|
|
10127
|
-
if (!
|
|
10127
|
+
if (!_chunkE23BQ5SCjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
10128
10128
|
return null;
|
|
10129
10129
|
}
|
|
10130
10130
|
const [, rows, fields2, namespace, cached, pending] = mapStart;
|
|
@@ -10134,7 +10134,7 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
10134
10134
|
/^Map completed: (\d+) results \((\d+) executed, (\d+) already satisfied\)$/
|
|
10135
10135
|
);
|
|
10136
10136
|
if (mapDone) {
|
|
10137
|
-
if (!
|
|
10137
|
+
if (!_chunkE23BQ5SCjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
10138
10138
|
return null;
|
|
10139
10139
|
}
|
|
10140
10140
|
const [, results, executed, cached] = mapDone;
|
|
@@ -11421,7 +11421,7 @@ function formatRecentRunLogLines(value) {
|
|
|
11421
11421
|
(line) => typeof line === "string"
|
|
11422
11422
|
);
|
|
11423
11423
|
if (tail.length === 0) return [];
|
|
11424
|
-
const shown = tail.map((line) =>
|
|
11424
|
+
const shown = tail.map((line) => _chunkE23BQ5SCjs.classifyLogLine.call(void 0, line)).filter(
|
|
11425
11425
|
(entry) => entry.level !== "debug" && !isProviderRowWaitLogLine(entry.line)
|
|
11426
11426
|
).slice(-8);
|
|
11427
11427
|
const total = readNonNegativeInteger(logs.totalCount);
|
|
@@ -11704,7 +11704,7 @@ function writePlayResult(status, jsonOutput, options) {
|
|
|
11704
11704
|
const hits = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _398 => _398.hits]), () => ( null));
|
|
11705
11705
|
if (jsonOutput) {
|
|
11706
11706
|
const payload2 = _optionalChain([options, 'optionalAccess', _399 => _399.fullJson]) ? status.package ? buildRunOverview(status, status) : { ...buildRunLaunch(status), diagnostics: status } : buildRunLaunch(status);
|
|
11707
|
-
|
|
11707
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
11708
11708
|
hits ? { ...payload2, hits } : payload2,
|
|
11709
11709
|
{ json: true, fields: _optionalChain([options, 'optionalAccess', _400 => _400.jsonFields]) }
|
|
11710
11710
|
);
|
|
@@ -11720,7 +11720,7 @@ function writePlayResult(status, jsonOutput, options) {
|
|
|
11720
11720
|
...buildPlayCompletionTextLines(status),
|
|
11721
11721
|
...formatRunHitsLines(hits)
|
|
11722
11722
|
];
|
|
11723
|
-
|
|
11723
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, displayPackage, {
|
|
11724
11724
|
json: false,
|
|
11725
11725
|
text: `${lines2.join("\n")}
|
|
11726
11726
|
`
|
|
@@ -11771,7 +11771,7 @@ function writePlayResult(status, jsonOutput, options) {
|
|
|
11771
11771
|
lines.push(...buildBillingRollupTextLines(status));
|
|
11772
11772
|
const compact = compactPlayStatus(status);
|
|
11773
11773
|
const payload = _optionalChain([options, 'optionalAccess', _402 => _402.fullJson]) ? status : compact;
|
|
11774
|
-
|
|
11774
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
11775
11775
|
{
|
|
11776
11776
|
...payload,
|
|
11777
11777
|
render: {
|
|
@@ -12541,7 +12541,7 @@ function writeStartedPlayRun(input) {
|
|
|
12541
12541
|
dashboardUrl: input.dashboardUrl,
|
|
12542
12542
|
package: input.package
|
|
12543
12543
|
};
|
|
12544
|
-
|
|
12544
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, buildRunLaunch(status), {
|
|
12545
12545
|
json: true,
|
|
12546
12546
|
fields: input.jsonFields
|
|
12547
12547
|
});
|
|
@@ -12563,7 +12563,7 @@ function writeStartedPlayRun(input) {
|
|
|
12563
12563
|
input.progress.writeLine(output2, process.stdout);
|
|
12564
12564
|
return;
|
|
12565
12565
|
}
|
|
12566
|
-
|
|
12566
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, input.package, {
|
|
12567
12567
|
json: false,
|
|
12568
12568
|
text: `${output2}
|
|
12569
12569
|
`
|
|
@@ -12592,7 +12592,7 @@ function writeStartedPlayRun(input) {
|
|
|
12592
12592
|
) ? [`Stop: deepline runs stop ${_chunkAID3OYVJjs.shellQuote.call(void 0, input.runId)}`] : []
|
|
12593
12593
|
];
|
|
12594
12594
|
if (input.jsonOutput) {
|
|
12595
|
-
|
|
12595
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, payload, { json: true, fields: input.jsonFields });
|
|
12596
12596
|
return;
|
|
12597
12597
|
}
|
|
12598
12598
|
if (input.dashboardUrl) {
|
|
@@ -12603,7 +12603,7 @@ function writeStartedPlayRun(input) {
|
|
|
12603
12603
|
input.progress.writeLine(output, process.stdout);
|
|
12604
12604
|
return;
|
|
12605
12605
|
}
|
|
12606
|
-
|
|
12606
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
12607
12607
|
{
|
|
12608
12608
|
...payload,
|
|
12609
12609
|
render: { sections: [{ title: "play run", lines }] }
|
|
@@ -12613,7 +12613,7 @@ function writeStartedPlayRun(input) {
|
|
|
12613
12613
|
);
|
|
12614
12614
|
}
|
|
12615
12615
|
function parsePlayCheckOptions(args) {
|
|
12616
|
-
const selection =
|
|
12616
|
+
const selection = _chunkKGNTKMRGjs.parseJsonFields.call(void 0, args, "check");
|
|
12617
12617
|
args = selection.args;
|
|
12618
12618
|
const target = args[0];
|
|
12619
12619
|
if (!target || target.startsWith("-")) {
|
|
@@ -12625,7 +12625,7 @@ function parsePlayCheckOptions(args) {
|
|
|
12625
12625
|
if (arg !== "--json" && arg !== "--full")
|
|
12626
12626
|
throw new Error(`Unknown plays check option: ${arg}`);
|
|
12627
12627
|
}
|
|
12628
|
-
const jsonOutput =
|
|
12628
|
+
const jsonOutput = _chunkKGNTKMRGjs.argsWantJson.call(void 0, args);
|
|
12629
12629
|
return {
|
|
12630
12630
|
target,
|
|
12631
12631
|
jsonOutput,
|
|
@@ -12701,7 +12701,7 @@ ${PLAY_PUBLISH_USAGE}`
|
|
|
12701
12701
|
useLatest,
|
|
12702
12702
|
expectedArtifactHash,
|
|
12703
12703
|
dryRun,
|
|
12704
|
-
jsonOutput:
|
|
12704
|
+
jsonOutput: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args)
|
|
12705
12705
|
};
|
|
12706
12706
|
}
|
|
12707
12707
|
var PLAY_SAVE_USAGE = "Usage: deepline plays save <play-file.ts> [--expected-artifact <hash>] [--dry-run] [--json]";
|
|
@@ -12742,7 +12742,7 @@ ${PLAY_SAVE_USAGE}`);
|
|
|
12742
12742
|
target,
|
|
12743
12743
|
expectedArtifactHash,
|
|
12744
12744
|
dryRun,
|
|
12745
|
-
jsonOutput:
|
|
12745
|
+
jsonOutput: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args)
|
|
12746
12746
|
};
|
|
12747
12747
|
}
|
|
12748
12748
|
function printScheduledPlayCapacity(capacity) {
|
|
@@ -12953,7 +12953,7 @@ function printBundledRuntimeWarning(bundle) {
|
|
|
12953
12953
|
async function handlePlayCheck(args) {
|
|
12954
12954
|
const options = parsePlayCheckOptions(args);
|
|
12955
12955
|
if (!isFileTarget2(options.target)) {
|
|
12956
|
-
const client = new (0,
|
|
12956
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
12957
12957
|
try {
|
|
12958
12958
|
await assertCanonicalNamedPlayReference(client, options.target, {
|
|
12959
12959
|
command: "check"
|
|
@@ -12982,7 +12982,7 @@ async function handlePlayCheck(args) {
|
|
|
12982
12982
|
},
|
|
12983
12983
|
...options.full ? { diagnostics: { staticPipeline: _nullishCoalesce(play.staticPipeline, () => ( null)) } } : {}
|
|
12984
12984
|
};
|
|
12985
|
-
|
|
12985
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, result, {
|
|
12986
12986
|
json: options.jsonOutput,
|
|
12987
12987
|
fields: options.jsonFields,
|
|
12988
12988
|
text: renderPlayCheckOutput(result) + "\n"
|
|
@@ -12992,7 +12992,7 @@ async function handlePlayCheck(args) {
|
|
|
12992
12992
|
const resolved = _path.resolve.call(void 0, options.target);
|
|
12993
12993
|
const message = error instanceof Error && error.message ? error.message : `File not found: ${resolved}`;
|
|
12994
12994
|
if (options.jsonOutput) {
|
|
12995
|
-
|
|
12995
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
12996
12996
|
{
|
|
12997
12997
|
kind: "play_check",
|
|
12998
12998
|
checked: "named_contract",
|
|
@@ -13025,7 +13025,7 @@ async function handlePlayCheck(args) {
|
|
|
13025
13025
|
);
|
|
13026
13026
|
}
|
|
13027
13027
|
const primary = outcomes.find(
|
|
13028
|
-
(outcome) => outcome.exportName ===
|
|
13028
|
+
(outcome) => outcome.exportName === _chunkMH73HMPVjs.PLAY_DEFAULT_EXPORT
|
|
13029
13029
|
);
|
|
13030
13030
|
const output = buildPlayCheckOutput({
|
|
13031
13031
|
outcomes,
|
|
@@ -13034,7 +13034,7 @@ async function handlePlayCheck(args) {
|
|
|
13034
13034
|
detailsCommand: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.target)} --full`,
|
|
13035
13035
|
publishCommand: _optionalChain([primary, 'optionalAccess', _449 => _449.result, 'access', _450 => _450.artifactHash]) ? `deepline plays publish ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.target)} --expected-artifact ${primary.result.artifactHash}` : void 0
|
|
13036
13036
|
});
|
|
13037
|
-
|
|
13037
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, output, {
|
|
13038
13038
|
json: options.jsonOutput,
|
|
13039
13039
|
fields: options.jsonFields,
|
|
13040
13040
|
text: renderPlayCheckOutput(output) + "\n"
|
|
@@ -13042,8 +13042,8 @@ async function handlePlayCheck(args) {
|
|
|
13042
13042
|
return output.valid ? 0 : 1;
|
|
13043
13043
|
}
|
|
13044
13044
|
function resolvePlayCheckExportNames(sourceCode) {
|
|
13045
|
-
const exports =
|
|
13046
|
-
if (!exports || exports.length === 0) return [
|
|
13045
|
+
const exports = _chunkMH73HMPVjs.listPlayFileExports.call(void 0, sourceCode);
|
|
13046
|
+
if (!exports || exports.length === 0) return [_chunkMH73HMPVjs.PLAY_DEFAULT_EXPORT];
|
|
13047
13047
|
return exports.map((entry) => entry.name);
|
|
13048
13048
|
}
|
|
13049
13049
|
function artifactForProductionCompatibilityCheck(artifact) {
|
|
@@ -13088,7 +13088,7 @@ async function checkOneExportedPlay(input) {
|
|
|
13088
13088
|
}
|
|
13089
13089
|
const playName = _nullishCoalesce(graph.root.playName, () => ( fallbackName));
|
|
13090
13090
|
const authoringErrors = collectPlayGraphAuthoringErrors(graph);
|
|
13091
|
-
const client = new (0,
|
|
13091
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
13092
13092
|
const integrationMode = resolveEvalIntegrationMode();
|
|
13093
13093
|
const importedPlays = [...graph.nodes.values()].filter((node) => node.filePath !== graph.root.filePath).map((node) => ({
|
|
13094
13094
|
playName: node.playName,
|
|
@@ -13101,7 +13101,7 @@ async function checkOneExportedPlay(input) {
|
|
|
13101
13101
|
sourceFiles: graph.root.sourceFiles,
|
|
13102
13102
|
description: _nullishCoalesce(graph.root.playDescription, () => ( void 0)),
|
|
13103
13103
|
artifact: artifactForProductionCompatibilityCheck(graph.root.artifact),
|
|
13104
|
-
...exportName ===
|
|
13104
|
+
...exportName === _chunkMH73HMPVjs.PLAY_DEFAULT_EXPORT ? {} : { exportName },
|
|
13105
13105
|
...importedPlays.length > 0 ? { importedPlays } : {},
|
|
13106
13106
|
...integrationMode ? { integrationMode } : {}
|
|
13107
13107
|
});
|
|
@@ -13152,7 +13152,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
13152
13152
|
() => collectBundledPlayGraph(
|
|
13153
13153
|
absolutePlayPath,
|
|
13154
13154
|
options.profile,
|
|
13155
|
-
|
|
13155
|
+
_chunkMH73HMPVjs.PLAY_DEFAULT_EXPORT,
|
|
13156
13156
|
{ cache: !options.dryRun }
|
|
13157
13157
|
)
|
|
13158
13158
|
);
|
|
@@ -13165,7 +13165,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
13165
13165
|
);
|
|
13166
13166
|
return 0;
|
|
13167
13167
|
}
|
|
13168
|
-
client = new (0,
|
|
13168
|
+
client = new (0, _chunkE23BQ5SCjs.DeeplineClient)(playRunClientOptions(options));
|
|
13169
13169
|
const canDeferCompilerManifest = graph.root.importedPlayDependencies.length === 0 && !sourceGraphMentionsRunPlay(graph.root) && !inputContainsLocalFilePath(runtimeInput);
|
|
13170
13170
|
if (canDeferCompilerManifest) {
|
|
13171
13171
|
_chunkAYHLUHE5js.recordCliTrace.call(void 0, {
|
|
@@ -13364,7 +13364,7 @@ async function handleNamedRun(options, hooks) {
|
|
|
13364
13364
|
if (options.target.kind !== "name") {
|
|
13365
13365
|
throw new Error("Expected a named play run target.");
|
|
13366
13366
|
}
|
|
13367
|
-
const client = new (0,
|
|
13367
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)(playRunClientOptions(options));
|
|
13368
13368
|
const progress = _nullishCoalesce(_chunkWJYPBHTEjs.getActiveCliProgress.call(void 0, ), () => ( _chunkWJYPBHTEjs.createCliProgress.call(void 0, !options.jsonOutput)));
|
|
13369
13369
|
const playName = options.target.name;
|
|
13370
13370
|
const runtimeInput = options.input ? { ...options.input } : {};
|
|
@@ -13561,7 +13561,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
13561
13561
|
JSON.stringify({
|
|
13562
13562
|
version: 1,
|
|
13563
13563
|
admissionState: "submitted_unknown",
|
|
13564
|
-
baseUrl: new (0,
|
|
13564
|
+
baseUrl: new (0, _chunkE23BQ5SCjs.DeeplineClient)().baseUrl,
|
|
13565
13565
|
...intent
|
|
13566
13566
|
})
|
|
13567
13567
|
);
|
|
@@ -13790,10 +13790,10 @@ function renderRunOverviewText(overview, extras = {}) {
|
|
|
13790
13790
|
);
|
|
13791
13791
|
return `${lines.join("\n")}
|
|
13792
13792
|
|
|
13793
|
-
${
|
|
13793
|
+
${_chunkKGNTKMRGjs.renderCommandEnvelopeText.call(void 0, { render: { sections, actions: actions2 } })}`;
|
|
13794
13794
|
}
|
|
13795
13795
|
async function handleRunGet(args) {
|
|
13796
|
-
const selection =
|
|
13796
|
+
const selection = _chunkKGNTKMRGjs.parseJsonFields.call(void 0,
|
|
13797
13797
|
args,
|
|
13798
13798
|
args.includes("--config") ? "config" : "get"
|
|
13799
13799
|
);
|
|
@@ -13806,7 +13806,7 @@ async function handleRunGet(args) {
|
|
|
13806
13806
|
console.error(error instanceof Error ? error.message : usage2);
|
|
13807
13807
|
return 1;
|
|
13808
13808
|
}
|
|
13809
|
-
const client = new (0,
|
|
13809
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
13810
13810
|
if (args.includes("--web-url")) {
|
|
13811
13811
|
const status2 = await client.runs.get(runId, { full: false });
|
|
13812
13812
|
const playName2 = resolveRunPlayName(status2, runId);
|
|
@@ -13815,7 +13815,7 @@ async function handleRunGet(args) {
|
|
|
13815
13815
|
return 1;
|
|
13816
13816
|
}
|
|
13817
13817
|
const dashboardUrl2 = buildPlayDashboardUrl(client.baseUrl, playName2);
|
|
13818
|
-
|
|
13818
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
13819
13819
|
{ dashboardUrl: dashboardUrl2 },
|
|
13820
13820
|
{ json: args.includes("--json"), text: `${dashboardUrl2}
|
|
13821
13821
|
` }
|
|
@@ -13835,7 +13835,7 @@ async function handleRunGet(args) {
|
|
|
13835
13835
|
"This server does not support recorded configuration reads."
|
|
13836
13836
|
);
|
|
13837
13837
|
}
|
|
13838
|
-
|
|
13838
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
13839
13839
|
{ runId, contract: _nullishCoalesce(status2.contract, () => ( null)) },
|
|
13840
13840
|
{ json: true, fields: selection.fields }
|
|
13841
13841
|
);
|
|
@@ -13843,7 +13843,7 @@ async function handleRunGet(args) {
|
|
|
13843
13843
|
}
|
|
13844
13844
|
if (args.includes("--input")) {
|
|
13845
13845
|
const input = await client.getRunInput(runId);
|
|
13846
|
-
|
|
13846
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, input, { json: true });
|
|
13847
13847
|
return 0;
|
|
13848
13848
|
}
|
|
13849
13849
|
const full = args.includes("--full");
|
|
@@ -13859,8 +13859,8 @@ async function handleRunGet(args) {
|
|
|
13859
13859
|
}) : status;
|
|
13860
13860
|
const legacyPlayName = resolveRunPlayName(legacyStatus, runId);
|
|
13861
13861
|
const legacyDashboardUrl = legacyPlayName ? buildPlayDashboardUrl(client.baseUrl, legacyPlayName) : null;
|
|
13862
|
-
if (
|
|
13863
|
-
|
|
13862
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
13863
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
13864
13864
|
{
|
|
13865
13865
|
...full ? legacyStatus : compactPlayStatus(legacyStatus),
|
|
13866
13866
|
...legacyDashboardUrl ? { dashboardUrl: legacyDashboardUrl } : {}
|
|
@@ -13870,7 +13870,7 @@ async function handleRunGet(args) {
|
|
|
13870
13870
|
} else {
|
|
13871
13871
|
writePlayResult(legacyStatus, false, { fullJson: full });
|
|
13872
13872
|
if (legacyDashboardUrl)
|
|
13873
|
-
|
|
13873
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
13874
13874
|
{ dashboardUrl: legacyDashboardUrl },
|
|
13875
13875
|
{ json: false, text: `play page: ${legacyDashboardUrl}
|
|
13876
13876
|
` }
|
|
@@ -13885,10 +13885,10 @@ async function handleRunGet(args) {
|
|
|
13885
13885
|
readRunCredits(client, runId, !TERMINAL_PLAY_STATUSES.has(status.status))
|
|
13886
13886
|
]);
|
|
13887
13887
|
const hitLines = formatRunHitsLines(hits);
|
|
13888
|
-
const json =
|
|
13888
|
+
const json = _chunkKGNTKMRGjs.argsWantJson.call(void 0, args);
|
|
13889
13889
|
const playName = resolveRunPlayName(status, runId);
|
|
13890
13890
|
const dashboardUrl = playName ? buildPlayDashboardUrl(client.baseUrl, playName) : void 0;
|
|
13891
|
-
|
|
13891
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
13892
13892
|
{
|
|
13893
13893
|
...overview,
|
|
13894
13894
|
...dashboardUrl ? { dashboardUrl } : {},
|
|
@@ -13992,9 +13992,9 @@ async function handleRunLifecycleStatus(args) {
|
|
|
13992
13992
|
console.error(error instanceof Error ? error.message : usage2);
|
|
13993
13993
|
return 1;
|
|
13994
13994
|
}
|
|
13995
|
-
const status = await new (0,
|
|
13996
|
-
if (
|
|
13997
|
-
|
|
13995
|
+
const status = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().runs.status(runId);
|
|
13996
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
13997
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, status, { json: true });
|
|
13998
13998
|
return 0;
|
|
13999
13999
|
}
|
|
14000
14000
|
if (!status.available) {
|
|
@@ -14034,7 +14034,7 @@ async function handleRunsRerun(args) {
|
|
|
14034
14034
|
console.error(error instanceof Error ? error.message : usage2);
|
|
14035
14035
|
return 1;
|
|
14036
14036
|
}
|
|
14037
|
-
const options = { json:
|
|
14037
|
+
const options = { json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args) };
|
|
14038
14038
|
for (let index = 0; index < args.length; index += 1) {
|
|
14039
14039
|
if (args[index] === "--idempotency-key") {
|
|
14040
14040
|
options.idempotencyKey = _nullishCoalesce(args[++index], () => ( ""));
|
|
@@ -14099,8 +14099,8 @@ ${usage2}
|
|
|
14099
14099
|
Discover Plays: ${next.discover}
|
|
14100
14100
|
Active runs: ${next.running}`
|
|
14101
14101
|
);
|
|
14102
|
-
if (
|
|
14103
|
-
|
|
14102
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
14103
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14104
14104
|
{ ok: false, exitCode: 1, code: "RUN_FILTER_REQUIRED", message, next },
|
|
14105
14105
|
{ json: true }
|
|
14106
14106
|
);
|
|
@@ -14115,7 +14115,7 @@ Active runs: ${next.running}`
|
|
|
14115
14115
|
console.error("--offset requires --play.");
|
|
14116
14116
|
return 1;
|
|
14117
14117
|
}
|
|
14118
|
-
const client = new (0,
|
|
14118
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
14119
14119
|
const page = await client.runs.listPage({
|
|
14120
14120
|
...playName ? { play: playName } : {},
|
|
14121
14121
|
...statusFilter ? { status: statusFilter } : {},
|
|
@@ -14184,7 +14184,7 @@ Active runs: ${next.running}`
|
|
|
14184
14184
|
nextPage ? `Next page: ${nextPage}` : "Narrow with --play <play-name> to page through runs."
|
|
14185
14185
|
);
|
|
14186
14186
|
}
|
|
14187
|
-
|
|
14187
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14188
14188
|
{
|
|
14189
14189
|
runs,
|
|
14190
14190
|
count: runs.length,
|
|
@@ -14198,7 +14198,7 @@ Active runs: ${next.running}`
|
|
|
14198
14198
|
},
|
|
14199
14199
|
render: { sections: [{ title: "runs", lines }] }
|
|
14200
14200
|
},
|
|
14201
|
-
{ json:
|
|
14201
|
+
{ json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args) }
|
|
14202
14202
|
);
|
|
14203
14203
|
return 0;
|
|
14204
14204
|
}
|
|
@@ -14228,7 +14228,7 @@ async function handleRunTail(args) {
|
|
|
14228
14228
|
console.error("--log-level requires one of: debug, info, warn, error.");
|
|
14229
14229
|
return 1;
|
|
14230
14230
|
}
|
|
14231
|
-
const parsed =
|
|
14231
|
+
const parsed = _chunkE23BQ5SCjs.parseLogLevel.call(void 0, value);
|
|
14232
14232
|
if (!parsed) {
|
|
14233
14233
|
console.error(
|
|
14234
14234
|
`Unsupported --log-level ${JSON.stringify(value)}. Use debug, info, warn, or error.`
|
|
@@ -14266,9 +14266,9 @@ async function handleRunTail(args) {
|
|
|
14266
14266
|
);
|
|
14267
14267
|
return 1;
|
|
14268
14268
|
}
|
|
14269
|
-
const client = new (0,
|
|
14269
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
14270
14270
|
const jsonLines = args.includes("--jsonl");
|
|
14271
|
-
const jsonOutput = !jsonLines &&
|
|
14271
|
+
const jsonOutput = !jsonLines && _chunkKGNTKMRGjs.argsWantJson.call(void 0, args);
|
|
14272
14272
|
const compact = args.includes("--compact");
|
|
14273
14273
|
const showLiveLogs = debug || hasExplicitLogLevel || !jsonOutput && !compact;
|
|
14274
14274
|
const compactState = {
|
|
@@ -14349,7 +14349,7 @@ async function handleRunLogs(args) {
|
|
|
14349
14349
|
]);
|
|
14350
14350
|
const cursorIndex = args.indexOf("--cursor");
|
|
14351
14351
|
const cursorValue = cursorIndex >= 0 ? args[cursorIndex + 1] : void 0;
|
|
14352
|
-
const continuesEventSearch = cursorIndex >= 0 && !(cursorValue &&
|
|
14352
|
+
const continuesEventSearch = cursorIndex >= 0 && !(cursorValue && _chunkE23BQ5SCjs.isRunLogsCursor.call(void 0, cursorValue));
|
|
14353
14353
|
if (!args[0] || args[0].startsWith("--") || continuesEventSearch || args.some((arg) => searchFlags.has(arg))) {
|
|
14354
14354
|
return handleRunEventSearch(args);
|
|
14355
14355
|
}
|
|
@@ -14383,7 +14383,7 @@ async function handleRunLogs(args) {
|
|
|
14383
14383
|
console.error("--log-level requires one of: debug, info, warn, error.");
|
|
14384
14384
|
return 1;
|
|
14385
14385
|
}
|
|
14386
|
-
const parsed =
|
|
14386
|
+
const parsed = _chunkE23BQ5SCjs.parseLogLevel.call(void 0, value);
|
|
14387
14387
|
if (!parsed) {
|
|
14388
14388
|
console.error(
|
|
14389
14389
|
`Unsupported --log-level ${JSON.stringify(value)}. Use debug, info, warn, or error.`
|
|
@@ -14430,12 +14430,12 @@ async function handleRunLogs(args) {
|
|
|
14430
14430
|
);
|
|
14431
14431
|
return 1;
|
|
14432
14432
|
}
|
|
14433
|
-
const client = new (0,
|
|
14433
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
14434
14434
|
if (outPath) {
|
|
14435
14435
|
const result2 = await client.runs.logs(runId, { all: true });
|
|
14436
|
-
const logs = result2.entries.filter((line) =>
|
|
14436
|
+
const logs = result2.entries.filter((line) => _chunkE23BQ5SCjs.logLevelReaches.call(void 0, _chunkE23BQ5SCjs.classifyLogLine.call(void 0, line).level, logLevel)).map((line) => _chunkE23BQ5SCjs.classifyLogLine.call(void 0, line).line);
|
|
14437
14437
|
_fs.writeFileSync.call(void 0, outPath, `${logs.join("\n")}${logs.length > 0 ? "\n" : ""}`);
|
|
14438
|
-
|
|
14438
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14439
14439
|
{
|
|
14440
14440
|
runId: result2.runId,
|
|
14441
14441
|
log_path: outPath,
|
|
@@ -14458,7 +14458,7 @@ async function handleRunLogs(args) {
|
|
|
14458
14458
|
]
|
|
14459
14459
|
}
|
|
14460
14460
|
},
|
|
14461
|
-
{ json:
|
|
14461
|
+
{ json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args) }
|
|
14462
14462
|
);
|
|
14463
14463
|
return 0;
|
|
14464
14464
|
}
|
|
@@ -14489,7 +14489,7 @@ async function handleRunLogs(args) {
|
|
|
14489
14489
|
}
|
|
14490
14490
|
};
|
|
14491
14491
|
const text = buildRunLogsText(filteredResult);
|
|
14492
|
-
|
|
14492
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14493
14493
|
{
|
|
14494
14494
|
runId: result.runId,
|
|
14495
14495
|
totalCount: result.totalCount,
|
|
@@ -14513,7 +14513,7 @@ async function handleRunLogs(args) {
|
|
|
14513
14513
|
render: { sections: [{ title: "run logs", lines: entries }] }
|
|
14514
14514
|
},
|
|
14515
14515
|
{
|
|
14516
|
-
json:
|
|
14516
|
+
json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args),
|
|
14517
14517
|
text
|
|
14518
14518
|
}
|
|
14519
14519
|
);
|
|
@@ -14537,7 +14537,7 @@ function selectRunLogTailPage(result, logLevel, limit) {
|
|
|
14537
14537
|
);
|
|
14538
14538
|
}
|
|
14539
14539
|
const matching = result.entries.map((line, index) => ({ line, seq: first + index })).filter(
|
|
14540
|
-
(entry) =>
|
|
14540
|
+
(entry) => _chunkE23BQ5SCjs.logLevelReaches.call(void 0, _chunkE23BQ5SCjs.classifyLogLine.call(void 0, entry.line).level, logLevel)
|
|
14541
14541
|
);
|
|
14542
14542
|
const selected = matching.slice(-limit);
|
|
14543
14543
|
const olderMatchesExist = matching.length > selected.length;
|
|
@@ -14547,7 +14547,7 @@ function selectRunLogTailPage(result, logLevel, limit) {
|
|
|
14547
14547
|
lastSequence: _nullishCoalesce(_optionalChain([selected, 'access', _498 => _498.at, 'call', _499 => _499(-1), 'optionalAccess', _500 => _500.seq]), () => ( null)),
|
|
14548
14548
|
truncated: result.truncated || olderMatchesExist,
|
|
14549
14549
|
hasMore: olderMatchesExist,
|
|
14550
|
-
nextCursor: olderMatchesExist ?
|
|
14550
|
+
nextCursor: olderMatchesExist ? _chunkE23BQ5SCjs.encodeRunLogsCursor.call(void 0, selected[0].seq) : null
|
|
14551
14551
|
};
|
|
14552
14552
|
}
|
|
14553
14553
|
async function handleRunEventSearch(args) {
|
|
@@ -14614,7 +14614,7 @@ ${usage2}`);
|
|
|
14614
14614
|
namespace,
|
|
14615
14615
|
...backend ? { backend } : {}
|
|
14616
14616
|
} : void 0;
|
|
14617
|
-
const client = new (0,
|
|
14617
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
14618
14618
|
const result = await client.runs.searchEvents({
|
|
14619
14619
|
...runId ? { runId } : {},
|
|
14620
14620
|
...values["--since"] ? { since: values["--since"] } : {},
|
|
@@ -14686,7 +14686,7 @@ ${renderedDetails}` : ""}`;
|
|
|
14686
14686
|
"--limit",
|
|
14687
14687
|
String(limit)
|
|
14688
14688
|
].join(" ") : null;
|
|
14689
|
-
|
|
14689
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14690
14690
|
{
|
|
14691
14691
|
events,
|
|
14692
14692
|
nextCursor: result.nextCursor,
|
|
@@ -14697,14 +14697,14 @@ ${renderedDetails}` : ""}`;
|
|
|
14697
14697
|
render: { sections: [{ title: "runtime events", lines }] }
|
|
14698
14698
|
},
|
|
14699
14699
|
{
|
|
14700
|
-
json:
|
|
14700
|
+
json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args),
|
|
14701
14701
|
text: `${lines.join("\n")}${lines.length ? "\n" : ""}`
|
|
14702
14702
|
}
|
|
14703
14703
|
);
|
|
14704
14704
|
return 0;
|
|
14705
14705
|
}
|
|
14706
14706
|
function buildRunLogsText(result) {
|
|
14707
|
-
const lines = result.entries.map((line) =>
|
|
14707
|
+
const lines = result.entries.map((line) => _chunkE23BQ5SCjs.classifyLogLine.call(void 0, line).line);
|
|
14708
14708
|
if (result.warning) {
|
|
14709
14709
|
if (lines.length > 0) lines.push("");
|
|
14710
14710
|
lines.push(`warning: ${result.warning}`);
|
|
@@ -14738,7 +14738,7 @@ async function handleRunStop(args) {
|
|
|
14738
14738
|
reason = args[++index];
|
|
14739
14739
|
}
|
|
14740
14740
|
}
|
|
14741
|
-
const client = new (0,
|
|
14741
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
14742
14742
|
const result = await client.runs.stop(runId, { reason });
|
|
14743
14743
|
const state = resolveRunStopState(result);
|
|
14744
14744
|
const hitlCleanupIncomplete = state === "cancelling" && result.hitlCancellationPending === true;
|
|
@@ -14753,7 +14753,7 @@ async function handleRunStop(args) {
|
|
|
14753
14753
|
...result.hitlCancelledCount > 0 ? [`cancelled HITL waits: ${result.hitlCancelledCount}`] : [],
|
|
14754
14754
|
`inspect: deepline runs get ${runId} --full`
|
|
14755
14755
|
];
|
|
14756
|
-
|
|
14756
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14757
14757
|
{
|
|
14758
14758
|
...cancelling,
|
|
14759
14759
|
state,
|
|
@@ -14768,7 +14768,7 @@ async function handleRunStop(args) {
|
|
|
14768
14768
|
]
|
|
14769
14769
|
}
|
|
14770
14770
|
},
|
|
14771
|
-
{ json:
|
|
14771
|
+
{ json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args) }
|
|
14772
14772
|
);
|
|
14773
14773
|
return 0;
|
|
14774
14774
|
}
|
|
@@ -14785,7 +14785,7 @@ async function handleRunStop(args) {
|
|
|
14785
14785
|
];
|
|
14786
14786
|
process.stderr.write(`${lines2.join("\n")}
|
|
14787
14787
|
`);
|
|
14788
|
-
|
|
14788
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14789
14789
|
{
|
|
14790
14790
|
...result,
|
|
14791
14791
|
render: {
|
|
@@ -14800,7 +14800,7 @@ async function handleRunStop(args) {
|
|
|
14800
14800
|
]
|
|
14801
14801
|
}
|
|
14802
14802
|
},
|
|
14803
|
-
{ json:
|
|
14803
|
+
{ json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args) }
|
|
14804
14804
|
);
|
|
14805
14805
|
return 1;
|
|
14806
14806
|
}
|
|
@@ -14811,12 +14811,12 @@ async function handleRunStop(args) {
|
|
|
14811
14811
|
`warning: HITL cancellation or Slack card refresh is still pending; retry 'deepline runs stop ${runId}'`
|
|
14812
14812
|
] : []
|
|
14813
14813
|
];
|
|
14814
|
-
|
|
14814
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14815
14815
|
{
|
|
14816
14816
|
...result,
|
|
14817
14817
|
render: { sections: [{ title: "run stop", lines }] }
|
|
14818
14818
|
},
|
|
14819
|
-
{ json:
|
|
14819
|
+
{ json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args) }
|
|
14820
14820
|
);
|
|
14821
14821
|
return 0;
|
|
14822
14822
|
}
|
|
@@ -14866,18 +14866,18 @@ async function handleRunStopAll(args) {
|
|
|
14866
14866
|
reason = args[++index];
|
|
14867
14867
|
}
|
|
14868
14868
|
}
|
|
14869
|
-
const client = new (0,
|
|
14869
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
14870
14870
|
if (dryRun) {
|
|
14871
14871
|
const result2 = await client.runs.stopAll({ dryRun: true, reason });
|
|
14872
14872
|
const lines2 = buildStopAllDryRunTextLines(result2);
|
|
14873
|
-
|
|
14873
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14874
14874
|
{
|
|
14875
14875
|
...result2,
|
|
14876
14876
|
render: {
|
|
14877
14877
|
sections: [{ title: "workspace stop-all (dry run)", lines: lines2 }]
|
|
14878
14878
|
}
|
|
14879
14879
|
},
|
|
14880
|
-
{ json:
|
|
14880
|
+
{ json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args), text: `${lines2.join("\n")}
|
|
14881
14881
|
` }
|
|
14882
14882
|
);
|
|
14883
14883
|
return 0;
|
|
@@ -14890,17 +14890,17 @@ async function handleRunStopAll(args) {
|
|
|
14890
14890
|
...result.failed > 0 ? [`failed stops: ${result.failed}`] : [],
|
|
14891
14891
|
...result.skipped > 0 ? [`skipped: ${result.skipped}`] : []
|
|
14892
14892
|
];
|
|
14893
|
-
|
|
14893
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
14894
14894
|
{
|
|
14895
14895
|
...result,
|
|
14896
14896
|
render: { sections: [{ title: "workspace stop-all", lines }] }
|
|
14897
14897
|
},
|
|
14898
|
-
{ json:
|
|
14898
|
+
{ json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args) }
|
|
14899
14899
|
);
|
|
14900
14900
|
return result.failed > 0 || result.partial ? 1 : 0;
|
|
14901
14901
|
}
|
|
14902
14902
|
async function handleRunExport(args) {
|
|
14903
|
-
const selection =
|
|
14903
|
+
const selection = _chunkKGNTKMRGjs.parseJsonFields.call(void 0, args, "export");
|
|
14904
14904
|
args = selection.args;
|
|
14905
14905
|
const usage2 = "Usage: deepline runs export <run-id> [--dataset result.rows] --out <path> [--format csv|json] [--wait] [--timeout-ms 300000] [--metadata-out export.json] [--allow-empty] [--json]";
|
|
14906
14906
|
let runId;
|
|
@@ -14959,16 +14959,16 @@ async function handleRunExport(args) {
|
|
|
14959
14959
|
"INVALID_ARGUMENT"
|
|
14960
14960
|
);
|
|
14961
14961
|
}
|
|
14962
|
-
const client = new (0,
|
|
14962
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
14963
14963
|
let status = await client.getPlayStatus(runId, { full: true });
|
|
14964
14964
|
if (wait && !TERMINAL_PLAY_STATUSES.has(status.status)) {
|
|
14965
|
-
const progress = _chunkWJYPBHTEjs.createCliProgress.call(void 0, !
|
|
14965
|
+
const progress = _chunkWJYPBHTEjs.createCliProgress.call(void 0, !_chunkKGNTKMRGjs.argsWantJson.call(void 0, args));
|
|
14966
14966
|
try {
|
|
14967
14967
|
await waitForPlayCompletionByWatch({
|
|
14968
14968
|
client,
|
|
14969
14969
|
playName: _nullishCoalesce(extractRunPlayName(status), () => ( runId)),
|
|
14970
14970
|
workflowId: runId,
|
|
14971
|
-
jsonOutput:
|
|
14971
|
+
jsonOutput: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args),
|
|
14972
14972
|
emitLogs: false,
|
|
14973
14973
|
waitTimeoutMs,
|
|
14974
14974
|
startedAt: Date.now(),
|
|
@@ -15068,8 +15068,8 @@ async function handleRunExport(args) {
|
|
|
15068
15068
|
"utf-8"
|
|
15069
15069
|
);
|
|
15070
15070
|
}
|
|
15071
|
-
|
|
15072
|
-
json:
|
|
15071
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, payload, {
|
|
15072
|
+
json: _chunkKGNTKMRGjs.argsWantJson.call(void 0, args),
|
|
15073
15073
|
fields: selection.fields,
|
|
15074
15074
|
text: `${lines.join("\n")}
|
|
15075
15075
|
`
|
|
@@ -15090,10 +15090,10 @@ async function handlePlayGet(args) {
|
|
|
15090
15090
|
);
|
|
15091
15091
|
return 2;
|
|
15092
15092
|
}
|
|
15093
|
-
const client = new (0,
|
|
15093
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
15094
15094
|
const explicitJson = args.includes("--json");
|
|
15095
15095
|
const sourceOutput = args.includes("--source");
|
|
15096
|
-
const jsonOutput = sourceOutput ? explicitJson :
|
|
15096
|
+
const jsonOutput = sourceOutput ? explicitJson : _chunkKGNTKMRGjs.argsWantJson.call(void 0, args);
|
|
15097
15097
|
const requestedRevisionFlags = [
|
|
15098
15098
|
args.includes("--working"),
|
|
15099
15099
|
args.includes("--live"),
|
|
@@ -15153,7 +15153,7 @@ async function handlePlayGet(args) {
|
|
|
15153
15153
|
}
|
|
15154
15154
|
const loadedMessage = materializedFile ? formatLoadedPlayMessage(materializedFile) : null;
|
|
15155
15155
|
if (jsonOutput) {
|
|
15156
|
-
|
|
15156
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, {
|
|
15157
15157
|
...detail,
|
|
15158
15158
|
...materializedFile ? {
|
|
15159
15159
|
message: loadedMessage,
|
|
@@ -15245,8 +15245,8 @@ async function handlePlayVersions(args) {
|
|
|
15245
15245
|
console.error("Usage: deepline plays versions --name <name> [--json]");
|
|
15246
15246
|
return 1;
|
|
15247
15247
|
}
|
|
15248
|
-
const client = new (0,
|
|
15249
|
-
const jsonOutput =
|
|
15248
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
15249
|
+
const jsonOutput = _chunkKGNTKMRGjs.argsWantJson.call(void 0, args);
|
|
15250
15250
|
await assertCanonicalNamedPlayReference(client, playName, {
|
|
15251
15251
|
command: "versions"
|
|
15252
15252
|
});
|
|
@@ -15254,7 +15254,7 @@ async function handlePlayVersions(args) {
|
|
|
15254
15254
|
parseReferencedPlayTarget2(playName).playName
|
|
15255
15255
|
);
|
|
15256
15256
|
if (jsonOutput) {
|
|
15257
|
-
|
|
15257
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, { versions });
|
|
15258
15258
|
return 0;
|
|
15259
15259
|
}
|
|
15260
15260
|
if (versions.length === 0) {
|
|
@@ -15286,9 +15286,9 @@ var PREBUILT_PLAY_TAG_KEYS = [
|
|
|
15286
15286
|
"signals"
|
|
15287
15287
|
];
|
|
15288
15288
|
async function handlePlayList(args) {
|
|
15289
|
-
const jsonOutput =
|
|
15289
|
+
const jsonOutput = _chunkKGNTKMRGjs.argsWantJson.call(void 0, args);
|
|
15290
15290
|
const showCost = args.includes("--show-cost");
|
|
15291
|
-
const client = new (0,
|
|
15291
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
15292
15292
|
const categoriesIndex = args.indexOf("--categories");
|
|
15293
15293
|
const categories = categoriesIndex >= 0 ? _optionalChain([args, 'access', _536 => _536[categoriesIndex + 1], 'optionalAccess', _537 => _537.trim, 'call', _538 => _538()]) : void 0;
|
|
15294
15294
|
const tags = args.flatMap((arg, index) => arg === "--tag" ? [args[index + 1]] : []).flatMap((value) => (_nullishCoalesce(value, () => ( ""))).split(",")).map((value) => value.trim()).filter(Boolean);
|
|
@@ -15385,7 +15385,7 @@ async function handlePlayList(args) {
|
|
|
15385
15385
|
lines.push("List truncated \u2014 more plays are available.");
|
|
15386
15386
|
lines.push(`Next page: ${nextPage}`);
|
|
15387
15387
|
}
|
|
15388
|
-
|
|
15388
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
15389
15389
|
{
|
|
15390
15390
|
plays,
|
|
15391
15391
|
count: plays.length,
|
|
@@ -15403,7 +15403,7 @@ async function handlePlayList(args) {
|
|
|
15403
15403
|
}
|
|
15404
15404
|
async function handlePlayPin(args, pinned) {
|
|
15405
15405
|
const target = _optionalChain([args, 'access', _545 => _545.find, 'call', _546 => _546((arg) => !arg.startsWith("-")), 'optionalAccess', _547 => _547.trim, 'call', _548 => _548()]);
|
|
15406
|
-
const jsonOutput =
|
|
15406
|
+
const jsonOutput = _chunkKGNTKMRGjs.argsWantJson.call(void 0, args);
|
|
15407
15407
|
const dryRun = args.includes("--dry-run");
|
|
15408
15408
|
if (!target) {
|
|
15409
15409
|
console.error(
|
|
@@ -15421,11 +15421,11 @@ async function handlePlayPin(args, pinned) {
|
|
|
15421
15421
|
const name = parsedTarget.playName;
|
|
15422
15422
|
const plan = { name, pinned, dryRun };
|
|
15423
15423
|
if (dryRun) {
|
|
15424
|
-
|
|
15424
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, plan);
|
|
15425
15425
|
return 0;
|
|
15426
15426
|
}
|
|
15427
|
-
const result = await new (0,
|
|
15428
|
-
if (jsonOutput)
|
|
15427
|
+
const result = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().setPlayPinned(name, pinned);
|
|
15428
|
+
if (jsonOutput) _chunkKGNTKMRGjs.printCompactJson.call(void 0, result);
|
|
15429
15429
|
else console.log(`${result.pinned ? "Pinned" : "Unpinned"} ${result.name}.`);
|
|
15430
15430
|
return 0;
|
|
15431
15431
|
}
|
|
@@ -15441,7 +15441,7 @@ function csvColumnLines(csvInput) {
|
|
|
15441
15441
|
const headers = [defaults[column]].flat().filter((header) => header && header !== column);
|
|
15442
15442
|
return `${column}${required.has(column) ? " (required)" : ""}${headers.length > 0 ? `, default header: ${headers.join(" or ")}` : ""}`;
|
|
15443
15443
|
}),
|
|
15444
|
-
|
|
15444
|
+
_chunkE23BQ5SCjs.CSV_HEADER_MATCHING_NOTE
|
|
15445
15445
|
];
|
|
15446
15446
|
}
|
|
15447
15447
|
function describedPlay(play) {
|
|
@@ -15607,12 +15607,12 @@ async function handlePlayGrep(args) {
|
|
|
15607
15607
|
console.error("Usage: deepline plays grep <query> [--json]");
|
|
15608
15608
|
return 1;
|
|
15609
15609
|
}
|
|
15610
|
-
const client = new (0,
|
|
15610
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
15611
15611
|
const results = (await client.listPlays({ grep: query })).map(
|
|
15612
15612
|
summarizePlayGrepResult
|
|
15613
15613
|
);
|
|
15614
|
-
if (
|
|
15615
|
-
|
|
15614
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
15615
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, {
|
|
15616
15616
|
plays: results,
|
|
15617
15617
|
count: results.length,
|
|
15618
15618
|
query,
|
|
@@ -15635,7 +15635,7 @@ async function handlePlayGrep(args) {
|
|
|
15635
15635
|
return 0;
|
|
15636
15636
|
}
|
|
15637
15637
|
async function handlePlayDescribe(args) {
|
|
15638
|
-
const selection =
|
|
15638
|
+
const selection = _chunkKGNTKMRGjs.parseJsonFields.call(void 0, args, "describe");
|
|
15639
15639
|
args = selection.args;
|
|
15640
15640
|
const playName = args[0];
|
|
15641
15641
|
if (!playName) {
|
|
@@ -15669,8 +15669,8 @@ async function handlePlayDescribe(args) {
|
|
|
15669
15669
|
`deepline plays check ${playName}`,
|
|
15670
15670
|
...definedName ? [`deepline describe <workspace>/${definedName}`] : []
|
|
15671
15671
|
];
|
|
15672
|
-
if (
|
|
15673
|
-
|
|
15672
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
15673
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, {
|
|
15674
15674
|
ok: false,
|
|
15675
15675
|
error: { message },
|
|
15676
15676
|
next
|
|
@@ -15684,7 +15684,7 @@ async function handlePlayDescribe(args) {
|
|
|
15684
15684
|
}
|
|
15685
15685
|
return 2;
|
|
15686
15686
|
}
|
|
15687
|
-
const client = new (0,
|
|
15687
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
15688
15688
|
await assertCanonicalNamedPlayReference(client, playName, {
|
|
15689
15689
|
command: "describe"
|
|
15690
15690
|
});
|
|
@@ -15694,9 +15694,9 @@ async function handlePlayDescribe(args) {
|
|
|
15694
15694
|
compact: args.includes("--compact")
|
|
15695
15695
|
}
|
|
15696
15696
|
);
|
|
15697
|
-
if (
|
|
15698
|
-
if (selection.fields)
|
|
15699
|
-
else
|
|
15697
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
15698
|
+
if (selection.fields) _chunkKGNTKMRGjs.printJson.call(void 0, play, selection.fields);
|
|
15699
|
+
else _chunkKGNTKMRGjs.printCompactJson.call(void 0, play);
|
|
15700
15700
|
return 0;
|
|
15701
15701
|
}
|
|
15702
15702
|
printPlayDescription(play);
|
|
@@ -15740,7 +15740,7 @@ async function handlePlaySave(args) {
|
|
|
15740
15740
|
next: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.target)}`
|
|
15741
15741
|
};
|
|
15742
15742
|
if (options.jsonOutput) {
|
|
15743
|
-
|
|
15743
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result);
|
|
15744
15744
|
} else {
|
|
15745
15745
|
console.error(result.message);
|
|
15746
15746
|
console.error(` checked artifact: ${result.expectedArtifactHash}`);
|
|
@@ -15762,7 +15762,7 @@ async function handlePlaySave(args) {
|
|
|
15762
15762
|
};
|
|
15763
15763
|
if (options.dryRun) {
|
|
15764
15764
|
if (options.jsonOutput) {
|
|
15765
|
-
|
|
15765
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, dryRun);
|
|
15766
15766
|
} else {
|
|
15767
15767
|
console.log(`Dry run: ${playName}`);
|
|
15768
15768
|
console.log(` source: ${dryRun.sourceHash}`);
|
|
@@ -15771,7 +15771,7 @@ async function handlePlaySave(args) {
|
|
|
15771
15771
|
}
|
|
15772
15772
|
return 0;
|
|
15773
15773
|
}
|
|
15774
|
-
const client = new (0,
|
|
15774
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
15775
15775
|
try {
|
|
15776
15776
|
await _chunkAYHLUHE5js.traceCliSpan.call(void 0,
|
|
15777
15777
|
"cli.play_save_compile_manifests",
|
|
@@ -15807,7 +15807,7 @@ async function handlePlaySave(args) {
|
|
|
15807
15807
|
}
|
|
15808
15808
|
};
|
|
15809
15809
|
if (options.jsonOutput) {
|
|
15810
|
-
|
|
15810
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result);
|
|
15811
15811
|
} else {
|
|
15812
15812
|
console.log(
|
|
15813
15813
|
`\u2713 Saved ${playName} working draft as v${_nullishCoalesce(result.version, () => ( "?"))}`
|
|
@@ -15833,7 +15833,7 @@ async function handlePlayPublish(args) {
|
|
|
15833
15833
|
}
|
|
15834
15834
|
const { target: playName, useLatest } = options;
|
|
15835
15835
|
let revisionId = options.revisionId;
|
|
15836
|
-
const client = new (0,
|
|
15836
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
15837
15837
|
if (isFileTarget2(playName)) {
|
|
15838
15838
|
if (revisionId || useLatest) {
|
|
15839
15839
|
console.error(
|
|
@@ -15865,7 +15865,7 @@ async function handlePlayPublish(args) {
|
|
|
15865
15865
|
next: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, playName)}`
|
|
15866
15866
|
};
|
|
15867
15867
|
if (options.jsonOutput) {
|
|
15868
|
-
|
|
15868
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result3);
|
|
15869
15869
|
} else {
|
|
15870
15870
|
console.error(result3.message);
|
|
15871
15871
|
console.error(` checked artifact: ${result3.expectedArtifactHash}`);
|
|
@@ -15888,7 +15888,7 @@ async function handlePlayPublish(args) {
|
|
|
15888
15888
|
};
|
|
15889
15889
|
if (options.dryRun) {
|
|
15890
15890
|
if (options.jsonOutput) {
|
|
15891
|
-
|
|
15891
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, dryRun);
|
|
15892
15892
|
} else {
|
|
15893
15893
|
console.log(`Dry run: ${rootPlayName}`);
|
|
15894
15894
|
console.log(` source: ${dryRun.sourceHash}`);
|
|
@@ -15956,7 +15956,7 @@ async function handlePlayPublish(args) {
|
|
|
15956
15956
|
triggerBindings: _nullishCoalesce(published.triggerBindings, () => ( []))
|
|
15957
15957
|
};
|
|
15958
15958
|
if (options.jsonOutput) {
|
|
15959
|
-
|
|
15959
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result2);
|
|
15960
15960
|
} else {
|
|
15961
15961
|
printPublishReceipt({
|
|
15962
15962
|
name: rootPlayName,
|
|
@@ -15987,7 +15987,7 @@ async function handlePlayPublish(args) {
|
|
|
15987
15987
|
revisionId: _nullishCoalesce(revisionId, () => ( null)),
|
|
15988
15988
|
latest: useLatest
|
|
15989
15989
|
};
|
|
15990
|
-
|
|
15990
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result2);
|
|
15991
15991
|
return 0;
|
|
15992
15992
|
}
|
|
15993
15993
|
const resolvedName = parseReferencedPlayTarget2(playName).playName;
|
|
@@ -16011,7 +16011,7 @@ async function handlePlayPublish(args) {
|
|
|
16011
16011
|
revisionId ? { revisionId } : {}
|
|
16012
16012
|
);
|
|
16013
16013
|
if (options.jsonOutput) {
|
|
16014
|
-
|
|
16014
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result);
|
|
16015
16015
|
} else {
|
|
16016
16016
|
printPublishReceipt({
|
|
16017
16017
|
name: result.name,
|
|
@@ -16051,7 +16051,7 @@ async function handlePlayDelete(args) {
|
|
|
16051
16051
|
);
|
|
16052
16052
|
return 2;
|
|
16053
16053
|
}
|
|
16054
|
-
const client = new (0,
|
|
16054
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
16055
16055
|
let detail;
|
|
16056
16056
|
try {
|
|
16057
16057
|
detail = await client.getPlay(parseReferencedPlayTarget2(playName).playName);
|
|
@@ -16075,8 +16075,8 @@ async function handlePlayDelete(args) {
|
|
|
16075
16075
|
name: resolvedName,
|
|
16076
16076
|
plannedMutation: "move saved org-owned play to Trash and stop triggers"
|
|
16077
16077
|
};
|
|
16078
|
-
if (
|
|
16079
|
-
|
|
16078
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
16079
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result2);
|
|
16080
16080
|
} else {
|
|
16081
16081
|
process.stdout.write(
|
|
16082
16082
|
`Dry run: would move ${result2.name} to Trash and stop its active triggers.
|
|
@@ -16086,8 +16086,8 @@ async function handlePlayDelete(args) {
|
|
|
16086
16086
|
return 0;
|
|
16087
16087
|
}
|
|
16088
16088
|
const result = await client.deletePlay(resolvedName);
|
|
16089
|
-
if (
|
|
16090
|
-
|
|
16089
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
16090
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result);
|
|
16091
16091
|
return result.archived || result.alreadyArchived ? 0 : 4;
|
|
16092
16092
|
}
|
|
16093
16093
|
if (result.alreadyArchived) {
|
|
@@ -16126,13 +16126,13 @@ async function handlePlayRestore(args) {
|
|
|
16126
16126
|
);
|
|
16127
16127
|
return 2;
|
|
16128
16128
|
}
|
|
16129
|
-
const client = new (0,
|
|
16129
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
16130
16130
|
try {
|
|
16131
16131
|
const result = await client.restorePlay(
|
|
16132
16132
|
parseReferencedPlayTarget2(playName).playName
|
|
16133
16133
|
);
|
|
16134
|
-
if (
|
|
16135
|
-
|
|
16134
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
16135
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, result);
|
|
16136
16136
|
return result.restored || result.alreadyActive ? 0 : 4;
|
|
16137
16137
|
}
|
|
16138
16138
|
if (result.alreadyActive) {
|
|
@@ -16159,6 +16159,11 @@ function registerPlayCommands(program) {
|
|
|
16159
16159
|
Concepts:
|
|
16160
16160
|
Plays are durable cloud workflows.
|
|
16161
16161
|
Stable ctx.tools.execute({ id, tool, input, staleAfterSeconds: 0 }) requests fresh work.
|
|
16162
|
+
In authoring edition 11, choose freshness explicitly: 0 for fresh logical
|
|
16163
|
+
work, a positive integer for the maximum reusable result age in seconds, or
|
|
16164
|
+
null for indefinite result reuse. A matching completed operation receipt can
|
|
16165
|
+
still recover that operation after resume; older authored editions retain
|
|
16166
|
+
omitted-value behavior.
|
|
16162
16167
|
Completed calls are replay-safe during recovery of the same run; unfinished calls may execute again.
|
|
16163
16168
|
A stable id recovers a completed call; repeating plays run starts new work.
|
|
16164
16169
|
ctx.dataset adds row keys and row progress.
|
|
@@ -16240,21 +16245,21 @@ Common commands:
|
|
|
16240
16245
|
resume: `deepline plays resume-submission ${_chunkAID3OYVJjs.shellQuote.call(void 0, path)} --json`
|
|
16241
16246
|
}
|
|
16242
16247
|
};
|
|
16243
|
-
|
|
16248
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0, result2, {
|
|
16244
16249
|
json: options.json,
|
|
16245
16250
|
text: `Submission ${saved.workflowId}: admission is unknown. ${result2.next.inspect}
|
|
16246
16251
|
`
|
|
16247
16252
|
});
|
|
16248
16253
|
return;
|
|
16249
16254
|
}
|
|
16250
|
-
const client = new (0,
|
|
16255
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
16251
16256
|
if (new URL(saved.baseUrl).origin !== new URL(client.baseUrl).origin) {
|
|
16252
16257
|
throw new Error(
|
|
16253
16258
|
"The submission belongs to a different API origin. Select its original host before recovery."
|
|
16254
16259
|
);
|
|
16255
16260
|
}
|
|
16256
16261
|
const result = await client.startPlayRun(saved.request);
|
|
16257
|
-
|
|
16262
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
16258
16263
|
{ ...result },
|
|
16259
16264
|
{
|
|
16260
16265
|
json: options.json,
|
|
@@ -16290,7 +16295,7 @@ Examples:
|
|
|
16290
16295
|
).action(async (target, options) => {
|
|
16291
16296
|
process.exitCode = await handlePlayCheck([
|
|
16292
16297
|
target,
|
|
16293
|
-
...
|
|
16298
|
+
..._chunkKGNTKMRGjs.jsonFieldArgs.call(void 0, options.json),
|
|
16294
16299
|
...options.full ? ["--full"] : []
|
|
16295
16300
|
]);
|
|
16296
16301
|
});
|
|
@@ -16342,6 +16347,11 @@ Idempotent execution:
|
|
|
16342
16347
|
Durable tool-call reuse is based on the actual external call identity:
|
|
16343
16348
|
same play, tool, semantic input, auth scope, provider action version, and
|
|
16344
16349
|
cache policy.
|
|
16350
|
+
In authoring edition 11, choose freshness explicitly: 0 for fresh logical
|
|
16351
|
+
work, a positive integer for the maximum reusable result age in seconds, or
|
|
16352
|
+
null for indefinite result reuse. A matching completed operation receipt can
|
|
16353
|
+
still recover that operation after resume. Older authored editions keep their
|
|
16354
|
+
existing omitted-value behavior.
|
|
16345
16355
|
|
|
16346
16356
|
await ctx.tools.execute({ id: 'company_lookup', tool, input, staleAfterSeconds: 86400 });
|
|
16347
16357
|
|
|
@@ -16526,9 +16536,9 @@ Examples:
|
|
|
16526
16536
|
const limit = Number(options.historyLimit);
|
|
16527
16537
|
if (!Number.isInteger(limit) || limit < 1 || limit > 30)
|
|
16528
16538
|
throw new Error("--history-limit must be an integer from 1 to 30.");
|
|
16529
|
-
const client = new (0,
|
|
16539
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
16530
16540
|
if (options.binding) {
|
|
16531
|
-
|
|
16541
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0,
|
|
16532
16542
|
await client.getPlayTriggerHistory(options.binding, { limit })
|
|
16533
16543
|
);
|
|
16534
16544
|
return;
|
|
@@ -16536,7 +16546,7 @@ Examples:
|
|
|
16536
16546
|
const result = await client.listPlayTriggerInventory({
|
|
16537
16547
|
cursor: options.cursor
|
|
16538
16548
|
});
|
|
16539
|
-
|
|
16549
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, {
|
|
16540
16550
|
...result,
|
|
16541
16551
|
next: result.isDone ? null : `deepline plays triggers --cursor ${JSON.stringify(result.continueCursor)}`
|
|
16542
16552
|
});
|
|
@@ -16583,7 +16593,7 @@ Examples:
|
|
|
16583
16593
|
if (options.groupBy !== "kind" && options.groupBy !== "trigger_source") {
|
|
16584
16594
|
throw new Error("--group-by must be kind or trigger_source.");
|
|
16585
16595
|
}
|
|
16586
|
-
const result = await new (0,
|
|
16596
|
+
const result = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().getPlaysActivity({
|
|
16587
16597
|
timeZone: options.timeZone,
|
|
16588
16598
|
days,
|
|
16589
16599
|
...options.endDate ? { endDate: options.endDate } : {},
|
|
@@ -16597,7 +16607,7 @@ Examples:
|
|
|
16597
16607
|
`${bucket.key} ${groups} failed_play_runs=${bucket.failedPlayRuns} ${coverage}`
|
|
16598
16608
|
);
|
|
16599
16609
|
}
|
|
16600
|
-
|
|
16610
|
+
_chunkKGNTKMRGjs.printCommandEnvelope.call(void 0,
|
|
16601
16611
|
{ ...result },
|
|
16602
16612
|
{
|
|
16603
16613
|
json: Boolean(options.json),
|
|
@@ -16626,7 +16636,7 @@ Examples:
|
|
|
16626
16636
|
false
|
|
16627
16637
|
);
|
|
16628
16638
|
});
|
|
16629
|
-
|
|
16639
|
+
_chunkVK6FYZLPjs.registerDeprecatedSearchCommand.call(void 0,
|
|
16630
16640
|
play,
|
|
16631
16641
|
(options) => options.all ? ["plays"] : ["prebuilts"]
|
|
16632
16642
|
);
|
|
@@ -16669,7 +16679,7 @@ Examples:
|
|
|
16669
16679
|
);
|
|
16670
16680
|
_chunkZMVJSS6Njs.addDescribeOptions.call(void 0, describeCommand, { json: false }).action(
|
|
16671
16681
|
async (target, options) => {
|
|
16672
|
-
const ownView = () => handlePlayDescribe(
|
|
16682
|
+
const ownView = () => handlePlayDescribe(_chunkKGNTKMRGjs.describeArgs.call(void 0, target, options));
|
|
16673
16683
|
const [flagText] = [options.json].filter(
|
|
16674
16684
|
(value) => typeof value === "string"
|
|
16675
16685
|
);
|
|
@@ -16680,7 +16690,7 @@ Examples:
|
|
|
16680
16690
|
process.exitCode = await ownView();
|
|
16681
16691
|
return;
|
|
16682
16692
|
}
|
|
16683
|
-
const { describeAnything } = await Promise.resolve().then(() => _interopRequireWildcard(require("./describe-
|
|
16693
|
+
const { describeAnything } = await Promise.resolve().then(() => _interopRequireWildcard(require("./describe-FRH32RDV.js")));
|
|
16684
16694
|
process.exitCode = await describeAnything(
|
|
16685
16695
|
name,
|
|
16686
16696
|
{
|
|
@@ -16798,7 +16808,7 @@ Examples:
|
|
|
16798
16808
|
deepline plays deployments <deployment-id>
|
|
16799
16809
|
`
|
|
16800
16810
|
).option("--limit <n>", "Max rows (default 50)").option("--json", "Emit JSON output").action(
|
|
16801
|
-
async (id, options) => id ?
|
|
16811
|
+
async (id, options) => id ? _chunk2MDDA7A4js.handleDeploymentGet.call(void 0, id, options) : _chunk2MDDA7A4js.handleDeploymentsList.call(void 0, options)
|
|
16802
16812
|
);
|
|
16803
16813
|
addPublishHelp(
|
|
16804
16814
|
play.command("publish <target>").description(
|
|
@@ -16933,14 +16943,14 @@ Examples:
|
|
|
16933
16943
|
const limit = Number(options.limit);
|
|
16934
16944
|
if (!Number.isSafeInteger(limit) || limit < 1 || limit > 1e3)
|
|
16935
16945
|
throw new Error("--limit must be an integer from 1 to 1000.");
|
|
16936
|
-
const result = await new (0,
|
|
16946
|
+
const result = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().runs.rowHistory({
|
|
16937
16947
|
playName: options.play,
|
|
16938
16948
|
runId,
|
|
16939
16949
|
tableNamespace: options.dataset,
|
|
16940
16950
|
limit,
|
|
16941
16951
|
cursor: options.cursor
|
|
16942
16952
|
});
|
|
16943
|
-
|
|
16953
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, {
|
|
16944
16954
|
...result,
|
|
16945
16955
|
...result.nextCursor ? {
|
|
16946
16956
|
next: `deepline runs rows-history ${_chunkAID3OYVJjs.shellQuote.call(void 0, runId)} --play ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.play)} --dataset ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.dataset)} --limit ${limit} --cursor ${_chunkAID3OYVJjs.shellQuote.call(void 0, result.nextCursor)} --json`
|
|
@@ -17005,7 +17015,7 @@ Examples:
|
|
|
17005
17015
|
).action(async (runId, options) => {
|
|
17006
17016
|
process.exitCode = await handleRunGet([
|
|
17007
17017
|
runId,
|
|
17008
|
-
...
|
|
17018
|
+
..._chunkKGNTKMRGjs.jsonFieldArgs.call(void 0, options.json),
|
|
17009
17019
|
...options.webUrl ? ["--web-url"] : [],
|
|
17010
17020
|
...options.full ? ["--full"] : [],
|
|
17011
17021
|
...options.input ? ["--input"] : [],
|
|
@@ -17284,7 +17294,7 @@ Examples:
|
|
|
17284
17294
|
...options.allowEmpty ? ["--allow-empty"] : [],
|
|
17285
17295
|
...options.wait ? ["--wait"] : [],
|
|
17286
17296
|
...options.timeoutMs ? ["--timeout-ms", options.timeoutMs] : [],
|
|
17287
|
-
...
|
|
17297
|
+
..._chunkKGNTKMRGjs.jsonFieldArgs.call(void 0, options.json)
|
|
17288
17298
|
]);
|
|
17289
17299
|
});
|
|
17290
17300
|
const share = play.command("share").description(
|
|
@@ -17450,10 +17460,10 @@ async function handlePlayShareStatus(args) {
|
|
|
17450
17460
|
return 2;
|
|
17451
17461
|
}
|
|
17452
17462
|
const name = parseReferencedPlayTarget2(target).playName;
|
|
17453
|
-
const status = await new (0,
|
|
17463
|
+
const status = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().getSharePage(name);
|
|
17454
17464
|
const outputStatus = shareStatusForOutput(status);
|
|
17455
|
-
if (
|
|
17456
|
-
|
|
17465
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
17466
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, outputStatus);
|
|
17457
17467
|
return 0;
|
|
17458
17468
|
}
|
|
17459
17469
|
if (!outputStatus.share) {
|
|
@@ -17492,7 +17502,7 @@ async function handlePlaySharePublish(args) {
|
|
|
17492
17502
|
return 2;
|
|
17493
17503
|
}
|
|
17494
17504
|
const name = parseReferencedPlayTarget2(target).playName;
|
|
17495
|
-
const client = new (0,
|
|
17505
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
17496
17506
|
let revisionId = shareFlagValue(args, "--revision-id");
|
|
17497
17507
|
let resolvedVersion;
|
|
17498
17508
|
if (!revisionId) {
|
|
@@ -17523,8 +17533,8 @@ async function handlePlaySharePublish(args) {
|
|
|
17523
17533
|
);
|
|
17524
17534
|
if (!hasCompleted) {
|
|
17525
17535
|
const message = `No completed run for ${name}. Publish a play only after it has run successfully. (Override with --no-run-check.)`;
|
|
17526
|
-
if (
|
|
17527
|
-
|
|
17536
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
17537
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, {
|
|
17528
17538
|
ok: false,
|
|
17529
17539
|
code: "NO_SUCCESSFUL_RUN",
|
|
17530
17540
|
message,
|
|
@@ -17548,8 +17558,8 @@ async function handlePlaySharePublish(args) {
|
|
|
17548
17558
|
};
|
|
17549
17559
|
if (args.includes("--dry-run")) {
|
|
17550
17560
|
const plan = { dryRun: true, name, version: resolvedVersion, ...request };
|
|
17551
|
-
if (
|
|
17552
|
-
|
|
17561
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
17562
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, plan);
|
|
17553
17563
|
} else {
|
|
17554
17564
|
console.log(
|
|
17555
17565
|
`Would publish ${name}${resolvedVersion ? ` v${resolvedVersion}` : ""} (revision ${revisionId}).`
|
|
@@ -17559,8 +17569,8 @@ async function handlePlaySharePublish(args) {
|
|
|
17559
17569
|
}
|
|
17560
17570
|
const status = await client.publishSharePage(name, request);
|
|
17561
17571
|
const outputStatus = shareStatusForOutput(status);
|
|
17562
|
-
if (
|
|
17563
|
-
|
|
17572
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
17573
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, outputStatus);
|
|
17564
17574
|
return 0;
|
|
17565
17575
|
}
|
|
17566
17576
|
const urls = shareUrlFields(outputStatus);
|
|
@@ -17591,9 +17601,9 @@ async function handlePlayShareUpdate(args) {
|
|
|
17591
17601
|
...args.includes("--show-latency") ? { showAverageLatency: true } : args.includes("--hide-latency") ? { showAverageLatency: false } : {},
|
|
17592
17602
|
...seoIndexing ? { seoIndexing } : {}
|
|
17593
17603
|
};
|
|
17594
|
-
const status = await new (0,
|
|
17595
|
-
if (
|
|
17596
|
-
|
|
17604
|
+
const status = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().updateSharePage(name, request);
|
|
17605
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
17606
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, status);
|
|
17597
17607
|
return 0;
|
|
17598
17608
|
}
|
|
17599
17609
|
console.log(`Updated ${name} share settings.`);
|
|
@@ -17608,7 +17618,7 @@ async function handlePlayShareRegenerate(args) {
|
|
|
17608
17618
|
return 2;
|
|
17609
17619
|
}
|
|
17610
17620
|
const name = parseReferencedPlayTarget2(target).playName;
|
|
17611
|
-
const client = new (0,
|
|
17621
|
+
const client = new (0, _chunkE23BQ5SCjs.DeeplineClient)();
|
|
17612
17622
|
let revisionId = shareFlagValue(args, "--revision-id");
|
|
17613
17623
|
const versionFlag = shareFlagValue(args, "--version");
|
|
17614
17624
|
if (!revisionId && versionFlag) {
|
|
@@ -17625,8 +17635,8 @@ async function handlePlayShareRegenerate(args) {
|
|
|
17625
17635
|
revisionId ? { revisionId } : {}
|
|
17626
17636
|
);
|
|
17627
17637
|
const outputStatus = shareStatusForOutput(status);
|
|
17628
|
-
if (
|
|
17629
|
-
|
|
17638
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
17639
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, outputStatus);
|
|
17630
17640
|
return 0;
|
|
17631
17641
|
}
|
|
17632
17642
|
const urls = shareUrlFields(outputStatus);
|
|
@@ -17651,9 +17661,9 @@ async function handlePlayShareUnpublish(args) {
|
|
|
17651
17661
|
return 2;
|
|
17652
17662
|
}
|
|
17653
17663
|
const name = parseReferencedPlayTarget2(target).playName;
|
|
17654
|
-
const status = await new (0,
|
|
17655
|
-
if (
|
|
17656
|
-
|
|
17664
|
+
const status = await new (0, _chunkE23BQ5SCjs.DeeplineClient)().unpublishSharePage(name);
|
|
17665
|
+
if (_chunkKGNTKMRGjs.argsWantJson.call(void 0, args)) {
|
|
17666
|
+
_chunkKGNTKMRGjs.printCompactJson.call(void 0, status);
|
|
17657
17667
|
return 0;
|
|
17658
17668
|
}
|
|
17659
17669
|
console.log(`Unpublished ${name}; the public page has been removed.`);
|