deepline 0.3.400 → 0.3.401
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/cli/{auth-JL76JRJP.mjs → auth-4AWRW6ED.mjs} +4 -4
- package/dist/cli/auth-K6U65ROB.js +40 -0
- package/dist/cli/{billing-C6QEIDES.mjs → billing-AMQDNFSL.mjs} +4 -4
- package/dist/cli/{billing-BPYI4EUH.js → billing-FPHECIIS.js} +73 -73
- package/dist/cli/{chunk-JIDNO3FI.js → chunk-5QD6F5TW.js} +1 -1
- package/dist/cli/{chunk-PF3N65JD.js → chunk-72ESQ66A.js} +2 -2
- package/dist/cli/{chunk-OVYVMPEC.js → chunk-BHEJDACQ.js} +4 -4
- package/dist/cli/{chunk-GMMJMFCQ.mjs → chunk-BXRIA6OQ.mjs} +2 -2
- package/dist/cli/{chunk-III4UASP.mjs → chunk-C7JATIE5.mjs} +1 -1
- package/dist/cli/{chunk-2H37YDDG.js → chunk-D5KFELCC.js} +8 -8
- package/dist/cli/{chunk-ORQE3XBG.js → chunk-GDKUYYCJ.js} +50 -50
- package/dist/cli/{chunk-CKIELGYT.mjs → chunk-H4QOCJNY.mjs} +5 -5
- package/dist/cli/{chunk-V3T4CHXI.mjs → chunk-JDA2E5MQ.mjs} +1 -1
- package/dist/cli/{chunk-QUCAOIN7.js → chunk-LD7WUOAZ.js} +26 -26
- package/dist/cli/{chunk-O4JZTJEP.js → chunk-M3R2BG3A.js} +8 -8
- package/dist/cli/{chunk-BRMEK6KG.mjs → chunk-MSOOPRSP.mjs} +3 -3
- package/dist/cli/{chunk-IDXATBJB.js → chunk-OIODIUIC.js} +6 -6
- package/dist/cli/{chunk-QZDHNVKF.mjs → chunk-R2S7OCRB.mjs} +1 -1
- package/dist/cli/{chunk-UYIRTEU6.mjs → chunk-RMW6SXGP.mjs} +3 -3
- package/dist/cli/{chunk-H7Q6RK5Y.js → chunk-RWVQQ7O4.js} +44 -44
- package/dist/cli/{chunk-6SRV2NM3.js → chunk-S56LMBGA.js} +65 -65
- package/dist/cli/{chunk-USSWEZNP.js → chunk-SXGVRWAW.js} +15 -15
- package/dist/cli/{chunk-GCIMQKW4.mjs → chunk-TPA6R5EF.mjs} +2 -2
- package/dist/cli/{chunk-4OPBTEVW.js → chunk-WSKN3U4U.js} +6 -6
- package/dist/cli/{chunk-6PRUVCMW.mjs → chunk-X6WLVELL.mjs} +1 -1
- package/dist/cli/{chunk-H33BWG7S.mjs → chunk-YGHWGZMF.mjs} +1 -1
- package/dist/cli/{chunk-GYJSZ6J6.mjs → chunk-YJZM6SMA.mjs} +2 -2
- package/dist/cli/{chunk-BENKBQ2J.mjs → chunk-ZKV52IDD.mjs} +4 -4
- package/dist/cli/{csv-NK4QWZNT.js → csv-ARB6UC2S.js} +12 -12
- package/dist/cli/{csv-FLNTE5CW.mjs → csv-FICXQQRA.mjs} +3 -3
- package/dist/cli/{db-DU7J3CEM.js → db-HFQAZHLR.js} +25 -25
- package/dist/cli/{db-CAGTZIVN.mjs → db-OG5PJUEH.mjs} +4 -4
- package/dist/cli/{describe-IWQW7OLG.js → describe-HSHMULQM.js} +10 -10
- package/dist/cli/{describe-YJHDN5IE.mjs → describe-OU3J552L.mjs} +6 -6
- package/dist/cli/{executions-CDFAK267.mjs → executions-6JBC2LEV.mjs} +4 -4
- package/dist/cli/{executions-SUKU6I7V.js → executions-74BX6WTW.js} +6 -6
- package/dist/cli/{feedback-EQKQZTC4.mjs → feedback-DQMLYSYA.mjs} +3 -3
- package/dist/cli/{feedback-SRPRMYAN.js → feedback-QVDE26VJ.js} +7 -7
- package/dist/cli/git-62XASBWF.js +24 -0
- package/dist/cli/{git-M555IN55.mjs → git-CLGBVWOE.mjs} +4 -4
- package/dist/cli/index.js +89 -89
- package/dist/cli/index.mjs +32 -32
- package/dist/cli/{legacy-noops-M4X6PQFZ.js → legacy-noops-3WGVVY3K.js} +7 -7
- package/dist/cli/{legacy-noops-LRNAWLDN.mjs → legacy-noops-WRSE7SQJ.mjs} +4 -4
- package/dist/cli/{monitors-AOXY55KT.js → monitors-GY4VQLAC.js} +84 -84
- package/dist/cli/{monitors-IKRE2U3J.mjs → monitors-ZKFTF7YR.mjs} +4 -4
- package/dist/cli/{org-V5MRHKRO.mjs → org-D3PC2XSX.mjs} +4 -4
- package/dist/cli/{org-HNFRABMG.js → org-TYO2HXYG.js} +64 -64
- package/dist/cli/{play-Z22R7FWE.mjs → play-3OQWZXXS.mjs} +112 -33
- package/dist/cli/{play-LSGWSQE2.js → play-ZVHBPWSF.js} +375 -296
- package/dist/cli/{providers-BJJCETVG.mjs → providers-FFGKI5TY.mjs} +4 -4
- package/dist/cli/{providers-VYVFZR4J.js → providers-PGMUOSED.js} +7 -7
- package/dist/cli/{quickstart-EFPCKX32.mjs → quickstart-JCOPUMOG.mjs} +3 -3
- package/dist/cli/{quickstart-UGWUJK67.js → quickstart-PSA6H2J4.js} +5 -5
- package/dist/cli/search-OLW7VOVW.js +30 -0
- package/dist/cli/{search-NVPTBYU3.mjs → search-UBDRYRKV.mjs} +5 -5
- package/dist/cli/{secrets-ENLLOXON.js → secrets-35D7PHB6.js} +13 -13
- package/dist/cli/{secrets-4N4LSDKP.mjs → secrets-KERFAL3Q.mjs} +4 -4
- package/dist/cli/{sessions-PHGZZFBP.js → sessions-FDQFQHRN.js} +5 -5
- package/dist/cli/{sessions-7BKKDN5T.mjs → sessions-O2Z2KW6M.mjs} +4 -4
- package/dist/cli/{settings-CV2ZCTVK.js → settings-4FANCMJK.js} +74 -74
- package/dist/cli/{settings-VWEGOBRP.mjs → settings-4ZS7FR2D.mjs} +7 -7
- package/dist/cli/{setup-DEJSO3OM.js → setup-DO7JN6D5.js} +41 -41
- package/dist/cli/{setup-KG5HHXZD.mjs → setup-M2PE4H6S.mjs} +6 -6
- package/dist/cli/skills-OLGAL6KZ.js +29 -0
- package/dist/cli/{skills-EKFHOC3V.mjs → skills-TQBVDZRT.mjs} +4 -4
- package/dist/cli/{tools-4RLOPQJK.js → tools-3NNIOEWK.js} +7 -7
- package/dist/cli/{tools-4YNU6U4J.mjs → tools-WNRMVURQ.mjs} +6 -6
- package/dist/cli/{update-DE4SJRNA.mjs → update-3MF6MZJC.mjs} +6 -6
- package/dist/cli/update-6CWJ56OJ.js +29 -0
- package/dist/cli/{workflow-I7QMPLIW.js → workflow-EK3HMPGH.js} +15 -15
- package/dist/cli/{workflow-ODAFYNZA.mjs → workflow-UJB633SZ.mjs} +5 -5
- package/dist/index.js +6 -6
- package/dist/index.mjs +3 -3
- package/dist/install-integrity.json +70 -70
- 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-TNYZVC73.js +0 -40
- package/dist/cli/git-IRCN2ZZY.js +0 -24
- package/dist/cli/search-V3STUCIN.js +0 -30
- package/dist/cli/skills-YEVGRKB6.js +0 -29
- package/dist/cli/update-2RMF5UZD.js +0 -29
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
var _chunkZAAKSJASjs = require('./chunk-ZAAKSJAS.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkD5KFELCCjs = require('./chunk-D5KFELCC.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkLD7WUOAZjs = require('./chunk-LD7WUOAZ.js');
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
var _chunkBQR6UN3Cjs = require('./chunk-BQR6UN3C.js');
|
|
@@ -45,7 +45,7 @@ require('./chunk-KB4SDX5S.js');
|
|
|
45
45
|
|
|
46
46
|
|
|
47
47
|
|
|
48
|
-
var
|
|
48
|
+
var _chunkOIODIUICjs = require('./chunk-OIODIUIC.js');
|
|
49
49
|
require('./chunk-S6R3OX7B.js');
|
|
50
50
|
|
|
51
51
|
|
|
@@ -84,16 +84,16 @@ var _chunkWJYPBHTEjs = require('./chunk-WJYPBHTE.js');
|
|
|
84
84
|
|
|
85
85
|
|
|
86
86
|
|
|
87
|
-
var
|
|
87
|
+
var _chunkWSKN3U4Ujs = require('./chunk-WSKN3U4U.js');
|
|
88
88
|
|
|
89
89
|
|
|
90
|
-
var
|
|
90
|
+
var _chunkBHEJDACQjs = require('./chunk-BHEJDACQ.js');
|
|
91
91
|
require('./chunk-Q2E4E4FJ.js');
|
|
92
92
|
require('./chunk-XNYIZMNQ.js');
|
|
93
93
|
|
|
94
94
|
|
|
95
95
|
var _chunk7P5AA3SNjs = require('./chunk-7P5AA3SN.js');
|
|
96
|
-
require('./chunk-
|
|
96
|
+
require('./chunk-5QD6F5TW.js');
|
|
97
97
|
require('./chunk-OG64RBAC.js');
|
|
98
98
|
|
|
99
99
|
|
|
@@ -2075,7 +2075,7 @@ function resolveField(key, command) {
|
|
|
2075
2075
|
function printSettings(result, json, name) {
|
|
2076
2076
|
result = { ...result, settings: parsePlaySettings(result.settings) };
|
|
2077
2077
|
const selected = fields.filter(([key]) => !name || key === name);
|
|
2078
|
-
|
|
2078
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
2079
2079
|
{
|
|
2080
2080
|
...result,
|
|
2081
2081
|
settings: Object.fromEntries(
|
|
@@ -2119,7 +2119,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2119
2119
|
valueSyntax: field.cli.valueSyntax,
|
|
2120
2120
|
examples: field.cli.examples
|
|
2121
2121
|
}));
|
|
2122
|
-
|
|
2122
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
2123
2123
|
{
|
|
2124
2124
|
fields: descriptions,
|
|
2125
2125
|
render: {
|
|
@@ -2144,7 +2144,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2144
2144
|
async (options, command) => {
|
|
2145
2145
|
if (options.name !== void 0) resolveField(options.name, command);
|
|
2146
2146
|
printSettings(
|
|
2147
|
-
await new (0,
|
|
2147
|
+
await new (0, _chunkOIODIUICjs.DeeplineClient)().getPlaySettings(options.play),
|
|
2148
2148
|
options.json,
|
|
2149
2149
|
options.name
|
|
2150
2150
|
);
|
|
@@ -2175,7 +2175,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2175
2175
|
);
|
|
2176
2176
|
}
|
|
2177
2177
|
if (options.dryRun) {
|
|
2178
|
-
|
|
2178
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
2179
2179
|
{
|
|
2180
2180
|
dryRun: true,
|
|
2181
2181
|
play,
|
|
@@ -2196,7 +2196,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2196
2196
|
return;
|
|
2197
2197
|
}
|
|
2198
2198
|
printSettings(
|
|
2199
|
-
await new (0,
|
|
2199
|
+
await new (0, _chunkOIODIUICjs.DeeplineClient)().updatePlaySettings(play, patch),
|
|
2200
2200
|
options.json
|
|
2201
2201
|
);
|
|
2202
2202
|
};
|
|
@@ -2222,13 +2222,13 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2222
2222
|
"--root must be person or team; --limit must be 1\u2013100.",
|
|
2223
2223
|
{ exitCode: 2 }
|
|
2224
2224
|
);
|
|
2225
|
-
const page = await new (0,
|
|
2225
|
+
const page = await new (0, _chunkOIODIUICjs.DeeplineClient)().listPlaySettingsPaths({
|
|
2226
2226
|
root: options.root,
|
|
2227
2227
|
limit,
|
|
2228
2228
|
cursor: options.cursor
|
|
2229
2229
|
});
|
|
2230
2230
|
const nextCommand = page.hasMore ? `deepline plays settings paths --cursor '${page.cursor}'${options.root ? ` --root ${options.root}` : ""}` : null;
|
|
2231
|
-
|
|
2231
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
2232
2232
|
{
|
|
2233
2233
|
...page,
|
|
2234
2234
|
nextCommand,
|
|
@@ -2279,7 +2279,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2279
2279
|
root: _nullishCoalesce(_optionalChain([toPath, 'optionalAccess', _13 => _13.root]), () => ( "person")),
|
|
2280
2280
|
folders: _nullishCoalesce(_optionalChain([toPath, 'optionalAccess', _14 => _14.folders]), () => ( []))
|
|
2281
2281
|
};
|
|
2282
|
-
const client = new (0,
|
|
2282
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
2283
2283
|
const paths = [];
|
|
2284
2284
|
let cursor;
|
|
2285
2285
|
do {
|
|
@@ -2341,7 +2341,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2341
2341
|
moved.push(move.playName);
|
|
2342
2342
|
}
|
|
2343
2343
|
}
|
|
2344
|
-
|
|
2344
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
2345
2345
|
{
|
|
2346
2346
|
dryRun: Boolean(options.dryRun),
|
|
2347
2347
|
from: options.from,
|
|
@@ -2469,7 +2469,7 @@ function triggerLines(view) {
|
|
|
2469
2469
|
return lines;
|
|
2470
2470
|
}
|
|
2471
2471
|
function printView(view, json) {
|
|
2472
|
-
|
|
2472
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
2473
2473
|
{
|
|
2474
2474
|
...view,
|
|
2475
2475
|
render: {
|
|
@@ -2482,7 +2482,7 @@ function printView(view, json) {
|
|
|
2482
2482
|
);
|
|
2483
2483
|
}
|
|
2484
2484
|
function printResult(result, json) {
|
|
2485
|
-
|
|
2485
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
2486
2486
|
{
|
|
2487
2487
|
...result,
|
|
2488
2488
|
render: {
|
|
@@ -2512,7 +2512,7 @@ async function mutate(command, options, build) {
|
|
|
2512
2512
|
usage(command, `Invalid trigger: ${formatPlayTriggerConfigError(error)}`);
|
|
2513
2513
|
}
|
|
2514
2514
|
if (options.dryRun) {
|
|
2515
|
-
|
|
2515
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
2516
2516
|
{
|
|
2517
2517
|
dryRun: true,
|
|
2518
2518
|
play: options.play,
|
|
@@ -2531,7 +2531,7 @@ async function mutate(command, options, build) {
|
|
|
2531
2531
|
return;
|
|
2532
2532
|
}
|
|
2533
2533
|
printResult(
|
|
2534
|
-
await new (0,
|
|
2534
|
+
await new (0, _chunkOIODIUICjs.DeeplineClient)().updatePlayTriggerConfig(options.play, update),
|
|
2535
2535
|
options.json
|
|
2536
2536
|
);
|
|
2537
2537
|
}
|
|
@@ -2564,7 +2564,7 @@ function registerPlayTriggerConfigCommands(plays) {
|
|
|
2564
2564
|
}).addHelpText("after", help2);
|
|
2565
2565
|
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) => {
|
|
2566
2566
|
printView(
|
|
2567
|
-
await new (0,
|
|
2567
|
+
await new (0, _chunkOIODIUICjs.DeeplineClient)().getPlayTriggerConfig(options.play),
|
|
2568
2568
|
options.json
|
|
2569
2569
|
);
|
|
2570
2570
|
});
|
|
@@ -2608,7 +2608,7 @@ function registerPlayTriggerConfigCommands(plays) {
|
|
|
2608
2608
|
if (options.auth === void 0) {
|
|
2609
2609
|
if (secrets.length || options.header || options.signaturePrefix)
|
|
2610
2610
|
usage(setWebhook, "--secret/--header need --auth.");
|
|
2611
|
-
const current = await new (0,
|
|
2611
|
+
const current = await new (0, _chunkOIODIUICjs.DeeplineClient)().getPlayTriggerConfig(
|
|
2612
2612
|
options.play
|
|
2613
2613
|
);
|
|
2614
2614
|
return {
|
|
@@ -2685,7 +2685,7 @@ var KIND_DESCRIPTIONS = {
|
|
|
2685
2685
|
"receipt.skipped": "Saved work result: skipped.",
|
|
2686
2686
|
"runtime.event": "Other event."
|
|
2687
2687
|
};
|
|
2688
|
-
var RUN_LOGS_KIND_HELP =
|
|
2688
|
+
var RUN_LOGS_KIND_HELP = _chunkOIODIUICjs.RUN_EVENT_SEARCH_KIND_VALUES.map((kind) => ({
|
|
2689
2689
|
kind,
|
|
2690
2690
|
description: KIND_DESCRIPTIONS[kind]
|
|
2691
2691
|
}));
|
|
@@ -2822,9 +2822,9 @@ function configureRunQueryCommandErrors(command, resource) {
|
|
|
2822
2822
|
const args = program.args;
|
|
2823
2823
|
if (error.exitCode !== 0 && (resource === "events" || requestsStructuredLogs(args))) {
|
|
2824
2824
|
error.exitCode = 2;
|
|
2825
|
-
if (
|
|
2826
|
-
|
|
2827
|
-
Object.assign(new (0,
|
|
2825
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) || command.optsWithGlobals().json === true) {
|
|
2826
|
+
_chunkWSKN3U4Ujs.printJsonError.call(void 0,
|
|
2827
|
+
Object.assign(new (0, _chunkOIODIUICjs.RunEventQueryInputError)(error.message), {
|
|
2828
2828
|
exitCode: 2,
|
|
2829
2829
|
retryable: false
|
|
2830
2830
|
})
|
|
@@ -2868,14 +2868,14 @@ function parseQuery(args, resource) {
|
|
|
2868
2868
|
if (VALUE_FLAGS.has(flag)) {
|
|
2869
2869
|
const value = equals > 0 ? arg.slice(equals + 1) : args[++index];
|
|
2870
2870
|
if (!value || equals < 0 && value.startsWith("--") && flag !== "--query" && flag !== "--where") {
|
|
2871
|
-
throw new (0,
|
|
2871
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2872
2872
|
`${flag} requires a value. Use ${flag} <value>.`
|
|
2873
2873
|
);
|
|
2874
2874
|
}
|
|
2875
2875
|
if (flag === "--sum") sums.push(value);
|
|
2876
2876
|
else {
|
|
2877
2877
|
if (values[flag] !== void 0) {
|
|
2878
|
-
throw new (0,
|
|
2878
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2879
2879
|
`${flag} may only be supplied once.`
|
|
2880
2880
|
);
|
|
2881
2881
|
}
|
|
@@ -2889,12 +2889,12 @@ function parseQuery(args, resource) {
|
|
|
2889
2889
|
}
|
|
2890
2890
|
if (arg.startsWith("-")) {
|
|
2891
2891
|
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.";
|
|
2892
|
-
throw new (0,
|
|
2892
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2893
2893
|
`Unsupported query flag ${flag}. ${correction}`
|
|
2894
2894
|
);
|
|
2895
2895
|
}
|
|
2896
2896
|
if (runId !== void 0) {
|
|
2897
|
-
throw new (0,
|
|
2897
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2898
2898
|
`Unexpected argument ${JSON.stringify(arg)}. Supply one run ID.`
|
|
2899
2899
|
);
|
|
2900
2900
|
}
|
|
@@ -2902,7 +2902,7 @@ function parseQuery(args, resource) {
|
|
|
2902
2902
|
}
|
|
2903
2903
|
if (switches.has("--fields")) {
|
|
2904
2904
|
if (runId !== void 0) {
|
|
2905
|
-
throw new (0,
|
|
2905
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2906
2906
|
"--fields does not use a run ID. Omit the positional run ID."
|
|
2907
2907
|
);
|
|
2908
2908
|
}
|
|
@@ -2915,18 +2915,18 @@ function parseQuery(args, resource) {
|
|
|
2915
2915
|
)
|
|
2916
2916
|
];
|
|
2917
2917
|
if (incompatible.length) {
|
|
2918
|
-
throw new (0,
|
|
2918
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2919
2919
|
`--fields cannot be combined with ${incompatible.join(", ")}. Use --fields alone to discover the query contract.`
|
|
2920
2920
|
);
|
|
2921
2921
|
}
|
|
2922
2922
|
}
|
|
2923
2923
|
if (switches.has("--count") && values["--group-by"] !== void 0) {
|
|
2924
|
-
throw new (0,
|
|
2924
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2925
2925
|
"--count cannot be combined with --group-by. Use --group-by for counts per group."
|
|
2926
2926
|
);
|
|
2927
2927
|
}
|
|
2928
2928
|
if (sums.length && switches.has("--count")) {
|
|
2929
|
-
throw new (0,
|
|
2929
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2930
2930
|
"--sum cannot be combined with --count. Use --sum for the exact count and numeric total."
|
|
2931
2931
|
);
|
|
2932
2932
|
}
|
|
@@ -2934,7 +2934,7 @@ function parseQuery(args, resource) {
|
|
|
2934
2934
|
if (operation === "count") {
|
|
2935
2935
|
for (const flag of ["--limit", "--cursor", "--payloads"]) {
|
|
2936
2936
|
if (values[flag] !== void 0 || switches.has(flag)) {
|
|
2937
|
-
throw new (0,
|
|
2937
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2938
2938
|
`--count cannot be combined with ${flag}. Remove ${flag} to count all matching retained records.`
|
|
2939
2939
|
);
|
|
2940
2940
|
}
|
|
@@ -2969,16 +2969,16 @@ function parseQuery(args, resource) {
|
|
|
2969
2969
|
];
|
|
2970
2970
|
}
|
|
2971
2971
|
}
|
|
2972
|
-
const request =
|
|
2972
|
+
const request = _chunkOIODIUICjs.normalizeRunEventOperationRequest.call(void 0, body);
|
|
2973
2973
|
const namespace = _nullishCoalesce(values["--runtime-namespace"], () => ( (process.env.DEEPLINE_RUNTIME_ENVIRONMENT === "preview" ? process.env.DEEPLINE_RUNTIME_NAMESPACE : void 0)));
|
|
2974
2974
|
const backend = values["--runtime-backend"];
|
|
2975
2975
|
if (backend && backend !== "daytona" && backend !== "modal") {
|
|
2976
|
-
throw new (0,
|
|
2976
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2977
2977
|
"--runtime-backend must be daytona or modal."
|
|
2978
2978
|
);
|
|
2979
2979
|
}
|
|
2980
2980
|
if (backend && !namespace) {
|
|
2981
|
-
throw new (0,
|
|
2981
|
+
throw new (0, _chunkOIODIUICjs.RunEventQueryInputError)(
|
|
2982
2982
|
"--runtime-backend requires --runtime-namespace."
|
|
2983
2983
|
);
|
|
2984
2984
|
}
|
|
@@ -3025,12 +3025,12 @@ async function handleRunEventQuery(args, resource = "logs") {
|
|
|
3025
3025
|
const failure = error instanceof Error ? error : new Error(String(error));
|
|
3026
3026
|
const record3 = failure;
|
|
3027
3027
|
const status = record3.statusCode;
|
|
3028
|
-
const exitCode = error instanceof
|
|
3028
|
+
const exitCode = error instanceof _chunkOIODIUICjs.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;
|
|
3029
3029
|
const diagnostic = Object.assign(failure, {
|
|
3030
3030
|
exitCode,
|
|
3031
3031
|
retryable: exitCode === 5
|
|
3032
3032
|
});
|
|
3033
|
-
if (
|
|
3033
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) _chunkWSKN3U4Ujs.printJsonError.call(void 0, diagnostic);
|
|
3034
3034
|
else console.error(`Error: ${diagnostic.message}`);
|
|
3035
3035
|
return exitCode;
|
|
3036
3036
|
}
|
|
@@ -3045,7 +3045,7 @@ async function executeRunEventQuery(args, resource) {
|
|
|
3045
3045
|
...criteria
|
|
3046
3046
|
} = request;
|
|
3047
3047
|
const options = { ...criteria, ...runtime ? { runtime } : {} };
|
|
3048
|
-
const client = new (0,
|
|
3048
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
3049
3049
|
let result;
|
|
3050
3050
|
if (request.operation === "fields") {
|
|
3051
3051
|
result = await client.runs[resource].fields(runtime ? { runtime } : {});
|
|
@@ -3111,13 +3111,13 @@ async function executeRunEventQuery(args, resource) {
|
|
|
3111
3111
|
lines.push(`Next page: ${nextPage}`);
|
|
3112
3112
|
}
|
|
3113
3113
|
}
|
|
3114
|
-
|
|
3114
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
3115
3115
|
{
|
|
3116
3116
|
...result,
|
|
3117
3117
|
...nextPage ? { next: { page: nextPage } } : {},
|
|
3118
3118
|
render: { sections: [{ title: `run ${resource}`, lines }] }
|
|
3119
3119
|
},
|
|
3120
|
-
{ json:
|
|
3120
|
+
{ json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args), text: `${lines.join("\n")}
|
|
3121
3121
|
` }
|
|
3122
3122
|
);
|
|
3123
3123
|
return 0;
|
|
@@ -4035,7 +4035,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4035
4035
|
...text.split(/\r?\n/).map((key) => key.trim()).filter(Boolean)
|
|
4036
4036
|
);
|
|
4037
4037
|
}
|
|
4038
|
-
const response = await new (0,
|
|
4038
|
+
const response = await new (0, _chunkOIODIUICjs.DeeplineClient)().runs.getReceipts(runId, {
|
|
4039
4039
|
keys
|
|
4040
4040
|
});
|
|
4041
4041
|
const failed = response.receipts.filter(
|
|
@@ -4047,7 +4047,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4047
4047
|
JSON.stringify(response, null, 2) + "\n",
|
|
4048
4048
|
{ flag: "wx", mode: 384 }
|
|
4049
4049
|
);
|
|
4050
|
-
|
|
4050
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
4051
4051
|
{
|
|
4052
4052
|
runId,
|
|
4053
4053
|
out: options.out,
|
|
@@ -4057,7 +4057,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4057
4057
|
{ json: true }
|
|
4058
4058
|
);
|
|
4059
4059
|
} else {
|
|
4060
|
-
|
|
4060
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, { ...response }, { json: true });
|
|
4061
4061
|
}
|
|
4062
4062
|
if (failed)
|
|
4063
4063
|
process.exitCode = response.receipts.some(
|
|
@@ -4096,7 +4096,7 @@ includes nextCommand when another page is available.
|
|
|
4096
4096
|
{ exitCode: 2 }
|
|
4097
4097
|
);
|
|
4098
4098
|
}
|
|
4099
|
-
const page = await new (0,
|
|
4099
|
+
const page = await new (0, _chunkOIODIUICjs.DeeplineClient)().runs.children(parentRunId, {
|
|
4100
4100
|
launchKey: options.launchKey,
|
|
4101
4101
|
...options.cursor !== void 0 ? { cursor: options.cursor } : {},
|
|
4102
4102
|
limit
|
|
@@ -4111,7 +4111,7 @@ includes nextCommand when another page is available.
|
|
|
4111
4111
|
"--limit",
|
|
4112
4112
|
String(limit)
|
|
4113
4113
|
].join(" ") : null;
|
|
4114
|
-
|
|
4114
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
4115
4115
|
{
|
|
4116
4116
|
parentRunId,
|
|
4117
4117
|
launchKey: options.launchKey,
|
|
@@ -4147,7 +4147,7 @@ async function handleRunsHistory(options) {
|
|
|
4147
4147
|
throw new Error("--limit must be a positive integer.");
|
|
4148
4148
|
}
|
|
4149
4149
|
}
|
|
4150
|
-
const page = await new (0,
|
|
4150
|
+
const page = await new (0, _chunkOIODIUICjs.DeeplineClient)().runs.history({
|
|
4151
4151
|
cursor: options.cursor,
|
|
4152
4152
|
orgId: options.org,
|
|
4153
4153
|
search: options.search,
|
|
@@ -4163,7 +4163,7 @@ async function handleRunsHistory(options) {
|
|
|
4163
4163
|
);
|
|
4164
4164
|
}
|
|
4165
4165
|
if (page.hasMore) lines.push(`Next cursor: ${page.nextCursor}`);
|
|
4166
|
-
|
|
4166
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
4167
4167
|
{ ...page, render: { sections: [{ title: "Run history", lines }] } },
|
|
4168
4168
|
options.json ? { json: true } : {}
|
|
4169
4169
|
);
|
|
@@ -4215,12 +4215,12 @@ async function runRunsRerunCommand(runId, options) {
|
|
|
4215
4215
|
return 1;
|
|
4216
4216
|
}
|
|
4217
4217
|
}
|
|
4218
|
-
const result = await new (0,
|
|
4218
|
+
const result = await new (0, _chunkOIODIUICjs.DeeplineClient)().runs.rerun(runId, {
|
|
4219
4219
|
...idempotencyKey === void 0 ? {} : { idempotencyKey },
|
|
4220
4220
|
...inputOverrides === void 0 ? {} : { inputOverrides }
|
|
4221
4221
|
});
|
|
4222
|
-
if (
|
|
4223
|
-
|
|
4222
|
+
if (_chunkWSKN3U4Ujs.shouldEmitJson.call(void 0, options.json)) {
|
|
4223
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, result, { json: true });
|
|
4224
4224
|
} else {
|
|
4225
4225
|
console.log(
|
|
4226
4226
|
result.deduplicated === true ? `
|
|
@@ -4488,7 +4488,7 @@ function projectRunDatasetCell(value) {
|
|
|
4488
4488
|
const logicalValue = parseSerializedDatasetValue(value);
|
|
4489
4489
|
if (logicalValue === null || logicalValue === void 0) return logicalValue;
|
|
4490
4490
|
if (typeof logicalValue === "object") {
|
|
4491
|
-
return
|
|
4491
|
+
return _chunkWSKN3U4Ujs.csvSafeJsonString.call(void 0, canonicalDatasetJson(logicalValue));
|
|
4492
4492
|
}
|
|
4493
4493
|
return logicalValue;
|
|
4494
4494
|
}
|
|
@@ -6915,7 +6915,7 @@ function renderOutcome(outcome) {
|
|
|
6915
6915
|
function printResult2(input) {
|
|
6916
6916
|
const failed = input.status === "failed" || input.status === "cancelled";
|
|
6917
6917
|
if (failed) process.exitCode = 1;
|
|
6918
|
-
|
|
6918
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
6919
6919
|
{
|
|
6920
6920
|
deployment: { ...input.deployment, status: input.status },
|
|
6921
6921
|
plays: input.outcomes,
|
|
@@ -6940,7 +6940,7 @@ async function handlePlaysDeploy(directory, options) {
|
|
|
6940
6940
|
const root = await _promises.realpath.call(void 0, _path.resolve.call(void 0, _nullishCoalesce(directory, () => ( ".")))).catch(() => {
|
|
6941
6941
|
throw new Error(`No such directory: ${_path.resolve.call(void 0, _nullishCoalesce(directory, () => ( ".")))}`);
|
|
6942
6942
|
});
|
|
6943
|
-
const { http, config } =
|
|
6943
|
+
const { http, config } = _chunkWSKN3U4Ujs.getAuthedHttpClient.call(void 0, );
|
|
6944
6944
|
const deliveryId = `local:${_crypto.randomUUID.call(void 0, )}`;
|
|
6945
6945
|
const startDeployment = () => http.post("/api/v2/deployments", {
|
|
6946
6946
|
deliveryId,
|
|
@@ -6967,7 +6967,7 @@ async function handlePlaysDeploy(directory, options) {
|
|
|
6967
6967
|
},
|
|
6968
6968
|
{
|
|
6969
6969
|
bundle: bundleDeployPlayFile,
|
|
6970
|
-
fetchImpl:
|
|
6970
|
+
fetchImpl: _chunkBHEJDACQjs.fetchWithDeploymentProtection,
|
|
6971
6971
|
// The plays are already here: "opening" the source is naming it.
|
|
6972
6972
|
openSource: async () => ({
|
|
6973
6973
|
open: async () => ({ repoRoot: root })
|
|
@@ -7535,7 +7535,7 @@ function parseInputFlagValue(raw) {
|
|
|
7535
7535
|
return raw;
|
|
7536
7536
|
}
|
|
7537
7537
|
function parsePlayRunOptions(args, initialInput = null) {
|
|
7538
|
-
const selection =
|
|
7538
|
+
const selection = _chunkWSKN3U4Ujs.parseJsonFields.call(void 0, args, "run");
|
|
7539
7539
|
args = selection.args;
|
|
7540
7540
|
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.";
|
|
7541
7541
|
let filePath = null;
|
|
@@ -7547,7 +7547,7 @@ function parsePlayRunOptions(args, initialInput = null) {
|
|
|
7547
7547
|
let revisionSelector = null;
|
|
7548
7548
|
const watch = !args.includes("--no-wait");
|
|
7549
7549
|
const dryRun = args.includes("--dry-run");
|
|
7550
|
-
let jsonOutput = dryRun ?
|
|
7550
|
+
let jsonOutput = dryRun ? _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) : watch ? args.includes("--json") : _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args);
|
|
7551
7551
|
const fullJson = args.includes("--full");
|
|
7552
7552
|
const force = args.includes("--force");
|
|
7553
7553
|
const forceToolRefresh = args.includes("--force-tool-refresh");
|
|
@@ -7610,7 +7610,7 @@ function parsePlayRunOptions(args, initialInput = null) {
|
|
|
7610
7610
|
"--log-level requires one of: debug, info, warn, error."
|
|
7611
7611
|
);
|
|
7612
7612
|
}
|
|
7613
|
-
const parsed =
|
|
7613
|
+
const parsed = _chunkOIODIUICjs.parseLogLevel.call(void 0, value);
|
|
7614
7614
|
if (!parsed) {
|
|
7615
7615
|
throw new Error(
|
|
7616
7616
|
`Unsupported --log-level ${JSON.stringify(value)}. Use debug, info, warn, or error.`
|
|
@@ -7928,7 +7928,7 @@ function resolvePlayRunCliOptions(target, options, inputArgs = []) {
|
|
|
7928
7928
|
const hasExplicitLogLevel = options.logLevel !== void 0 || inputArgs.some(
|
|
7929
7929
|
(arg) => arg === "--log-level" || arg.startsWith("--log-level=")
|
|
7930
7930
|
);
|
|
7931
|
-
let logLevel = options.logLevel === void 0 ? base.logLevel :
|
|
7931
|
+
let logLevel = options.logLevel === void 0 ? base.logLevel : _chunkOIODIUICjs.parseLogLevel.call(void 0, options.logLevel);
|
|
7932
7932
|
if (!logLevel)
|
|
7933
7933
|
throw new Error("--log-level requires one of: debug, info, warn, error.");
|
|
7934
7934
|
const debugAlias = options.logs || options.debug === true || inputArgs.some(
|
|
@@ -7942,13 +7942,13 @@ function resolvePlayRunCliOptions(target, options, inputArgs = []) {
|
|
|
7942
7942
|
if (debugAlias || debugMapLatency && logLevel === "info")
|
|
7943
7943
|
logLevel = "debug";
|
|
7944
7944
|
const fullJson = _nullishCoalesce(options.full, () => ( base.fullJson));
|
|
7945
|
-
const jsonFields = options.json === void 0 ? base.jsonFields :
|
|
7946
|
-
[...fullJson ? ["--full"] : [], ...
|
|
7945
|
+
const jsonFields = options.json === void 0 ? base.jsonFields : _chunkWSKN3U4Ujs.parseJsonFields.call(void 0,
|
|
7946
|
+
[...fullJson ? ["--full"] : [], ..._chunkWSKN3U4Ujs.jsonFieldArgs.call(void 0, options.json)],
|
|
7947
7947
|
"run"
|
|
7948
7948
|
).fields;
|
|
7949
7949
|
const watch = options.wait === false ? false : base.watch;
|
|
7950
7950
|
const explicitJson = options.json !== void 0 ? options.json !== false : base.jsonOutput;
|
|
7951
|
-
const jsonOutput = dryRun || !watch ? explicitJson ||
|
|
7951
|
+
const jsonOutput = dryRun || !watch ? explicitJson || _chunkWSKN3U4Ujs.argsWantJson.call(void 0, []) : explicitJson;
|
|
7952
7952
|
const verboseLogs = Boolean(
|
|
7953
7953
|
debugAlias || logLevel === "debug" || debugMapLatency
|
|
7954
7954
|
);
|
|
@@ -7995,7 +7995,7 @@ function playAuthoringGraphPath(parent, filePath) {
|
|
|
7995
7995
|
// src/cli/renderers/local-play-execution.ts
|
|
7996
7996
|
function renderLocalPlayExecutionPlan(plan, options = {}) {
|
|
7997
7997
|
if (options.dryRun) {
|
|
7998
|
-
|
|
7998
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, { dryRun: true, ...plan }, { json: options.json });
|
|
7999
7999
|
return;
|
|
8000
8000
|
}
|
|
8001
8001
|
process.stderr.write(`Local Play execution plan: ${JSON.stringify(plan)}
|
|
@@ -8959,7 +8959,7 @@ function playStatusErrorText(status) {
|
|
|
8959
8959
|
function isRetryablePendingStartFailure(status) {
|
|
8960
8960
|
if (status.status !== "failed") return false;
|
|
8961
8961
|
if (status.runId && status.runId !== "pending") return false;
|
|
8962
|
-
return
|
|
8962
|
+
return _chunkOIODIUICjs.isTransientPlayRunReadError.call(void 0, new Error(playStatusErrorText(status)));
|
|
8963
8963
|
}
|
|
8964
8964
|
function pendingStartFailureStatus(input) {
|
|
8965
8965
|
const message = input.error instanceof Error ? input.error.message : String(input.error);
|
|
@@ -8986,13 +8986,13 @@ var PLAY_PROGRESS_HEARTBEAT_INTERVAL_MS = 15e3;
|
|
|
8986
8986
|
var PLAY_STATUS_HEARTBEAT_INTERVAL_MS = 15e3;
|
|
8987
8987
|
function watchSurfaceReaches(state, provenance, level) {
|
|
8988
8988
|
const minimumLevel = _nullishCoalesce(state.logLevel, () => ( (state.verbose ? "debug" : "info")));
|
|
8989
|
-
if (!
|
|
8989
|
+
if (!_chunkOIODIUICjs.logLevelReaches.call(void 0, level, minimumLevel)) {
|
|
8990
8990
|
return false;
|
|
8991
8991
|
}
|
|
8992
|
-
if (
|
|
8992
|
+
if (_chunkOIODIUICjs.logProvenanceReaches.call(void 0, provenance, "watch")) {
|
|
8993
8993
|
return true;
|
|
8994
8994
|
}
|
|
8995
|
-
return state.verbose === true &&
|
|
8995
|
+
return state.verbose === true && _chunkOIODIUICjs.logProvenanceReaches.call(void 0, provenance, "debug");
|
|
8996
8996
|
}
|
|
8997
8997
|
function getEventPayload(event) {
|
|
8998
8998
|
return event.payload && typeof event.payload === "object" ? event.payload : {};
|
|
@@ -9494,7 +9494,7 @@ function resolveRunPlayName(status, runId) {
|
|
|
9494
9494
|
}
|
|
9495
9495
|
function openPlayDashboard(dashboardUrl, open2) {
|
|
9496
9496
|
if (open2 && dashboardUrl) {
|
|
9497
|
-
|
|
9497
|
+
_chunkWSKN3U4Ujs.openInBrowser.call(void 0, dashboardUrl);
|
|
9498
9498
|
}
|
|
9499
9499
|
}
|
|
9500
9500
|
function printPlayLogLines(input) {
|
|
@@ -9556,7 +9556,7 @@ async function waitForPlayCompletionByWatch(input) {
|
|
|
9556
9556
|
billing: false
|
|
9557
9557
|
});
|
|
9558
9558
|
} catch (error) {
|
|
9559
|
-
if (
|
|
9559
|
+
if (_chunkOIODIUICjs.isTransientPlayRunReadError.call(void 0, error) || isAdmittedRunVisibilityDelay(error)) {
|
|
9560
9560
|
return null;
|
|
9561
9561
|
}
|
|
9562
9562
|
throw error;
|
|
@@ -9754,7 +9754,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9754
9754
|
billing: false
|
|
9755
9755
|
});
|
|
9756
9756
|
} catch (error) {
|
|
9757
|
-
if (
|
|
9757
|
+
if (_chunkOIODIUICjs.isTransientPlayRunReadError.call(void 0, error)) {
|
|
9758
9758
|
return null;
|
|
9759
9759
|
}
|
|
9760
9760
|
throw error;
|
|
@@ -9962,7 +9962,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9962
9962
|
lastPhase
|
|
9963
9963
|
});
|
|
9964
9964
|
}
|
|
9965
|
-
if (lastKnownWorkflowId &&
|
|
9965
|
+
if (lastKnownWorkflowId && _chunkOIODIUICjs.isTransientPlayRunReadError.call(void 0, error)) {
|
|
9966
9966
|
if (timeout) {
|
|
9967
9967
|
clearTimeout(timeout);
|
|
9968
9968
|
}
|
|
@@ -9998,7 +9998,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9998
9998
|
onRunAdmitted: confirmAdmission
|
|
9999
9999
|
});
|
|
10000
10000
|
}
|
|
10001
|
-
if (!lastKnownWorkflowId &&
|
|
10001
|
+
if (!lastKnownWorkflowId && _chunkOIODIUICjs.isTransientPlayRunReadError.call(void 0, error)) {
|
|
10002
10002
|
_chunkAYHLUHE5js.recordCliTrace.call(void 0, {
|
|
10003
10003
|
phase: "cli.play_start_stream_transient_failure",
|
|
10004
10004
|
ms: Date.now() - startedAt,
|
|
@@ -10097,7 +10097,7 @@ var BULKY_RETURN_KEYS = /* @__PURE__ */ new Set([
|
|
|
10097
10097
|
"logs"
|
|
10098
10098
|
]);
|
|
10099
10099
|
function formatPlayLogLine(rawLine, state) {
|
|
10100
|
-
const classified =
|
|
10100
|
+
const classified = _chunkOIODIUICjs.classifyLogLine.call(void 0, rawLine);
|
|
10101
10101
|
const line = classified.line;
|
|
10102
10102
|
const timestampMatch = line.match(/^\[([^\]]+)\]\s*(.*)$/);
|
|
10103
10103
|
const parsedTimestamp = _optionalChain([timestampMatch, 'optionalAccess', _317 => _317[1]]) ? new Date(timestampMatch[1]) : null;
|
|
@@ -10112,14 +10112,14 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
10112
10112
|
if (!state.verbose && isProviderRowWaitLogLine(line)) return null;
|
|
10113
10113
|
const providerWait = formatProviderCapacityWaitLogLine(line);
|
|
10114
10114
|
if (providerWait && !state.verbose) {
|
|
10115
|
-
return
|
|
10115
|
+
return _chunkOIODIUICjs.logLevelReaches.call(void 0, "warn", _nullishCoalesce(state.logLevel, () => ( "info"))) ? `${prefix}${providerWait}` : null;
|
|
10116
10116
|
}
|
|
10117
10117
|
const mapProgress = formatMapProgressDiagnosticLogLine(line);
|
|
10118
10118
|
if (mapProgress && !state.verbose) {
|
|
10119
|
-
return
|
|
10119
|
+
return _chunkOIODIUICjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info"))) ? `${prefix}${mapProgress}` : null;
|
|
10120
10120
|
}
|
|
10121
10121
|
if (/\[worker\] picked up run\b/.test(message)) {
|
|
10122
|
-
if (!
|
|
10122
|
+
if (!_chunkOIODIUICjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
10123
10123
|
return null;
|
|
10124
10124
|
}
|
|
10125
10125
|
if (state.emittedRunnerStarted) {
|
|
@@ -10132,7 +10132,7 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
10132
10132
|
/^Starting map over (\d+) items with (\d+) fields \(key: ([^;]+); (\d+) already satisfied; (\d+) pending\)$/
|
|
10133
10133
|
);
|
|
10134
10134
|
if (mapStart) {
|
|
10135
|
-
if (!
|
|
10135
|
+
if (!_chunkOIODIUICjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
10136
10136
|
return null;
|
|
10137
10137
|
}
|
|
10138
10138
|
const [, rows, fields2, namespace, cached, pending] = mapStart;
|
|
@@ -10142,7 +10142,7 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
10142
10142
|
/^Map completed: (\d+) results \((\d+) executed, (\d+) already satisfied\)$/
|
|
10143
10143
|
);
|
|
10144
10144
|
if (mapDone) {
|
|
10145
|
-
if (!
|
|
10145
|
+
if (!_chunkOIODIUICjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
10146
10146
|
return null;
|
|
10147
10147
|
}
|
|
10148
10148
|
const [, results, executed, cached] = mapDone;
|
|
@@ -11429,7 +11429,7 @@ function formatRecentRunLogLines(value) {
|
|
|
11429
11429
|
(line) => typeof line === "string"
|
|
11430
11430
|
);
|
|
11431
11431
|
if (tail.length === 0) return [];
|
|
11432
|
-
const shown = tail.map((line) =>
|
|
11432
|
+
const shown = tail.map((line) => _chunkOIODIUICjs.classifyLogLine.call(void 0, line)).filter(
|
|
11433
11433
|
(entry) => entry.level !== "debug" && !isProviderRowWaitLogLine(entry.line)
|
|
11434
11434
|
).slice(-8);
|
|
11435
11435
|
const total = readNonNegativeInteger(logs.totalCount);
|
|
@@ -11712,7 +11712,7 @@ function writePlayResult(status, jsonOutput, options) {
|
|
|
11712
11712
|
const hits = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _398 => _398.hits]), () => ( null));
|
|
11713
11713
|
if (jsonOutput) {
|
|
11714
11714
|
const payload2 = _optionalChain([options, 'optionalAccess', _399 => _399.fullJson]) ? status.package ? buildRunOverview(status, status) : { ...buildRunLaunch(status), diagnostics: status } : buildRunLaunch(status);
|
|
11715
|
-
|
|
11715
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
11716
11716
|
hits ? { ...payload2, hits } : payload2,
|
|
11717
11717
|
{ json: true, fields: _optionalChain([options, 'optionalAccess', _400 => _400.jsonFields]) }
|
|
11718
11718
|
);
|
|
@@ -11728,7 +11728,7 @@ function writePlayResult(status, jsonOutput, options) {
|
|
|
11728
11728
|
...buildPlayCompletionTextLines(status),
|
|
11729
11729
|
...formatRunHitsLines(hits)
|
|
11730
11730
|
];
|
|
11731
|
-
|
|
11731
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, displayPackage, {
|
|
11732
11732
|
json: false,
|
|
11733
11733
|
text: `${lines2.join("\n")}
|
|
11734
11734
|
`
|
|
@@ -11779,7 +11779,7 @@ function writePlayResult(status, jsonOutput, options) {
|
|
|
11779
11779
|
lines.push(...buildBillingRollupTextLines(status));
|
|
11780
11780
|
const compact = compactPlayStatus(status);
|
|
11781
11781
|
const payload = _optionalChain([options, 'optionalAccess', _402 => _402.fullJson]) ? status : compact;
|
|
11782
|
-
|
|
11782
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
11783
11783
|
{
|
|
11784
11784
|
...payload,
|
|
11785
11785
|
render: {
|
|
@@ -12549,7 +12549,7 @@ function writeStartedPlayRun(input) {
|
|
|
12549
12549
|
dashboardUrl: input.dashboardUrl,
|
|
12550
12550
|
package: input.package
|
|
12551
12551
|
};
|
|
12552
|
-
|
|
12552
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, buildRunLaunch(status), {
|
|
12553
12553
|
json: true,
|
|
12554
12554
|
fields: input.jsonFields
|
|
12555
12555
|
});
|
|
@@ -12571,7 +12571,7 @@ function writeStartedPlayRun(input) {
|
|
|
12571
12571
|
input.progress.writeLine(output2, process.stdout);
|
|
12572
12572
|
return;
|
|
12573
12573
|
}
|
|
12574
|
-
|
|
12574
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, input.package, {
|
|
12575
12575
|
json: false,
|
|
12576
12576
|
text: `${output2}
|
|
12577
12577
|
`
|
|
@@ -12600,7 +12600,7 @@ function writeStartedPlayRun(input) {
|
|
|
12600
12600
|
) ? [`Stop: deepline runs stop ${_chunkAID3OYVJjs.shellQuote.call(void 0, input.runId)}`] : []
|
|
12601
12601
|
];
|
|
12602
12602
|
if (input.jsonOutput) {
|
|
12603
|
-
|
|
12603
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, payload, { json: true, fields: input.jsonFields });
|
|
12604
12604
|
return;
|
|
12605
12605
|
}
|
|
12606
12606
|
if (input.dashboardUrl) {
|
|
@@ -12611,7 +12611,7 @@ function writeStartedPlayRun(input) {
|
|
|
12611
12611
|
input.progress.writeLine(output, process.stdout);
|
|
12612
12612
|
return;
|
|
12613
12613
|
}
|
|
12614
|
-
|
|
12614
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
12615
12615
|
{
|
|
12616
12616
|
...payload,
|
|
12617
12617
|
render: { sections: [{ title: "play run", lines }] }
|
|
@@ -12621,7 +12621,7 @@ function writeStartedPlayRun(input) {
|
|
|
12621
12621
|
);
|
|
12622
12622
|
}
|
|
12623
12623
|
function parsePlayCheckOptions(args) {
|
|
12624
|
-
const selection =
|
|
12624
|
+
const selection = _chunkWSKN3U4Ujs.parseJsonFields.call(void 0, args, "check");
|
|
12625
12625
|
args = selection.args;
|
|
12626
12626
|
const target = args[0];
|
|
12627
12627
|
if (!target || target.startsWith("-")) {
|
|
@@ -12633,7 +12633,7 @@ function parsePlayCheckOptions(args) {
|
|
|
12633
12633
|
if (arg !== "--json" && arg !== "--full")
|
|
12634
12634
|
throw new Error(`Unknown plays check option: ${arg}`);
|
|
12635
12635
|
}
|
|
12636
|
-
const jsonOutput =
|
|
12636
|
+
const jsonOutput = _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args);
|
|
12637
12637
|
return {
|
|
12638
12638
|
target,
|
|
12639
12639
|
jsonOutput,
|
|
@@ -12709,7 +12709,7 @@ ${PLAY_PUBLISH_USAGE}`
|
|
|
12709
12709
|
useLatest,
|
|
12710
12710
|
expectedArtifactHash,
|
|
12711
12711
|
dryRun,
|
|
12712
|
-
jsonOutput:
|
|
12712
|
+
jsonOutput: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)
|
|
12713
12713
|
};
|
|
12714
12714
|
}
|
|
12715
12715
|
var PLAY_SAVE_USAGE = "Usage: deepline plays save <play-file.ts> [--expected-artifact <hash>] [--dry-run] [--json]";
|
|
@@ -12750,7 +12750,7 @@ ${PLAY_SAVE_USAGE}`);
|
|
|
12750
12750
|
target,
|
|
12751
12751
|
expectedArtifactHash,
|
|
12752
12752
|
dryRun,
|
|
12753
|
-
jsonOutput:
|
|
12753
|
+
jsonOutput: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)
|
|
12754
12754
|
};
|
|
12755
12755
|
}
|
|
12756
12756
|
function printScheduledPlayCapacity(capacity) {
|
|
@@ -12961,7 +12961,7 @@ function printBundledRuntimeWarning(bundle) {
|
|
|
12961
12961
|
async function handlePlayCheck(args) {
|
|
12962
12962
|
const options = parsePlayCheckOptions(args);
|
|
12963
12963
|
if (!isFileTarget2(options.target)) {
|
|
12964
|
-
const client = new (0,
|
|
12964
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
12965
12965
|
try {
|
|
12966
12966
|
await assertCanonicalNamedPlayReference(client, options.target, {
|
|
12967
12967
|
command: "check"
|
|
@@ -12990,7 +12990,7 @@ async function handlePlayCheck(args) {
|
|
|
12990
12990
|
},
|
|
12991
12991
|
...options.full ? { diagnostics: { staticPipeline: _nullishCoalesce(play.staticPipeline, () => ( null)) } } : {}
|
|
12992
12992
|
};
|
|
12993
|
-
|
|
12993
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, result, {
|
|
12994
12994
|
json: options.jsonOutput,
|
|
12995
12995
|
fields: options.jsonFields,
|
|
12996
12996
|
text: renderPlayCheckOutput(result) + "\n"
|
|
@@ -13000,7 +13000,7 @@ async function handlePlayCheck(args) {
|
|
|
13000
13000
|
const resolved = _path.resolve.call(void 0, options.target);
|
|
13001
13001
|
const message = error instanceof Error && error.message ? error.message : `File not found: ${resolved}`;
|
|
13002
13002
|
if (options.jsonOutput) {
|
|
13003
|
-
|
|
13003
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
13004
13004
|
{
|
|
13005
13005
|
kind: "play_check",
|
|
13006
13006
|
checked: "named_contract",
|
|
@@ -13042,7 +13042,7 @@ async function handlePlayCheck(args) {
|
|
|
13042
13042
|
detailsCommand: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.target)} --full`,
|
|
13043
13043
|
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
|
|
13044
13044
|
});
|
|
13045
|
-
|
|
13045
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, output, {
|
|
13046
13046
|
json: options.jsonOutput,
|
|
13047
13047
|
fields: options.jsonFields,
|
|
13048
13048
|
text: renderPlayCheckOutput(output) + "\n"
|
|
@@ -13096,7 +13096,7 @@ async function checkOneExportedPlay(input) {
|
|
|
13096
13096
|
}
|
|
13097
13097
|
const playName = _nullishCoalesce(graph.root.playName, () => ( fallbackName));
|
|
13098
13098
|
const authoringErrors = collectPlayGraphAuthoringErrors(graph);
|
|
13099
|
-
const client = new (0,
|
|
13099
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
13100
13100
|
const integrationMode = resolveEvalIntegrationMode();
|
|
13101
13101
|
const importedPlays = [...graph.nodes.values()].filter((node) => node.filePath !== graph.root.filePath).map((node) => ({
|
|
13102
13102
|
playName: node.playName,
|
|
@@ -13173,7 +13173,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
13173
13173
|
);
|
|
13174
13174
|
return 0;
|
|
13175
13175
|
}
|
|
13176
|
-
client = new (0,
|
|
13176
|
+
client = new (0, _chunkOIODIUICjs.DeeplineClient)(playRunClientOptions(options));
|
|
13177
13177
|
const canDeferCompilerManifest = graph.root.importedPlayDependencies.length === 0 && !sourceGraphMentionsRunPlay(graph.root) && !inputContainsLocalFilePath(runtimeInput);
|
|
13178
13178
|
if (canDeferCompilerManifest) {
|
|
13179
13179
|
_chunkAYHLUHE5js.recordCliTrace.call(void 0, {
|
|
@@ -13372,7 +13372,7 @@ async function handleNamedRun(options, hooks) {
|
|
|
13372
13372
|
if (options.target.kind !== "name") {
|
|
13373
13373
|
throw new Error("Expected a named play run target.");
|
|
13374
13374
|
}
|
|
13375
|
-
const client = new (0,
|
|
13375
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)(playRunClientOptions(options));
|
|
13376
13376
|
const progress = _nullishCoalesce(_chunkWJYPBHTEjs.getActiveCliProgress.call(void 0, ), () => ( _chunkWJYPBHTEjs.createCliProgress.call(void 0, !options.jsonOutput)));
|
|
13377
13377
|
const playName = options.target.name;
|
|
13378
13378
|
const runtimeInput = options.input ? { ...options.input } : {};
|
|
@@ -13569,7 +13569,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
13569
13569
|
JSON.stringify({
|
|
13570
13570
|
version: 1,
|
|
13571
13571
|
admissionState: "submitted_unknown",
|
|
13572
|
-
baseUrl: new (0,
|
|
13572
|
+
baseUrl: new (0, _chunkOIODIUICjs.DeeplineClient)().baseUrl,
|
|
13573
13573
|
...intent
|
|
13574
13574
|
})
|
|
13575
13575
|
);
|
|
@@ -13798,15 +13798,36 @@ function renderRunOverviewText(overview, extras = {}) {
|
|
|
13798
13798
|
);
|
|
13799
13799
|
return `${lines.join("\n")}
|
|
13800
13800
|
|
|
13801
|
-
${
|
|
13801
|
+
${_chunkWSKN3U4Ujs.renderCommandEnvelopeText.call(void 0, { render: { sections, actions: actions2 } })}`;
|
|
13802
|
+
}
|
|
13803
|
+
var RUN_READ_TIMING_PROGRESS_INTERVAL_MS = 15e3;
|
|
13804
|
+
async function withRunReadTiming(command, stage, enabled, action) {
|
|
13805
|
+
if (!enabled) return action();
|
|
13806
|
+
const startedAt = performance.now();
|
|
13807
|
+
const elapsedMs = () => Math.round(performance.now() - startedAt);
|
|
13808
|
+
console.error(`[${command}] ${stage} started`);
|
|
13809
|
+
const progressTimer = setInterval(() => {
|
|
13810
|
+
console.error(`[${command}] ${stage} still running after ${elapsedMs()}ms`);
|
|
13811
|
+
}, RUN_READ_TIMING_PROGRESS_INTERVAL_MS);
|
|
13812
|
+
_optionalChain([progressTimer, 'access', _492 => _492.unref, 'optionalCall', _493 => _493()]);
|
|
13813
|
+
try {
|
|
13814
|
+
const result = await action();
|
|
13815
|
+
console.error(`[${command}] ${stage} completed in ${elapsedMs()}ms`);
|
|
13816
|
+
return result;
|
|
13817
|
+
} catch (error) {
|
|
13818
|
+
console.error(`[${command}] ${stage} failed after ${elapsedMs()}ms`);
|
|
13819
|
+
throw error;
|
|
13820
|
+
} finally {
|
|
13821
|
+
clearInterval(progressTimer);
|
|
13822
|
+
}
|
|
13802
13823
|
}
|
|
13803
13824
|
async function handleRunGet(args) {
|
|
13804
|
-
const selection =
|
|
13825
|
+
const selection = _chunkWSKN3U4Ujs.parseJsonFields.call(void 0,
|
|
13805
13826
|
args,
|
|
13806
13827
|
args.includes("--config") ? "config" : "get"
|
|
13807
13828
|
);
|
|
13808
13829
|
args = selection.args;
|
|
13809
|
-
const usage2 = "Usage: deepline runs get <run-id> [--json] [--full] [--input] [--config] [--web-url]";
|
|
13830
|
+
const usage2 = "Usage: deepline runs get <run-id> [--json] [--full] [--input] [--config] [--web-url] [--timing]";
|
|
13810
13831
|
let runId;
|
|
13811
13832
|
try {
|
|
13812
13833
|
runId = parseRunIdPositional(args, usage2);
|
|
@@ -13814,16 +13835,22 @@ async function handleRunGet(args) {
|
|
|
13814
13835
|
console.error(error instanceof Error ? error.message : usage2);
|
|
13815
13836
|
return 1;
|
|
13816
13837
|
}
|
|
13817
|
-
const client = new (0,
|
|
13838
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
13839
|
+
const timing = args.includes("--timing");
|
|
13818
13840
|
if (args.includes("--web-url")) {
|
|
13819
|
-
const status2 = await
|
|
13841
|
+
const status2 = await withRunReadTiming(
|
|
13842
|
+
"runs get",
|
|
13843
|
+
"status",
|
|
13844
|
+
timing,
|
|
13845
|
+
() => client.runs.get(runId, { full: false })
|
|
13846
|
+
);
|
|
13820
13847
|
const playName2 = resolveRunPlayName(status2, runId);
|
|
13821
13848
|
if (!playName2) {
|
|
13822
13849
|
console.error(`Run ${runId} does not name its play; no play page URL.`);
|
|
13823
13850
|
return 1;
|
|
13824
13851
|
}
|
|
13825
13852
|
const dashboardUrl2 = _chunkBQR6UN3Cjs.buildPlayDashboardUrl.call(void 0, client.baseUrl, playName2);
|
|
13826
|
-
|
|
13853
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
13827
13854
|
{ dashboardUrl: dashboardUrl2 },
|
|
13828
13855
|
{ json: args.includes("--json"), text: `${dashboardUrl2}
|
|
13829
13856
|
` }
|
|
@@ -13837,38 +13864,58 @@ async function handleRunGet(args) {
|
|
|
13837
13864
|
);
|
|
13838
13865
|
return 1;
|
|
13839
13866
|
}
|
|
13840
|
-
const status2 = await
|
|
13867
|
+
const status2 = await withRunReadTiming(
|
|
13868
|
+
"runs get",
|
|
13869
|
+
"configuration",
|
|
13870
|
+
timing,
|
|
13871
|
+
() => client.runs.get(runId, { configuration: true })
|
|
13872
|
+
);
|
|
13841
13873
|
if (!Object.hasOwn(status2, "contract")) {
|
|
13842
13874
|
throw new Error(
|
|
13843
13875
|
"This server does not support recorded configuration reads."
|
|
13844
13876
|
);
|
|
13845
13877
|
}
|
|
13846
|
-
|
|
13878
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
13847
13879
|
{ runId, contract: _nullishCoalesce(status2.contract, () => ( null)) },
|
|
13848
13880
|
{ json: true, fields: selection.fields }
|
|
13849
13881
|
);
|
|
13850
13882
|
return 0;
|
|
13851
13883
|
}
|
|
13852
13884
|
if (args.includes("--input")) {
|
|
13853
|
-
const input = await
|
|
13854
|
-
|
|
13885
|
+
const input = await withRunReadTiming(
|
|
13886
|
+
"runs get",
|
|
13887
|
+
"input",
|
|
13888
|
+
timing,
|
|
13889
|
+
() => client.getRunInput(runId)
|
|
13890
|
+
);
|
|
13891
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, input, { json: true });
|
|
13855
13892
|
return 0;
|
|
13856
13893
|
}
|
|
13857
13894
|
const full = args.includes("--full");
|
|
13858
|
-
const status = await
|
|
13859
|
-
|
|
13860
|
-
|
|
13861
|
-
|
|
13895
|
+
const status = await withRunReadTiming(
|
|
13896
|
+
"runs get",
|
|
13897
|
+
"status",
|
|
13898
|
+
timing,
|
|
13899
|
+
() => client.runs.get(runId, {
|
|
13900
|
+
full: false,
|
|
13901
|
+
failedLogs: args.includes("--log-failed")
|
|
13902
|
+
})
|
|
13903
|
+
);
|
|
13862
13904
|
if (status.package) _chunkZAAKSJASjs.recordPlayTermination.call(void 0, buildRunOverview(status).run);
|
|
13863
13905
|
if (!status.package) {
|
|
13864
|
-
const legacyStatus = full ? await
|
|
13865
|
-
|
|
13866
|
-
|
|
13867
|
-
|
|
13906
|
+
const legacyStatus = full ? await withRunReadTiming(
|
|
13907
|
+
"runs get",
|
|
13908
|
+
"legacy full status",
|
|
13909
|
+
timing,
|
|
13910
|
+
() => client.runs.get(runId, {
|
|
13911
|
+
full: true,
|
|
13912
|
+
failedLogs: args.includes("--log-failed")
|
|
13913
|
+
})
|
|
13914
|
+
) : status;
|
|
13868
13915
|
const legacyPlayName = resolveRunPlayName(legacyStatus, runId);
|
|
13869
13916
|
const legacyDashboardUrl = legacyPlayName ? _chunkBQR6UN3Cjs.buildPlayDashboardUrl.call(void 0, client.baseUrl, legacyPlayName) : null;
|
|
13870
|
-
if (
|
|
13871
|
-
|
|
13917
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
13918
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
13872
13919
|
{
|
|
13873
13920
|
...full ? legacyStatus : compactPlayStatus(legacyStatus),
|
|
13874
13921
|
...legacyDashboardUrl ? { dashboardUrl: legacyDashboardUrl } : {}
|
|
@@ -13878,7 +13925,7 @@ async function handleRunGet(args) {
|
|
|
13878
13925
|
} else {
|
|
13879
13926
|
writePlayResult(legacyStatus, false, { fullJson: full });
|
|
13880
13927
|
if (legacyDashboardUrl)
|
|
13881
|
-
|
|
13928
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
13882
13929
|
{ dashboardUrl: legacyDashboardUrl },
|
|
13883
13930
|
{ json: false, text: `play page: ${legacyDashboardUrl}
|
|
13884
13931
|
` }
|
|
@@ -13886,17 +13933,32 @@ async function handleRunGet(args) {
|
|
|
13886
13933
|
}
|
|
13887
13934
|
return 0;
|
|
13888
13935
|
}
|
|
13889
|
-
const fullStatus = full ? await
|
|
13936
|
+
const fullStatus = full ? await withRunReadTiming(
|
|
13937
|
+
"runs get",
|
|
13938
|
+
"full result",
|
|
13939
|
+
timing,
|
|
13940
|
+
() => client.runs.get(runId, { full: true })
|
|
13941
|
+
) : void 0;
|
|
13890
13942
|
const overview = buildRunOverview(status, fullStatus);
|
|
13891
13943
|
const [hits, credits] = await Promise.all([
|
|
13892
|
-
|
|
13893
|
-
|
|
13944
|
+
withRunReadTiming(
|
|
13945
|
+
"runs get",
|
|
13946
|
+
"row summaries",
|
|
13947
|
+
timing,
|
|
13948
|
+
() => readRunHitCounts(client, status)
|
|
13949
|
+
),
|
|
13950
|
+
withRunReadTiming(
|
|
13951
|
+
"runs get",
|
|
13952
|
+
"billing",
|
|
13953
|
+
timing,
|
|
13954
|
+
() => readRunCredits(client, runId, !TERMINAL_PLAY_STATUSES.has(status.status))
|
|
13955
|
+
)
|
|
13894
13956
|
]);
|
|
13895
13957
|
const hitLines = formatRunHitsLines(hits);
|
|
13896
|
-
const json =
|
|
13958
|
+
const json = _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args);
|
|
13897
13959
|
const playName = resolveRunPlayName(status, runId);
|
|
13898
13960
|
const dashboardUrl = playName ? _chunkBQR6UN3Cjs.buildPlayDashboardUrl.call(void 0, client.baseUrl, playName) : void 0;
|
|
13899
|
-
|
|
13961
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
13900
13962
|
{
|
|
13901
13963
|
...overview,
|
|
13902
13964
|
...dashboardUrl ? { dashboardUrl } : {},
|
|
@@ -14000,9 +14062,9 @@ async function handleRunLifecycleStatus(args) {
|
|
|
14000
14062
|
console.error(error instanceof Error ? error.message : usage2);
|
|
14001
14063
|
return 1;
|
|
14002
14064
|
}
|
|
14003
|
-
const status = await new (0,
|
|
14004
|
-
if (
|
|
14005
|
-
|
|
14065
|
+
const status = await new (0, _chunkOIODIUICjs.DeeplineClient)().runs.status(runId);
|
|
14066
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
14067
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, status, { json: true });
|
|
14006
14068
|
return 0;
|
|
14007
14069
|
}
|
|
14008
14070
|
if (!status.available) {
|
|
@@ -14042,7 +14104,7 @@ async function handleRunsRerun(args) {
|
|
|
14042
14104
|
console.error(error instanceof Error ? error.message : usage2);
|
|
14043
14105
|
return 1;
|
|
14044
14106
|
}
|
|
14045
|
-
const options = { json:
|
|
14107
|
+
const options = { json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) };
|
|
14046
14108
|
for (let index = 0; index < args.length; index += 1) {
|
|
14047
14109
|
if (args[index] === "--idempotency-key") {
|
|
14048
14110
|
options.idempotencyKey = _nullishCoalesce(args[++index], () => ( ""));
|
|
@@ -14053,7 +14115,8 @@ async function handleRunsRerun(args) {
|
|
|
14053
14115
|
return runRunsRerunCommand(runId, options);
|
|
14054
14116
|
}
|
|
14055
14117
|
async function handleRunsList(args) {
|
|
14056
|
-
const usage2 = "Usage: deepline runs list [--play <play-name>] [--node <mermaid-node-id>] [--status <status>] [--limit <count>] [--offset <count>] [--json]";
|
|
14118
|
+
const usage2 = "Usage: deepline runs list [--play <play-name>] [--node <mermaid-node-id>] [--status <status>] [--limit <count>] [--offset <count>] [--json] [--timing]";
|
|
14119
|
+
const timing = args.includes("--timing");
|
|
14057
14120
|
let playName = null;
|
|
14058
14121
|
let nodeId = null;
|
|
14059
14122
|
let statusFilter = null;
|
|
@@ -14107,8 +14170,8 @@ ${usage2}
|
|
|
14107
14170
|
Discover Plays: ${next.discover}
|
|
14108
14171
|
Active runs: ${next.running}`
|
|
14109
14172
|
);
|
|
14110
|
-
if (
|
|
14111
|
-
|
|
14173
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
14174
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14112
14175
|
{ ok: false, exitCode: 1, code: "RUN_FILTER_REQUIRED", message, next },
|
|
14113
14176
|
{ json: true }
|
|
14114
14177
|
);
|
|
@@ -14123,14 +14186,19 @@ Active runs: ${next.running}`
|
|
|
14123
14186
|
console.error("--offset requires --play.");
|
|
14124
14187
|
return 1;
|
|
14125
14188
|
}
|
|
14126
|
-
const client = new (0,
|
|
14127
|
-
const page = await
|
|
14128
|
-
|
|
14129
|
-
|
|
14130
|
-
|
|
14131
|
-
|
|
14132
|
-
|
|
14133
|
-
|
|
14189
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
14190
|
+
const page = await withRunReadTiming(
|
|
14191
|
+
"runs list",
|
|
14192
|
+
"run inventory",
|
|
14193
|
+
timing,
|
|
14194
|
+
() => client.runs.listPage({
|
|
14195
|
+
...playName ? { play: playName } : {},
|
|
14196
|
+
...statusFilter ? { status: statusFilter } : {},
|
|
14197
|
+
...nodeId ? { node: nodeId } : {},
|
|
14198
|
+
...limit !== void 0 ? { limit } : {},
|
|
14199
|
+
...offset !== void 0 ? { offset } : {}
|
|
14200
|
+
})
|
|
14201
|
+
);
|
|
14134
14202
|
const runs = page.runs.map((run) => ({
|
|
14135
14203
|
id: run.workflowId,
|
|
14136
14204
|
runId: run.workflowId,
|
|
@@ -14153,7 +14221,7 @@ Active runs: ${next.running}`
|
|
|
14153
14221
|
executionTime: run.executionTime,
|
|
14154
14222
|
billingTotalCredits: run.billingTotalCredits,
|
|
14155
14223
|
billingMaxCreditsPerRun: run.billingMaxCreditsPerRun,
|
|
14156
|
-
playName: _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(run.playName, () => ( _optionalChain([run, 'access',
|
|
14224
|
+
playName: _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(run.playName, () => ( _optionalChain([run, 'access', _494 => _494.memo, 'optionalAccess', _495 => _495.playName]))), () => ( playName)), () => ( null)),
|
|
14157
14225
|
...nodeId ? { nodeObservation: _nullishCoalesce(run.nodeObservation, () => ( null)) } : {}
|
|
14158
14226
|
}));
|
|
14159
14227
|
const lines = runs.length === 0 ? [
|
|
@@ -14192,7 +14260,7 @@ Active runs: ${next.running}`
|
|
|
14192
14260
|
nextPage ? `Next page: ${nextPage}` : "Narrow with --play <play-name> to page through runs."
|
|
14193
14261
|
);
|
|
14194
14262
|
}
|
|
14195
|
-
|
|
14263
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14196
14264
|
{
|
|
14197
14265
|
runs,
|
|
14198
14266
|
count: runs.length,
|
|
@@ -14202,11 +14270,11 @@ Active runs: ${next.running}`
|
|
|
14202
14270
|
...page.hasMore !== void 0 ? { has_more: page.hasMore, is_truncated: page.hasMore } : {},
|
|
14203
14271
|
next: {
|
|
14204
14272
|
page: nextPage,
|
|
14205
|
-
get: _optionalChain([runs, 'access',
|
|
14273
|
+
get: _optionalChain([runs, 'access', _496 => _496[0], 'optionalAccess', _497 => _497.id]) ? `deepline runs get ${runs[0].id}` : null
|
|
14206
14274
|
},
|
|
14207
14275
|
render: { sections: [{ title: "runs", lines }] }
|
|
14208
14276
|
},
|
|
14209
|
-
{ json:
|
|
14277
|
+
{ json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) }
|
|
14210
14278
|
);
|
|
14211
14279
|
return 0;
|
|
14212
14280
|
}
|
|
@@ -14236,7 +14304,7 @@ async function handleRunTail(args) {
|
|
|
14236
14304
|
console.error("--log-level requires one of: debug, info, warn, error.");
|
|
14237
14305
|
return 1;
|
|
14238
14306
|
}
|
|
14239
|
-
const parsed =
|
|
14307
|
+
const parsed = _chunkOIODIUICjs.parseLogLevel.call(void 0, value);
|
|
14240
14308
|
if (!parsed) {
|
|
14241
14309
|
console.error(
|
|
14242
14310
|
`Unsupported --log-level ${JSON.stringify(value)}. Use debug, info, warn, or error.`
|
|
@@ -14274,9 +14342,9 @@ async function handleRunTail(args) {
|
|
|
14274
14342
|
);
|
|
14275
14343
|
return 1;
|
|
14276
14344
|
}
|
|
14277
|
-
const client = new (0,
|
|
14345
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
14278
14346
|
const jsonLines = args.includes("--jsonl");
|
|
14279
|
-
const jsonOutput = !jsonLines &&
|
|
14347
|
+
const jsonOutput = !jsonLines && _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args);
|
|
14280
14348
|
const compact = args.includes("--compact");
|
|
14281
14349
|
const showLiveLogs = debug || hasExplicitLogLevel || !jsonOutput && !compact;
|
|
14282
14350
|
const compactState = {
|
|
@@ -14357,7 +14425,7 @@ async function handleRunLogs(args) {
|
|
|
14357
14425
|
]);
|
|
14358
14426
|
const cursorIndex = args.indexOf("--cursor");
|
|
14359
14427
|
const cursorValue = cursorIndex >= 0 ? args[cursorIndex + 1] : void 0;
|
|
14360
|
-
const continuesEventSearch = cursorIndex >= 0 && !(cursorValue &&
|
|
14428
|
+
const continuesEventSearch = cursorIndex >= 0 && !(cursorValue && _chunkOIODIUICjs.isRunLogsCursor.call(void 0, cursorValue));
|
|
14361
14429
|
if (!args[0] || args[0].startsWith("--") || continuesEventSearch || args.some((arg) => searchFlags.has(arg))) {
|
|
14362
14430
|
return handleRunEventSearch(args);
|
|
14363
14431
|
}
|
|
@@ -14391,7 +14459,7 @@ async function handleRunLogs(args) {
|
|
|
14391
14459
|
console.error("--log-level requires one of: debug, info, warn, error.");
|
|
14392
14460
|
return 1;
|
|
14393
14461
|
}
|
|
14394
|
-
const parsed =
|
|
14462
|
+
const parsed = _chunkOIODIUICjs.parseLogLevel.call(void 0, value);
|
|
14395
14463
|
if (!parsed) {
|
|
14396
14464
|
console.error(
|
|
14397
14465
|
`Unsupported --log-level ${JSON.stringify(value)}. Use debug, info, warn, or error.`
|
|
@@ -14438,12 +14506,12 @@ async function handleRunLogs(args) {
|
|
|
14438
14506
|
);
|
|
14439
14507
|
return 1;
|
|
14440
14508
|
}
|
|
14441
|
-
const client = new (0,
|
|
14509
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
14442
14510
|
if (outPath) {
|
|
14443
14511
|
const result2 = await client.runs.logs(runId, { all: true });
|
|
14444
|
-
const logs = result2.entries.filter((line) =>
|
|
14512
|
+
const logs = result2.entries.filter((line) => _chunkOIODIUICjs.logLevelReaches.call(void 0, _chunkOIODIUICjs.classifyLogLine.call(void 0, line).level, logLevel)).map((line) => _chunkOIODIUICjs.classifyLogLine.call(void 0, line).line);
|
|
14445
14513
|
_fs.writeFileSync.call(void 0, outPath, `${logs.join("\n")}${logs.length > 0 ? "\n" : ""}`);
|
|
14446
|
-
|
|
14514
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14447
14515
|
{
|
|
14448
14516
|
runId: result2.runId,
|
|
14449
14517
|
log_path: outPath,
|
|
@@ -14466,7 +14534,7 @@ async function handleRunLogs(args) {
|
|
|
14466
14534
|
]
|
|
14467
14535
|
}
|
|
14468
14536
|
},
|
|
14469
|
-
{ json:
|
|
14537
|
+
{ json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) }
|
|
14470
14538
|
);
|
|
14471
14539
|
return 0;
|
|
14472
14540
|
}
|
|
@@ -14497,7 +14565,7 @@ async function handleRunLogs(args) {
|
|
|
14497
14565
|
}
|
|
14498
14566
|
};
|
|
14499
14567
|
const text = buildRunLogsText(filteredResult);
|
|
14500
|
-
|
|
14568
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14501
14569
|
{
|
|
14502
14570
|
runId: result.runId,
|
|
14503
14571
|
totalCount: result.totalCount,
|
|
@@ -14521,7 +14589,7 @@ async function handleRunLogs(args) {
|
|
|
14521
14589
|
render: { sections: [{ title: "run logs", lines: entries }] }
|
|
14522
14590
|
},
|
|
14523
14591
|
{
|
|
14524
|
-
json:
|
|
14592
|
+
json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args),
|
|
14525
14593
|
text
|
|
14526
14594
|
}
|
|
14527
14595
|
);
|
|
@@ -14545,17 +14613,17 @@ function selectRunLogTailPage(result, logLevel, limit) {
|
|
|
14545
14613
|
);
|
|
14546
14614
|
}
|
|
14547
14615
|
const matching = result.entries.map((line, index) => ({ line, seq: first + index })).filter(
|
|
14548
|
-
(entry) =>
|
|
14616
|
+
(entry) => _chunkOIODIUICjs.logLevelReaches.call(void 0, _chunkOIODIUICjs.classifyLogLine.call(void 0, entry.line).level, logLevel)
|
|
14549
14617
|
);
|
|
14550
14618
|
const selected = matching.slice(-limit);
|
|
14551
14619
|
const olderMatchesExist = matching.length > selected.length;
|
|
14552
14620
|
return {
|
|
14553
14621
|
entries: selected.map((entry) => entry.line),
|
|
14554
|
-
firstSequence: _nullishCoalesce(_optionalChain([selected, 'access',
|
|
14555
|
-
lastSequence: _nullishCoalesce(_optionalChain([selected, 'access',
|
|
14622
|
+
firstSequence: _nullishCoalesce(_optionalChain([selected, 'access', _498 => _498[0], 'optionalAccess', _499 => _499.seq]), () => ( null)),
|
|
14623
|
+
lastSequence: _nullishCoalesce(_optionalChain([selected, 'access', _500 => _500.at, 'call', _501 => _501(-1), 'optionalAccess', _502 => _502.seq]), () => ( null)),
|
|
14556
14624
|
truncated: result.truncated || olderMatchesExist,
|
|
14557
14625
|
hasMore: olderMatchesExist,
|
|
14558
|
-
nextCursor: olderMatchesExist ?
|
|
14626
|
+
nextCursor: olderMatchesExist ? _chunkOIODIUICjs.encodeRunLogsCursor.call(void 0, selected[0].seq) : null
|
|
14559
14627
|
};
|
|
14560
14628
|
}
|
|
14561
14629
|
async function handleRunEventSearch(args) {
|
|
@@ -14622,7 +14690,7 @@ ${usage2}`);
|
|
|
14622
14690
|
namespace,
|
|
14623
14691
|
...backend ? { backend } : {}
|
|
14624
14692
|
} : void 0;
|
|
14625
|
-
const client = new (0,
|
|
14693
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
14626
14694
|
const result = await client.runs.searchEvents({
|
|
14627
14695
|
...runId ? { runId } : {},
|
|
14628
14696
|
...values["--since"] ? { since: values["--since"] } : {},
|
|
@@ -14694,7 +14762,7 @@ ${renderedDetails}` : ""}`;
|
|
|
14694
14762
|
"--limit",
|
|
14695
14763
|
String(limit)
|
|
14696
14764
|
].join(" ") : null;
|
|
14697
|
-
|
|
14765
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14698
14766
|
{
|
|
14699
14767
|
events,
|
|
14700
14768
|
nextCursor: result.nextCursor,
|
|
@@ -14705,19 +14773,19 @@ ${renderedDetails}` : ""}`;
|
|
|
14705
14773
|
render: { sections: [{ title: "runtime events", lines }] }
|
|
14706
14774
|
},
|
|
14707
14775
|
{
|
|
14708
|
-
json:
|
|
14776
|
+
json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args),
|
|
14709
14777
|
text: `${lines.join("\n")}${lines.length ? "\n" : ""}`
|
|
14710
14778
|
}
|
|
14711
14779
|
);
|
|
14712
14780
|
return 0;
|
|
14713
14781
|
}
|
|
14714
14782
|
function buildRunLogsText(result) {
|
|
14715
|
-
const lines = result.entries.map((line) =>
|
|
14783
|
+
const lines = result.entries.map((line) => _chunkOIODIUICjs.classifyLogLine.call(void 0, line).line);
|
|
14716
14784
|
if (result.warning) {
|
|
14717
14785
|
if (lines.length > 0) lines.push("");
|
|
14718
14786
|
lines.push(`warning: ${result.warning}`);
|
|
14719
14787
|
lines.push(
|
|
14720
|
-
`retained logs: ${_nullishCoalesce(_optionalChain([result, 'access',
|
|
14788
|
+
`retained logs: ${_nullishCoalesce(_optionalChain([result, 'access', _503 => _503.next, 'optionalAccess', _504 => _504.logs]), () => ( `deepline runs logs ${result.runId} --out run.log`))}`
|
|
14721
14789
|
);
|
|
14722
14790
|
}
|
|
14723
14791
|
return `${lines.join("\n")}${lines.length > 0 ? "\n" : ""}`;
|
|
@@ -14746,7 +14814,7 @@ async function handleRunStop(args) {
|
|
|
14746
14814
|
reason = args[++index];
|
|
14747
14815
|
}
|
|
14748
14816
|
}
|
|
14749
|
-
const client = new (0,
|
|
14817
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
14750
14818
|
const result = await client.runs.stop(runId, { reason });
|
|
14751
14819
|
const state = resolveRunStopState(result);
|
|
14752
14820
|
const hitlCleanupIncomplete = state === "cancelling" && result.hitlCancellationPending === true;
|
|
@@ -14761,7 +14829,7 @@ async function handleRunStop(args) {
|
|
|
14761
14829
|
...result.hitlCancelledCount > 0 ? [`cancelled HITL waits: ${result.hitlCancelledCount}`] : [],
|
|
14762
14830
|
`inspect: deepline runs get ${runId} --full`
|
|
14763
14831
|
];
|
|
14764
|
-
|
|
14832
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14765
14833
|
{
|
|
14766
14834
|
...cancelling,
|
|
14767
14835
|
state,
|
|
@@ -14776,7 +14844,7 @@ async function handleRunStop(args) {
|
|
|
14776
14844
|
]
|
|
14777
14845
|
}
|
|
14778
14846
|
},
|
|
14779
|
-
{ json:
|
|
14847
|
+
{ json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) }
|
|
14780
14848
|
);
|
|
14781
14849
|
return 0;
|
|
14782
14850
|
}
|
|
@@ -14793,7 +14861,7 @@ async function handleRunStop(args) {
|
|
|
14793
14861
|
];
|
|
14794
14862
|
process.stderr.write(`${lines2.join("\n")}
|
|
14795
14863
|
`);
|
|
14796
|
-
|
|
14864
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14797
14865
|
{
|
|
14798
14866
|
...result,
|
|
14799
14867
|
render: {
|
|
@@ -14808,7 +14876,7 @@ async function handleRunStop(args) {
|
|
|
14808
14876
|
]
|
|
14809
14877
|
}
|
|
14810
14878
|
},
|
|
14811
|
-
{ json:
|
|
14879
|
+
{ json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) }
|
|
14812
14880
|
);
|
|
14813
14881
|
return 1;
|
|
14814
14882
|
}
|
|
@@ -14819,12 +14887,12 @@ async function handleRunStop(args) {
|
|
|
14819
14887
|
`warning: HITL cancellation or Slack card refresh is still pending; retry 'deepline runs stop ${runId}'`
|
|
14820
14888
|
] : []
|
|
14821
14889
|
];
|
|
14822
|
-
|
|
14890
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14823
14891
|
{
|
|
14824
14892
|
...result,
|
|
14825
14893
|
render: { sections: [{ title: "run stop", lines }] }
|
|
14826
14894
|
},
|
|
14827
|
-
{ json:
|
|
14895
|
+
{ json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) }
|
|
14828
14896
|
);
|
|
14829
14897
|
return 0;
|
|
14830
14898
|
}
|
|
@@ -14874,18 +14942,18 @@ async function handleRunStopAll(args) {
|
|
|
14874
14942
|
reason = args[++index];
|
|
14875
14943
|
}
|
|
14876
14944
|
}
|
|
14877
|
-
const client = new (0,
|
|
14945
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
14878
14946
|
if (dryRun) {
|
|
14879
14947
|
const result2 = await client.runs.stopAll({ dryRun: true, reason });
|
|
14880
14948
|
const lines2 = buildStopAllDryRunTextLines(result2);
|
|
14881
|
-
|
|
14949
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14882
14950
|
{
|
|
14883
14951
|
...result2,
|
|
14884
14952
|
render: {
|
|
14885
14953
|
sections: [{ title: "workspace stop-all (dry run)", lines: lines2 }]
|
|
14886
14954
|
}
|
|
14887
14955
|
},
|
|
14888
|
-
{ json:
|
|
14956
|
+
{ json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args), text: `${lines2.join("\n")}
|
|
14889
14957
|
` }
|
|
14890
14958
|
);
|
|
14891
14959
|
return 0;
|
|
@@ -14898,17 +14966,17 @@ async function handleRunStopAll(args) {
|
|
|
14898
14966
|
...result.failed > 0 ? [`failed stops: ${result.failed}`] : [],
|
|
14899
14967
|
...result.skipped > 0 ? [`skipped: ${result.skipped}`] : []
|
|
14900
14968
|
];
|
|
14901
|
-
|
|
14969
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
14902
14970
|
{
|
|
14903
14971
|
...result,
|
|
14904
14972
|
render: { sections: [{ title: "workspace stop-all", lines }] }
|
|
14905
14973
|
},
|
|
14906
|
-
{ json:
|
|
14974
|
+
{ json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args) }
|
|
14907
14975
|
);
|
|
14908
14976
|
return result.failed > 0 || result.partial ? 1 : 0;
|
|
14909
14977
|
}
|
|
14910
14978
|
async function handleRunExport(args) {
|
|
14911
|
-
const selection =
|
|
14979
|
+
const selection = _chunkWSKN3U4Ujs.parseJsonFields.call(void 0, args, "export");
|
|
14912
14980
|
args = selection.args;
|
|
14913
14981
|
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]";
|
|
14914
14982
|
let runId;
|
|
@@ -14967,16 +15035,16 @@ async function handleRunExport(args) {
|
|
|
14967
15035
|
"INVALID_ARGUMENT"
|
|
14968
15036
|
);
|
|
14969
15037
|
}
|
|
14970
|
-
const client = new (0,
|
|
15038
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
14971
15039
|
let status = await client.getPlayStatus(runId, { full: true });
|
|
14972
15040
|
if (wait && !TERMINAL_PLAY_STATUSES.has(status.status)) {
|
|
14973
|
-
const progress = _chunkWJYPBHTEjs.createCliProgress.call(void 0, !
|
|
15041
|
+
const progress = _chunkWJYPBHTEjs.createCliProgress.call(void 0, !_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args));
|
|
14974
15042
|
try {
|
|
14975
15043
|
await waitForPlayCompletionByWatch({
|
|
14976
15044
|
client,
|
|
14977
15045
|
playName: _nullishCoalesce(extractRunPlayName(status), () => ( runId)),
|
|
14978
15046
|
workflowId: runId,
|
|
14979
|
-
jsonOutput:
|
|
15047
|
+
jsonOutput: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args),
|
|
14980
15048
|
emitLogs: false,
|
|
14981
15049
|
waitTimeoutMs,
|
|
14982
15050
|
startedAt: Date.now(),
|
|
@@ -15000,26 +15068,26 @@ async function handleRunExport(args) {
|
|
|
15000
15068
|
allowEmpty: args.includes("--allow-empty"),
|
|
15001
15069
|
format
|
|
15002
15070
|
});
|
|
15003
|
-
const source = _nullishCoalesce(_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
15004
|
-
const currentTableNotice = _optionalChain([exportResult, 'optionalAccess',
|
|
15071
|
+
const source = _nullishCoalesce(_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _505 => _505.rowsInfo, 'access', _506 => _506.source]), () => ( datasetPath)), () => ( null));
|
|
15072
|
+
const currentTableNotice = _optionalChain([exportResult, 'optionalAccess', _507 => _507.currentTable]) ? {
|
|
15005
15073
|
code: "CURRENT_SHARED_DATASET",
|
|
15006
15074
|
message: "This export is the current shared dataset and may include writes from another run.",
|
|
15007
15075
|
full_run_output_command: `deepline runs get ${status.runId} --full`
|
|
15008
15076
|
} : null;
|
|
15009
15077
|
const navigation = buildRunNavigation(status);
|
|
15010
|
-
const resolved = _optionalChain([exportResult, 'optionalAccess',
|
|
15078
|
+
const resolved = _optionalChain([exportResult, 'optionalAccess', _508 => _508.datasetInfo]);
|
|
15011
15079
|
const identity = navigation.datasets.find(
|
|
15012
|
-
(dataset) => _optionalChain([resolved, 'optionalAccess',
|
|
15080
|
+
(dataset) => _optionalChain([resolved, 'optionalAccess', _509 => _509.datasetId]) ? dataset.datasetId === resolved.datasetId : dataset.name === _optionalChain([resolved, 'optionalAccess', _510 => _510.tableNamespace])
|
|
15013
15081
|
);
|
|
15014
15082
|
const unambiguousName = identity && !identity.exportUnavailable && navigation.datasets.filter((dataset) => dataset.name === identity.name).length === 1 ? identity.name : void 0;
|
|
15015
15083
|
const exportCommand = runExportRetryCommand(
|
|
15016
15084
|
status.runId,
|
|
15017
15085
|
outPath,
|
|
15018
|
-
_nullishCoalesce(_nullishCoalesce(unambiguousName, () => ( datasetPath)), () => ( _optionalChain([exportResult, 'optionalAccess',
|
|
15086
|
+
_nullishCoalesce(_nullishCoalesce(unambiguousName, () => ( datasetPath)), () => ( _optionalChain([exportResult, 'optionalAccess', _511 => _511.datasetPath]))),
|
|
15019
15087
|
{ format }
|
|
15020
15088
|
) + (args.includes("--allow-empty") ? " --allow-empty" : "");
|
|
15021
|
-
const fileLocation = format === "json" ? { json_path: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
15022
|
-
const exportedRowOutcomes = _optionalChain([exportResult, 'optionalAccess',
|
|
15089
|
+
const fileLocation = format === "json" ? { json_path: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _512 => _512.path]), () => ( null)) } : { csv_path: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _513 => _513.path]), () => ( null)) };
|
|
15090
|
+
const exportedRowOutcomes = _optionalChain([exportResult, 'optionalAccess', _514 => _514.rowsInfo, 'access', _515 => _515.exportedRowOutcomes]);
|
|
15023
15091
|
const rowFailures = exportedRowOutcomes && exportedRowOutcomes.failed > 0 ? {
|
|
15024
15092
|
count: exportedRowOutcomes.failed,
|
|
15025
15093
|
message: "Failed rows can retain values from stages that completed earlier; those values do not prove the row succeeded.",
|
|
@@ -15039,17 +15107,17 @@ async function handleRunExport(args) {
|
|
|
15039
15107
|
...fileLocation,
|
|
15040
15108
|
format,
|
|
15041
15109
|
source,
|
|
15042
|
-
rowCount: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
15110
|
+
rowCount: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _516 => _516.rowsInfo, 'access', _517 => _517.totalRows]), () => ( null)),
|
|
15043
15111
|
...exportedRowOutcomes ? { rowOutcomes: exportedRowOutcomes } : {},
|
|
15044
15112
|
...rowFailures ? { rowFailures } : {},
|
|
15045
|
-
columns: underscoreKeysLast(_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
15113
|
+
columns: underscoreKeysLast(_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _518 => _518.rowsInfo, 'access', _519 => _519.columns]), () => ( []))),
|
|
15046
15114
|
...currentTableNotice ? { notice: currentTableNotice } : {},
|
|
15047
15115
|
...metadataOutPath ? { metadata_path: metadataOutPath } : {},
|
|
15048
15116
|
...!TERMINAL_PLAY_STATUSES.has(status.status) ? { completionCommand: `${exportCommand} --wait` } : {}
|
|
15049
15117
|
};
|
|
15050
15118
|
const lines = withRunNavigationLines(
|
|
15051
15119
|
[
|
|
15052
|
-
`Exported ${status.runId} to ${_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
15120
|
+
`Exported ${status.runId} to ${_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _520 => _520.path]), () => ( outPath))}`,
|
|
15053
15121
|
...!TERMINAL_PLAY_STATUSES.has(status.status) ? [
|
|
15054
15122
|
`Partial export: run is ${status.status}; more rows may be saved.`,
|
|
15055
15123
|
`Export after completion: ${exportCommand} --wait`
|
|
@@ -15076,8 +15144,8 @@ async function handleRunExport(args) {
|
|
|
15076
15144
|
"utf-8"
|
|
15077
15145
|
);
|
|
15078
15146
|
}
|
|
15079
|
-
|
|
15080
|
-
json:
|
|
15147
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, payload, {
|
|
15148
|
+
json: _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args),
|
|
15081
15149
|
fields: selection.fields,
|
|
15082
15150
|
text: `${lines.join("\n")}
|
|
15083
15151
|
`
|
|
@@ -15098,10 +15166,10 @@ async function handlePlayGet(args) {
|
|
|
15098
15166
|
);
|
|
15099
15167
|
return 2;
|
|
15100
15168
|
}
|
|
15101
|
-
const client = new (0,
|
|
15169
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
15102
15170
|
const explicitJson = args.includes("--json");
|
|
15103
15171
|
const sourceOutput = args.includes("--source");
|
|
15104
|
-
const jsonOutput = sourceOutput ? explicitJson :
|
|
15172
|
+
const jsonOutput = sourceOutput ? explicitJson : _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args);
|
|
15105
15173
|
const requestedRevisionFlags = [
|
|
15106
15174
|
args.includes("--working"),
|
|
15107
15175
|
args.includes("--live"),
|
|
@@ -15151,7 +15219,7 @@ async function handlePlayGet(args) {
|
|
|
15151
15219
|
...includeSource ? { source: sourceSelector } : {}
|
|
15152
15220
|
});
|
|
15153
15221
|
const source = detail.source;
|
|
15154
|
-
const resolvedSource = _nullishCoalesce(_optionalChain([source, 'optionalAccess',
|
|
15222
|
+
const resolvedSource = _nullishCoalesce(_optionalChain([source, 'optionalAccess', _521 => _521.files, 'access', _522 => _522[source.entryFile]]), () => ( ""));
|
|
15155
15223
|
let materializedFile = null;
|
|
15156
15224
|
try {
|
|
15157
15225
|
materializedFile = outPath && source ? materializeRemotePlaySource({ target, playName, source, outPath }) : null;
|
|
@@ -15161,7 +15229,7 @@ async function handlePlayGet(args) {
|
|
|
15161
15229
|
}
|
|
15162
15230
|
const loadedMessage = materializedFile ? formatLoadedPlayMessage(materializedFile) : null;
|
|
15163
15231
|
if (jsonOutput) {
|
|
15164
|
-
|
|
15232
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, {
|
|
15165
15233
|
...detail,
|
|
15166
15234
|
...materializedFile ? {
|
|
15167
15235
|
message: loadedMessage,
|
|
@@ -15202,16 +15270,16 @@ async function handlePlayGet(args) {
|
|
|
15202
15270
|
}
|
|
15203
15271
|
console.log(`Play: ${formatPlayReference(detail.play)}`);
|
|
15204
15272
|
console.log(
|
|
15205
|
-
`Working version: ${_nullishCoalesce(_optionalChain([detail, 'access',
|
|
15273
|
+
`Working version: ${_nullishCoalesce(_optionalChain([detail, 'access', _523 => _523.play, 'access', _524 => _524.workingRevision, 'optionalAccess', _525 => _525.version]), () => ( "\u2014"))}`
|
|
15206
15274
|
);
|
|
15207
|
-
console.log(`Live version: ${_nullishCoalesce(_optionalChain([detail, 'access',
|
|
15275
|
+
console.log(`Live version: ${_nullishCoalesce(_optionalChain([detail, 'access', _526 => _526.play, 'access', _527 => _527.liveRevision, 'optionalAccess', _528 => _528.version]), () => ( "\u2014"))}`);
|
|
15208
15276
|
if (detail.play.liveRevision) {
|
|
15209
15277
|
console.log(
|
|
15210
15278
|
`Live max credits per run: ${liveMaxCreditsPerRun(detail.play.liveRevision.sourceCode)}`
|
|
15211
15279
|
);
|
|
15212
15280
|
}
|
|
15213
15281
|
console.log(`Draft dirty: ${detail.play.isDraftDirty ? "yes" : "no"}`);
|
|
15214
|
-
if (detail.play.isDraftDirty && _optionalChain([detail, 'access',
|
|
15282
|
+
if (detail.play.isDraftDirty && _optionalChain([detail, 'access', _529 => _529.play, 'access', _530 => _530.liveRevision, 'optionalAccess', _531 => _531.version])) {
|
|
15215
15283
|
console.log(
|
|
15216
15284
|
` Scheduled and named runs continue to use live v${detail.play.liveRevision.version}.`
|
|
15217
15285
|
);
|
|
@@ -15223,7 +15291,7 @@ async function handlePlayGet(args) {
|
|
|
15223
15291
|
console.log(line);
|
|
15224
15292
|
}
|
|
15225
15293
|
console.log(`Updated: ${formatTimestamp(detail.play.updatedAt)}`);
|
|
15226
|
-
console.log(`Sheet rows: ${_nullishCoalesce(_optionalChain([detail, 'access',
|
|
15294
|
+
console.log(`Sheet rows: ${_nullishCoalesce(_optionalChain([detail, 'access', _532 => _532.sheetSummary, 'optionalAccess', _533 => _533.stats, 'optionalAccess', _534 => _534.total]), () => ( 0))}`);
|
|
15227
15295
|
if (detail.customerDbUrl) {
|
|
15228
15296
|
console.log(`Customer DB: ${detail.customerDbUrl}`);
|
|
15229
15297
|
}
|
|
@@ -15239,7 +15307,7 @@ async function handlePlayGet(args) {
|
|
|
15239
15307
|
return 0;
|
|
15240
15308
|
}
|
|
15241
15309
|
function formatVersionLine(version) {
|
|
15242
|
-
const revisionLabel = _nullishCoalesce(_optionalChain([version, 'access',
|
|
15310
|
+
const revisionLabel = _nullishCoalesce(_optionalChain([version, 'access', _535 => _535.artifactHash, 'optionalAccess', _536 => _536.slice, 'call', _537 => _537(0, 12)]), () => ( "unknown-revision"));
|
|
15243
15311
|
const state = [
|
|
15244
15312
|
version.isLive ? "live" : null,
|
|
15245
15313
|
version.isWorking ? "working" : null
|
|
@@ -15253,8 +15321,8 @@ async function handlePlayVersions(args) {
|
|
|
15253
15321
|
console.error("Usage: deepline plays versions --name <name> [--json]");
|
|
15254
15322
|
return 1;
|
|
15255
15323
|
}
|
|
15256
|
-
const client = new (0,
|
|
15257
|
-
const jsonOutput =
|
|
15324
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
15325
|
+
const jsonOutput = _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args);
|
|
15258
15326
|
await assertCanonicalNamedPlayReference(client, playName, {
|
|
15259
15327
|
command: "versions"
|
|
15260
15328
|
});
|
|
@@ -15262,7 +15330,7 @@ async function handlePlayVersions(args) {
|
|
|
15262
15330
|
parseReferencedPlayTarget2(playName).playName
|
|
15263
15331
|
);
|
|
15264
15332
|
if (jsonOutput) {
|
|
15265
|
-
|
|
15333
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, { versions });
|
|
15266
15334
|
return 0;
|
|
15267
15335
|
}
|
|
15268
15336
|
if (versions.length === 0) {
|
|
@@ -15294,11 +15362,11 @@ var PREBUILT_PLAY_TAG_KEYS = [
|
|
|
15294
15362
|
"signals"
|
|
15295
15363
|
];
|
|
15296
15364
|
async function handlePlayList(args) {
|
|
15297
|
-
const jsonOutput =
|
|
15365
|
+
const jsonOutput = _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args);
|
|
15298
15366
|
const showCost = args.includes("--show-cost");
|
|
15299
|
-
const client = new (0,
|
|
15367
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
15300
15368
|
const categoriesIndex = args.indexOf("--categories");
|
|
15301
|
-
const categories = categoriesIndex >= 0 ? _optionalChain([args, 'access',
|
|
15369
|
+
const categories = categoriesIndex >= 0 ? _optionalChain([args, 'access', _538 => _538[categoriesIndex + 1], 'optionalAccess', _539 => _539.trim, 'call', _540 => _540()]) : void 0;
|
|
15302
15370
|
const tags = args.flatMap((arg, index) => arg === "--tag" ? [args[index + 1]] : []).flatMap((value) => (_nullishCoalesce(value, () => ( ""))).split(",")).map((value) => value.trim()).filter(Boolean);
|
|
15303
15371
|
if (args.includes("--tag") && tags.length === 0) {
|
|
15304
15372
|
console.error(
|
|
@@ -15319,7 +15387,7 @@ async function handlePlayList(args) {
|
|
|
15319
15387
|
const cursorIndex = args.indexOf("--cursor");
|
|
15320
15388
|
const limit = limitIndex >= 0 ? Number(args[limitIndex + 1]) : void 0;
|
|
15321
15389
|
const cursor = cursorIndex >= 0 ? args[cursorIndex + 1] : void 0;
|
|
15322
|
-
if (limitIndex >= 0 && (!Number.isSafeInteger(limit) || limit < 1) || cursorIndex >= 0 && !_optionalChain([cursor, 'optionalAccess',
|
|
15390
|
+
if (limitIndex >= 0 && (!Number.isSafeInteger(limit) || limit < 1) || cursorIndex >= 0 && !_optionalChain([cursor, 'optionalAccess', _541 => _541.trim, 'call', _542 => _542()])) {
|
|
15323
15391
|
console.error("Pass a positive --limit and a non-empty --cursor.");
|
|
15324
15392
|
return 2;
|
|
15325
15393
|
}
|
|
@@ -15359,7 +15427,7 @@ async function handlePlayList(args) {
|
|
|
15359
15427
|
if (play.inputSchema || play.hasInputSchema) {
|
|
15360
15428
|
lines.push(" inputSchema: yes");
|
|
15361
15429
|
}
|
|
15362
|
-
if (_optionalChain([play, 'access',
|
|
15430
|
+
if (_optionalChain([play, 'access', _543 => _543.triggerStatus, 'optionalAccess', _544 => _544.cron])) {
|
|
15363
15431
|
lines.push(
|
|
15364
15432
|
` scheduled execution: ${cronExecutionLabel(play.triggerStatus.cron)}`
|
|
15365
15433
|
);
|
|
@@ -15379,7 +15447,7 @@ async function handlePlayList(args) {
|
|
|
15379
15447
|
} else {
|
|
15380
15448
|
lines.push(" scheduled execution: not configured");
|
|
15381
15449
|
}
|
|
15382
|
-
if (_optionalChain([play, 'access',
|
|
15450
|
+
if (_optionalChain([play, 'access', _545 => _545.triggerStatus, 'optionalAccess', _546 => _546.webhook])) {
|
|
15383
15451
|
lines.push(` webhook: ${play.triggerStatus.webhook}`);
|
|
15384
15452
|
}
|
|
15385
15453
|
if (showCost) {
|
|
@@ -15393,7 +15461,7 @@ async function handlePlayList(args) {
|
|
|
15393
15461
|
lines.push("List truncated \u2014 more plays are available.");
|
|
15394
15462
|
lines.push(`Next page: ${nextPage}`);
|
|
15395
15463
|
}
|
|
15396
|
-
|
|
15464
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
15397
15465
|
{
|
|
15398
15466
|
plays,
|
|
15399
15467
|
count: plays.length,
|
|
@@ -15410,8 +15478,8 @@ async function handlePlayList(args) {
|
|
|
15410
15478
|
return 0;
|
|
15411
15479
|
}
|
|
15412
15480
|
async function handlePlayPin(args, pinned) {
|
|
15413
|
-
const target = _optionalChain([args, 'access',
|
|
15414
|
-
const jsonOutput =
|
|
15481
|
+
const target = _optionalChain([args, 'access', _547 => _547.find, 'call', _548 => _548((arg) => !arg.startsWith("-")), 'optionalAccess', _549 => _549.trim, 'call', _550 => _550()]);
|
|
15482
|
+
const jsonOutput = _chunkWSKN3U4Ujs.argsWantJson.call(void 0, args);
|
|
15415
15483
|
const dryRun = args.includes("--dry-run");
|
|
15416
15484
|
if (!target) {
|
|
15417
15485
|
console.error(
|
|
@@ -15429,11 +15497,11 @@ async function handlePlayPin(args, pinned) {
|
|
|
15429
15497
|
const name = parsedTarget.playName;
|
|
15430
15498
|
const plan = { name, pinned, dryRun };
|
|
15431
15499
|
if (dryRun) {
|
|
15432
|
-
|
|
15500
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, plan);
|
|
15433
15501
|
return 0;
|
|
15434
15502
|
}
|
|
15435
|
-
const result = await new (0,
|
|
15436
|
-
if (jsonOutput)
|
|
15503
|
+
const result = await new (0, _chunkOIODIUICjs.DeeplineClient)().setPlayPinned(name, pinned);
|
|
15504
|
+
if (jsonOutput) _chunkWSKN3U4Ujs.printCompactJson.call(void 0, result);
|
|
15437
15505
|
else console.log(`${result.pinned ? "Pinned" : "Unpinned"} ${result.name}.`);
|
|
15438
15506
|
return 0;
|
|
15439
15507
|
}
|
|
@@ -15481,7 +15549,7 @@ function printPlayDescription(play) {
|
|
|
15481
15549
|
console.log(` ${line}`);
|
|
15482
15550
|
}
|
|
15483
15551
|
}
|
|
15484
|
-
if (_optionalChain([play, 'access',
|
|
15552
|
+
if (_optionalChain([play, 'access', _551 => _551.toolCategories, 'optionalAccess', _552 => _552.length])) {
|
|
15485
15553
|
console.log(` Tool categories: ${play.toolCategories.join(", ")}`);
|
|
15486
15554
|
}
|
|
15487
15555
|
if (play.aliases.length > 0) {
|
|
@@ -15526,7 +15594,7 @@ function printPlayDescription(play) {
|
|
|
15526
15594
|
const runtimeLimit = formatPlayRuntimeLimit(play.runtimeLimit);
|
|
15527
15595
|
if (runtimeLimit) {
|
|
15528
15596
|
console.log(
|
|
15529
|
-
` Runtime limit: ${runtimeLimit} (${_nullishCoalesce(_optionalChain([play, 'access',
|
|
15597
|
+
` Runtime limit: ${runtimeLimit} (${_nullishCoalesce(_optionalChain([play, 'access', _553 => _553.runtimeLimit, 'optionalAccess', _554 => _554.source]), () => ( "live"))})`
|
|
15530
15598
|
);
|
|
15531
15599
|
}
|
|
15532
15600
|
printScheduledPlayCapacity(play.activeScheduledPlays);
|
|
@@ -15554,17 +15622,17 @@ function formatPlayGrepMatches(matches) {
|
|
|
15554
15622
|
return matches.map((match) => `${match.field}: ${match.terms.join(", ")}`).join("; ");
|
|
15555
15623
|
}
|
|
15556
15624
|
async function handlePlayGrep(args) {
|
|
15557
|
-
const query = _optionalChain([args, 'access',
|
|
15625
|
+
const query = _optionalChain([args, 'access', _555 => _555[0], 'optionalAccess', _556 => _556.trim, 'call', _557 => _557()]);
|
|
15558
15626
|
if (!query) {
|
|
15559
15627
|
console.error("Usage: deepline plays grep <query> [--json]");
|
|
15560
15628
|
return 1;
|
|
15561
15629
|
}
|
|
15562
|
-
const client = new (0,
|
|
15630
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
15563
15631
|
const results = (await client.listPlays({ grep: query })).map(
|
|
15564
15632
|
summarizePlayGrepResult
|
|
15565
15633
|
);
|
|
15566
|
-
if (
|
|
15567
|
-
|
|
15634
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
15635
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, {
|
|
15568
15636
|
plays: results,
|
|
15569
15637
|
count: results.length,
|
|
15570
15638
|
query,
|
|
@@ -15578,7 +15646,7 @@ async function handlePlayGrep(args) {
|
|
|
15578
15646
|
`
|
|
15579
15647
|
);
|
|
15580
15648
|
for (const result of results) {
|
|
15581
|
-
console.log(_optionalChain([result, 'access',
|
|
15649
|
+
console.log(_optionalChain([result, 'access', _558 => _558.displayName, 'optionalAccess', _559 => _559.trim, 'call', _560 => _560()]) || result.name);
|
|
15582
15650
|
const matches = formatPlayGrepMatches(result.matches);
|
|
15583
15651
|
if (matches) console.log(` Matched: ${matches}`);
|
|
15584
15652
|
console.log(` Describe: ${result.describe}`);
|
|
@@ -15587,7 +15655,7 @@ async function handlePlayGrep(args) {
|
|
|
15587
15655
|
return 0;
|
|
15588
15656
|
}
|
|
15589
15657
|
async function handlePlayDescribe(args) {
|
|
15590
|
-
const selection =
|
|
15658
|
+
const selection = _chunkWSKN3U4Ujs.parseJsonFields.call(void 0, args, "describe");
|
|
15591
15659
|
args = selection.args;
|
|
15592
15660
|
const playName = args[0];
|
|
15593
15661
|
if (!playName) {
|
|
@@ -15621,8 +15689,8 @@ async function handlePlayDescribe(args) {
|
|
|
15621
15689
|
`deepline plays check ${playName}`,
|
|
15622
15690
|
...definedName ? [`deepline describe <workspace>/${definedName}`] : []
|
|
15623
15691
|
];
|
|
15624
|
-
if (
|
|
15625
|
-
|
|
15692
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
15693
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, {
|
|
15626
15694
|
ok: false,
|
|
15627
15695
|
error: { message },
|
|
15628
15696
|
next
|
|
@@ -15636,7 +15704,7 @@ async function handlePlayDescribe(args) {
|
|
|
15636
15704
|
}
|
|
15637
15705
|
return 2;
|
|
15638
15706
|
}
|
|
15639
|
-
const client = new (0,
|
|
15707
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
15640
15708
|
await assertCanonicalNamedPlayReference(client, playName, {
|
|
15641
15709
|
command: "describe"
|
|
15642
15710
|
});
|
|
@@ -15646,9 +15714,9 @@ async function handlePlayDescribe(args) {
|
|
|
15646
15714
|
compact: args.includes("--compact")
|
|
15647
15715
|
}
|
|
15648
15716
|
);
|
|
15649
|
-
if (
|
|
15650
|
-
if (selection.fields)
|
|
15651
|
-
else
|
|
15717
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
15718
|
+
if (selection.fields) _chunkWSKN3U4Ujs.printJson.call(void 0, play, selection.fields);
|
|
15719
|
+
else _chunkWSKN3U4Ujs.printCompactJson.call(void 0, play);
|
|
15652
15720
|
return 0;
|
|
15653
15721
|
}
|
|
15654
15722
|
printPlayDescription(play);
|
|
@@ -15692,7 +15760,7 @@ async function handlePlaySave(args) {
|
|
|
15692
15760
|
next: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.target)}`
|
|
15693
15761
|
};
|
|
15694
15762
|
if (options.jsonOutput) {
|
|
15695
|
-
|
|
15763
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result);
|
|
15696
15764
|
} else {
|
|
15697
15765
|
console.error(result.message);
|
|
15698
15766
|
console.error(` checked artifact: ${result.expectedArtifactHash}`);
|
|
@@ -15714,7 +15782,7 @@ async function handlePlaySave(args) {
|
|
|
15714
15782
|
};
|
|
15715
15783
|
if (options.dryRun) {
|
|
15716
15784
|
if (options.jsonOutput) {
|
|
15717
|
-
|
|
15785
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, dryRun);
|
|
15718
15786
|
} else {
|
|
15719
15787
|
console.log(`Dry run: ${playName}`);
|
|
15720
15788
|
console.log(` source: ${dryRun.sourceHash}`);
|
|
@@ -15723,7 +15791,7 @@ async function handlePlaySave(args) {
|
|
|
15723
15791
|
}
|
|
15724
15792
|
return 0;
|
|
15725
15793
|
}
|
|
15726
|
-
const client = new (0,
|
|
15794
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
15727
15795
|
try {
|
|
15728
15796
|
await _chunkAYHLUHE5js.traceCliSpan.call(void 0,
|
|
15729
15797
|
"cli.play_save_compile_manifests",
|
|
@@ -15759,7 +15827,7 @@ async function handlePlaySave(args) {
|
|
|
15759
15827
|
}
|
|
15760
15828
|
};
|
|
15761
15829
|
if (options.jsonOutput) {
|
|
15762
|
-
|
|
15830
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result);
|
|
15763
15831
|
} else {
|
|
15764
15832
|
console.log(
|
|
15765
15833
|
`\u2713 Saved ${playName} working draft as v${_nullishCoalesce(result.version, () => ( "?"))}`
|
|
@@ -15785,7 +15853,7 @@ async function handlePlayPublish(args) {
|
|
|
15785
15853
|
}
|
|
15786
15854
|
const { target: playName, useLatest } = options;
|
|
15787
15855
|
let revisionId = options.revisionId;
|
|
15788
|
-
const client = new (0,
|
|
15856
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
15789
15857
|
if (isFileTarget2(playName)) {
|
|
15790
15858
|
if (revisionId || useLatest) {
|
|
15791
15859
|
console.error(
|
|
@@ -15817,7 +15885,7 @@ async function handlePlayPublish(args) {
|
|
|
15817
15885
|
next: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, playName)}`
|
|
15818
15886
|
};
|
|
15819
15887
|
if (options.jsonOutput) {
|
|
15820
|
-
|
|
15888
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result3);
|
|
15821
15889
|
} else {
|
|
15822
15890
|
console.error(result3.message);
|
|
15823
15891
|
console.error(` checked artifact: ${result3.expectedArtifactHash}`);
|
|
@@ -15840,7 +15908,7 @@ async function handlePlayPublish(args) {
|
|
|
15840
15908
|
};
|
|
15841
15909
|
if (options.dryRun) {
|
|
15842
15910
|
if (options.jsonOutput) {
|
|
15843
|
-
|
|
15911
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, dryRun);
|
|
15844
15912
|
} else {
|
|
15845
15913
|
console.log(`Dry run: ${rootPlayName}`);
|
|
15846
15914
|
console.log(` source: ${dryRun.sourceHash}`);
|
|
@@ -15898,17 +15966,17 @@ async function handlePlayPublish(args) {
|
|
|
15898
15966
|
artifactHash,
|
|
15899
15967
|
liveVersion: _nullishCoalesce(published.version, () => ( null)),
|
|
15900
15968
|
revisionId: _nullishCoalesce(published.revisionId, () => ( null)),
|
|
15901
|
-
previousLiveVersion: _nullishCoalesce(_optionalChain([previousLive, 'optionalAccess',
|
|
15902
|
-
previousArtifactHash: _nullishCoalesce(_optionalChain([previousLive, 'optionalAccess',
|
|
15969
|
+
previousLiveVersion: _nullishCoalesce(_optionalChain([previousLive, 'optionalAccess', _561 => _561.version]), () => ( null)),
|
|
15970
|
+
previousArtifactHash: _nullishCoalesce(_optionalChain([previousLive, 'optionalAccess', _562 => _562.artifactHash]), () => ( null)),
|
|
15903
15971
|
sourceBytes: {
|
|
15904
|
-
before: _optionalChain([previousLive, 'optionalAccess',
|
|
15972
|
+
before: _optionalChain([previousLive, 'optionalAccess', _563 => _563.sourceCode]) ? Buffer.byteLength(previousLive.sourceCode, "utf8") : null,
|
|
15905
15973
|
after: Buffer.byteLength(graph.root.sourceCode, "utf8")
|
|
15906
15974
|
},
|
|
15907
15975
|
triggerMetadata: _nullishCoalesce(published.triggerMetadata, () => ( null)),
|
|
15908
15976
|
triggerBindings: _nullishCoalesce(published.triggerBindings, () => ( []))
|
|
15909
15977
|
};
|
|
15910
15978
|
if (options.jsonOutput) {
|
|
15911
|
-
|
|
15979
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result2);
|
|
15912
15980
|
} else {
|
|
15913
15981
|
printPublishReceipt({
|
|
15914
15982
|
name: rootPlayName,
|
|
@@ -15939,14 +16007,14 @@ async function handlePlayPublish(args) {
|
|
|
15939
16007
|
revisionId: _nullishCoalesce(revisionId, () => ( null)),
|
|
15940
16008
|
latest: useLatest
|
|
15941
16009
|
};
|
|
15942
|
-
|
|
16010
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result2);
|
|
15943
16011
|
return 0;
|
|
15944
16012
|
}
|
|
15945
16013
|
const resolvedName = parseReferencedPlayTarget2(playName).playName;
|
|
15946
16014
|
if (useLatest) {
|
|
15947
16015
|
const versions = await client.listPlayVersions(resolvedName);
|
|
15948
16016
|
const latest = versions[0];
|
|
15949
|
-
if (!_optionalChain([latest, 'optionalAccess',
|
|
16017
|
+
if (!_optionalChain([latest, 'optionalAccess', _564 => _564._id])) {
|
|
15950
16018
|
console.error(`No saved revisions found for ${resolvedName}.`);
|
|
15951
16019
|
return 1;
|
|
15952
16020
|
}
|
|
@@ -15963,7 +16031,7 @@ async function handlePlayPublish(args) {
|
|
|
15963
16031
|
revisionId ? { revisionId } : {}
|
|
15964
16032
|
);
|
|
15965
16033
|
if (options.jsonOutput) {
|
|
15966
|
-
|
|
16034
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result);
|
|
15967
16035
|
} else {
|
|
15968
16036
|
printPublishReceipt({
|
|
15969
16037
|
name: result.name,
|
|
@@ -16003,7 +16071,7 @@ async function handlePlayDelete(args) {
|
|
|
16003
16071
|
);
|
|
16004
16072
|
return 2;
|
|
16005
16073
|
}
|
|
16006
|
-
const client = new (0,
|
|
16074
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
16007
16075
|
let detail;
|
|
16008
16076
|
try {
|
|
16009
16077
|
detail = await client.getPlay(parseReferencedPlayTarget2(playName).playName);
|
|
@@ -16027,8 +16095,8 @@ async function handlePlayDelete(args) {
|
|
|
16027
16095
|
name: resolvedName,
|
|
16028
16096
|
plannedMutation: "move saved org-owned play to Trash and stop triggers"
|
|
16029
16097
|
};
|
|
16030
|
-
if (
|
|
16031
|
-
|
|
16098
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
16099
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result2);
|
|
16032
16100
|
} else {
|
|
16033
16101
|
process.stdout.write(
|
|
16034
16102
|
`Dry run: would move ${result2.name} to Trash and stop its active triggers.
|
|
@@ -16038,8 +16106,8 @@ async function handlePlayDelete(args) {
|
|
|
16038
16106
|
return 0;
|
|
16039
16107
|
}
|
|
16040
16108
|
const result = await client.deletePlay(resolvedName);
|
|
16041
|
-
if (
|
|
16042
|
-
|
|
16109
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
16110
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result);
|
|
16043
16111
|
return result.archived || result.alreadyArchived ? 0 : 4;
|
|
16044
16112
|
}
|
|
16045
16113
|
if (result.alreadyArchived) {
|
|
@@ -16078,13 +16146,13 @@ async function handlePlayRestore(args) {
|
|
|
16078
16146
|
);
|
|
16079
16147
|
return 2;
|
|
16080
16148
|
}
|
|
16081
|
-
const client = new (0,
|
|
16149
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
16082
16150
|
try {
|
|
16083
16151
|
const result = await client.restorePlay(
|
|
16084
16152
|
parseReferencedPlayTarget2(playName).playName
|
|
16085
16153
|
);
|
|
16086
|
-
if (
|
|
16087
|
-
|
|
16154
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
16155
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, result);
|
|
16088
16156
|
return result.restored || result.alreadyActive ? 0 : 4;
|
|
16089
16157
|
}
|
|
16090
16158
|
if (result.alreadyActive) {
|
|
@@ -16197,21 +16265,21 @@ Common commands:
|
|
|
16197
16265
|
resume: `deepline plays resume-submission ${_chunkAID3OYVJjs.shellQuote.call(void 0, path)} --json`
|
|
16198
16266
|
}
|
|
16199
16267
|
};
|
|
16200
|
-
|
|
16268
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0, result2, {
|
|
16201
16269
|
json: options.json,
|
|
16202
16270
|
text: `Submission ${saved.workflowId}: admission is unknown. ${result2.next.inspect}
|
|
16203
16271
|
`
|
|
16204
16272
|
});
|
|
16205
16273
|
return;
|
|
16206
16274
|
}
|
|
16207
|
-
const client = new (0,
|
|
16275
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
16208
16276
|
if (new URL(saved.baseUrl).origin !== new URL(client.baseUrl).origin) {
|
|
16209
16277
|
throw new Error(
|
|
16210
16278
|
"The submission belongs to a different API origin. Select its original host before recovery."
|
|
16211
16279
|
);
|
|
16212
16280
|
}
|
|
16213
16281
|
const result = await client.startPlayRun(saved.request);
|
|
16214
|
-
|
|
16282
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
16215
16283
|
{ ...result },
|
|
16216
16284
|
{
|
|
16217
16285
|
json: options.json,
|
|
@@ -16247,7 +16315,7 @@ Examples:
|
|
|
16247
16315
|
).action(async (target, options) => {
|
|
16248
16316
|
process.exitCode = await handlePlayCheck([
|
|
16249
16317
|
target,
|
|
16250
|
-
...
|
|
16318
|
+
..._chunkWSKN3U4Ujs.jsonFieldArgs.call(void 0, options.json),
|
|
16251
16319
|
...options.full ? ["--full"] : []
|
|
16252
16320
|
]);
|
|
16253
16321
|
});
|
|
@@ -16488,9 +16556,9 @@ Examples:
|
|
|
16488
16556
|
const limit = Number(options.historyLimit);
|
|
16489
16557
|
if (!Number.isInteger(limit) || limit < 1 || limit > 30)
|
|
16490
16558
|
throw new Error("--history-limit must be an integer from 1 to 30.");
|
|
16491
|
-
const client = new (0,
|
|
16559
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
16492
16560
|
if (options.binding) {
|
|
16493
|
-
|
|
16561
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0,
|
|
16494
16562
|
await client.getPlayTriggerHistory(options.binding, { limit })
|
|
16495
16563
|
);
|
|
16496
16564
|
return;
|
|
@@ -16498,7 +16566,7 @@ Examples:
|
|
|
16498
16566
|
const result = await client.listPlayTriggerInventory({
|
|
16499
16567
|
cursor: options.cursor
|
|
16500
16568
|
});
|
|
16501
|
-
|
|
16569
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, {
|
|
16502
16570
|
...result,
|
|
16503
16571
|
next: result.isDone ? null : `deepline plays triggers --cursor ${JSON.stringify(result.continueCursor)}`
|
|
16504
16572
|
});
|
|
@@ -16545,7 +16613,7 @@ Examples:
|
|
|
16545
16613
|
if (options.groupBy !== "kind" && options.groupBy !== "trigger_source") {
|
|
16546
16614
|
throw new Error("--group-by must be kind or trigger_source.");
|
|
16547
16615
|
}
|
|
16548
|
-
const result = await new (0,
|
|
16616
|
+
const result = await new (0, _chunkOIODIUICjs.DeeplineClient)().getPlaysActivity({
|
|
16549
16617
|
timeZone: options.timeZone,
|
|
16550
16618
|
days,
|
|
16551
16619
|
...options.endDate ? { endDate: options.endDate } : {},
|
|
@@ -16559,7 +16627,7 @@ Examples:
|
|
|
16559
16627
|
`${bucket.key} ${groups} failed_play_runs=${bucket.failedPlayRuns} ${coverage}`
|
|
16560
16628
|
);
|
|
16561
16629
|
}
|
|
16562
|
-
|
|
16630
|
+
_chunkWSKN3U4Ujs.printCommandEnvelope.call(void 0,
|
|
16563
16631
|
{ ...result },
|
|
16564
16632
|
{
|
|
16565
16633
|
json: Boolean(options.json),
|
|
@@ -16588,7 +16656,7 @@ Examples:
|
|
|
16588
16656
|
false
|
|
16589
16657
|
);
|
|
16590
16658
|
});
|
|
16591
|
-
|
|
16659
|
+
_chunkD5KFELCCjs.registerDeprecatedSearchCommand.call(void 0,
|
|
16592
16660
|
play,
|
|
16593
16661
|
(options) => options.all ? ["plays"] : ["prebuilts"]
|
|
16594
16662
|
);
|
|
@@ -16631,7 +16699,7 @@ Examples:
|
|
|
16631
16699
|
);
|
|
16632
16700
|
_chunkZAAKSJASjs.addDescribeOptions.call(void 0, describeCommand, { json: false }).action(
|
|
16633
16701
|
async (target, options) => {
|
|
16634
|
-
const ownView = () => handlePlayDescribe(
|
|
16702
|
+
const ownView = () => handlePlayDescribe(_chunkWSKN3U4Ujs.describeArgs.call(void 0, target, options));
|
|
16635
16703
|
const [flagText] = [options.json].filter(
|
|
16636
16704
|
(value) => typeof value === "string"
|
|
16637
16705
|
);
|
|
@@ -16642,7 +16710,7 @@ Examples:
|
|
|
16642
16710
|
process.exitCode = await ownView();
|
|
16643
16711
|
return;
|
|
16644
16712
|
}
|
|
16645
|
-
const { describeAnything } = await Promise.resolve().then(() => _interopRequireWildcard(require("./describe-
|
|
16713
|
+
const { describeAnything } = await Promise.resolve().then(() => _interopRequireWildcard(require("./describe-HSHMULQM.js")));
|
|
16646
16714
|
process.exitCode = await describeAnything(
|
|
16647
16715
|
name,
|
|
16648
16716
|
{
|
|
@@ -16760,7 +16828,7 @@ Examples:
|
|
|
16760
16828
|
deepline plays deployments <deployment-id>
|
|
16761
16829
|
`
|
|
16762
16830
|
).option("--limit <n>", "Max rows (default 50)").option("--json", "Emit JSON output").action(
|
|
16763
|
-
async (id, options) => id ?
|
|
16831
|
+
async (id, options) => id ? _chunkLD7WUOAZjs.handleDeploymentGet.call(void 0, id, options) : _chunkLD7WUOAZjs.handleDeploymentsList.call(void 0, options)
|
|
16764
16832
|
);
|
|
16765
16833
|
addPublishHelp(
|
|
16766
16834
|
play.command("publish <target>").description(
|
|
@@ -16895,14 +16963,14 @@ Examples:
|
|
|
16895
16963
|
const limit = Number(options.limit);
|
|
16896
16964
|
if (!Number.isSafeInteger(limit) || limit < 1 || limit > 1e3)
|
|
16897
16965
|
throw new Error("--limit must be an integer from 1 to 1000.");
|
|
16898
|
-
const result = await new (0,
|
|
16966
|
+
const result = await new (0, _chunkOIODIUICjs.DeeplineClient)().runs.rowHistory({
|
|
16899
16967
|
playName: options.play,
|
|
16900
16968
|
runId,
|
|
16901
16969
|
tableNamespace: options.dataset,
|
|
16902
16970
|
limit,
|
|
16903
16971
|
cursor: options.cursor
|
|
16904
16972
|
});
|
|
16905
|
-
|
|
16973
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, {
|
|
16906
16974
|
...result,
|
|
16907
16975
|
...result.nextCursor ? {
|
|
16908
16976
|
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`
|
|
@@ -16938,6 +17006,8 @@ Notes:
|
|
|
16938
17006
|
--json run.status,datasets.name,actions selects fields without flattening.
|
|
16939
17007
|
Selection changes stdout only, not the server query. Optional missing paths
|
|
16940
17008
|
are omitted; array positions are preserved. --json diagnostics needs --full.
|
|
17009
|
+
--timing writes each read phase and periodic long-read updates to stderr;
|
|
17010
|
+
JSON stdout stays unchanged.
|
|
16941
17011
|
dashboardUrl (text: "play page:") links the run's play page; link it in a
|
|
16942
17012
|
final answer. --web-url prints only that URL (with --json: {"dashboardUrl"}).
|
|
16943
17013
|
|
|
@@ -16962,16 +17032,20 @@ Examples:
|
|
|
16962
17032
|
).option(
|
|
16963
17033
|
"--config",
|
|
16964
17034
|
"Explicitly print the recorded configuration, without full results"
|
|
16965
|
-
).option("--web-url", "Print only the run's play page URL").
|
|
17035
|
+
).option("--web-url", "Print only the run's play page URL").option(
|
|
17036
|
+
"--timing",
|
|
17037
|
+
"Report read phases and periodic long-read updates to stderr"
|
|
17038
|
+
).addOption(
|
|
16966
17039
|
new (0, _commander.Option)("--log-failed", "Attach terminal-failure logs").hideHelp()
|
|
16967
17040
|
).action(async (runId, options) => {
|
|
16968
17041
|
process.exitCode = await handleRunGet([
|
|
16969
17042
|
runId,
|
|
16970
|
-
...
|
|
17043
|
+
..._chunkWSKN3U4Ujs.jsonFieldArgs.call(void 0, options.json),
|
|
16971
17044
|
...options.webUrl ? ["--web-url"] : [],
|
|
16972
17045
|
...options.full ? ["--full"] : [],
|
|
16973
17046
|
...options.input ? ["--input"] : [],
|
|
16974
17047
|
...options.config ? ["--config"] : [],
|
|
17048
|
+
...options.timing ? ["--timing"] : [],
|
|
16975
17049
|
...options.logFailed ? ["--log-failed"] : []
|
|
16976
17050
|
]);
|
|
16977
17051
|
});
|
|
@@ -17017,6 +17091,7 @@ Notes:
|
|
|
17017
17091
|
JSON runs[].id is the public ID accepted by runs get, watch, export, and stop.
|
|
17018
17092
|
runId and workflowId are compatibility aliases; temporalRunId is not the public ID.
|
|
17019
17093
|
Use the ID returned by plays run for your execution, not the latest inventory entry.
|
|
17094
|
+
--timing writes the inventory request duration and periodic long-read updates to stderr.
|
|
17020
17095
|
|
|
17021
17096
|
Examples:
|
|
17022
17097
|
deepline runs list --play my-play
|
|
@@ -17024,14 +17099,18 @@ Examples:
|
|
|
17024
17099
|
deepline runs list --play my-play --status failed --compact
|
|
17025
17100
|
deepline runs list --status running --compact
|
|
17026
17101
|
`
|
|
17027
|
-
).option("--play <name>", "Play name to filter runs").option("--status <status>", "Filter by run status").option("--limit <count>", "Maximum runs to return").option("--offset <count>", "Zero-based page offset (requires --play)").option("--compact", "Drop verbose fields from JSON output").option("--json", "Emit JSON output").
|
|
17102
|
+
).option("--play <name>", "Play name to filter runs").option("--status <status>", "Filter by run status").option("--limit <count>", "Maximum runs to return").option("--offset <count>", "Zero-based page offset (requires --play)").option("--compact", "Drop verbose fields from JSON output").option("--json", "Emit JSON output").option(
|
|
17103
|
+
"--timing",
|
|
17104
|
+
"Report the inventory request duration and periodic long-read updates to stderr"
|
|
17105
|
+
).action(async (options) => {
|
|
17028
17106
|
process.exitCode = await handleRunsList([
|
|
17029
17107
|
...options.play ? ["--play", options.play] : [],
|
|
17030
17108
|
...options.status ? ["--status", options.status] : [],
|
|
17031
17109
|
...options.limit ? ["--limit", options.limit] : [],
|
|
17032
17110
|
...options.offset ? ["--offset", options.offset] : [],
|
|
17033
17111
|
...options.compact ? ["--compact"] : [],
|
|
17034
|
-
...options.json ? ["--json"] : []
|
|
17112
|
+
...options.json ? ["--json"] : [],
|
|
17113
|
+
...options.timing ? ["--timing"] : []
|
|
17035
17114
|
]);
|
|
17036
17115
|
});
|
|
17037
17116
|
runs.command("stop-all").description("Stop active play runs in the current workspace.").addHelpText(
|
|
@@ -17246,7 +17325,7 @@ Examples:
|
|
|
17246
17325
|
...options.allowEmpty ? ["--allow-empty"] : [],
|
|
17247
17326
|
...options.wait ? ["--wait"] : [],
|
|
17248
17327
|
...options.timeoutMs ? ["--timeout-ms", options.timeoutMs] : [],
|
|
17249
|
-
...
|
|
17328
|
+
..._chunkWSKN3U4Ujs.jsonFieldArgs.call(void 0, options.json)
|
|
17250
17329
|
]);
|
|
17251
17330
|
});
|
|
17252
17331
|
const share = play.command("share").description(
|
|
@@ -17387,8 +17466,8 @@ function absolutePublicPlayUrl(path) {
|
|
|
17387
17466
|
}
|
|
17388
17467
|
function shareUrlFields(status) {
|
|
17389
17468
|
return {
|
|
17390
|
-
publicUrl: absolutePublicPlayUrl(_optionalChain([status, 'access',
|
|
17391
|
-
canonicalUrl: absolutePublicPlayUrl(_optionalChain([status, 'access',
|
|
17469
|
+
publicUrl: absolutePublicPlayUrl(_optionalChain([status, 'access', _565 => _565.share, 'optionalAccess', _566 => _566.publicPath])),
|
|
17470
|
+
canonicalUrl: absolutePublicPlayUrl(_optionalChain([status, 'access', _567 => _567.share, 'optionalAccess', _568 => _568.canonicalPath]))
|
|
17392
17471
|
};
|
|
17393
17472
|
}
|
|
17394
17473
|
function shareStatusForOutput(status) {
|
|
@@ -17412,10 +17491,10 @@ async function handlePlayShareStatus(args) {
|
|
|
17412
17491
|
return 2;
|
|
17413
17492
|
}
|
|
17414
17493
|
const name = parseReferencedPlayTarget2(target).playName;
|
|
17415
|
-
const status = await new (0,
|
|
17494
|
+
const status = await new (0, _chunkOIODIUICjs.DeeplineClient)().getSharePage(name);
|
|
17416
17495
|
const outputStatus = shareStatusForOutput(status);
|
|
17417
|
-
if (
|
|
17418
|
-
|
|
17496
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
17497
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, outputStatus);
|
|
17419
17498
|
return 0;
|
|
17420
17499
|
}
|
|
17421
17500
|
if (!outputStatus.share) {
|
|
@@ -17454,7 +17533,7 @@ async function handlePlaySharePublish(args) {
|
|
|
17454
17533
|
return 2;
|
|
17455
17534
|
}
|
|
17456
17535
|
const name = parseReferencedPlayTarget2(target).playName;
|
|
17457
|
-
const client = new (0,
|
|
17536
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
17458
17537
|
let revisionId = shareFlagValue(args, "--revision-id");
|
|
17459
17538
|
let resolvedVersion;
|
|
17460
17539
|
if (!revisionId) {
|
|
@@ -17485,8 +17564,8 @@ async function handlePlaySharePublish(args) {
|
|
|
17485
17564
|
);
|
|
17486
17565
|
if (!hasCompleted) {
|
|
17487
17566
|
const message = `No completed run for ${name}. Publish a play only after it has run successfully. (Override with --no-run-check.)`;
|
|
17488
|
-
if (
|
|
17489
|
-
|
|
17567
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
17568
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, {
|
|
17490
17569
|
ok: false,
|
|
17491
17570
|
code: "NO_SUCCESSFUL_RUN",
|
|
17492
17571
|
message,
|
|
@@ -17510,8 +17589,8 @@ async function handlePlaySharePublish(args) {
|
|
|
17510
17589
|
};
|
|
17511
17590
|
if (args.includes("--dry-run")) {
|
|
17512
17591
|
const plan = { dryRun: true, name, version: resolvedVersion, ...request };
|
|
17513
|
-
if (
|
|
17514
|
-
|
|
17592
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
17593
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, plan);
|
|
17515
17594
|
} else {
|
|
17516
17595
|
console.log(
|
|
17517
17596
|
`Would publish ${name}${resolvedVersion ? ` v${resolvedVersion}` : ""} (revision ${revisionId}).`
|
|
@@ -17521,13 +17600,13 @@ async function handlePlaySharePublish(args) {
|
|
|
17521
17600
|
}
|
|
17522
17601
|
const status = await client.publishSharePage(name, request);
|
|
17523
17602
|
const outputStatus = shareStatusForOutput(status);
|
|
17524
|
-
if (
|
|
17525
|
-
|
|
17603
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
17604
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, outputStatus);
|
|
17526
17605
|
return 0;
|
|
17527
17606
|
}
|
|
17528
17607
|
const urls = shareUrlFields(outputStatus);
|
|
17529
17608
|
console.log(
|
|
17530
|
-
`Published ${name}${outputStatus.share ? ` v${outputStatus.share.publishedVersion}` : ""}: ${_nullishCoalesce(_nullishCoalesce(urls.publicUrl, () => ( _optionalChain([outputStatus, 'access',
|
|
17609
|
+
`Published ${name}${outputStatus.share ? ` v${outputStatus.share.publishedVersion}` : ""}: ${_nullishCoalesce(_nullishCoalesce(urls.publicUrl, () => ( _optionalChain([outputStatus, 'access', _569 => _569.share, 'optionalAccess', _570 => _570.publicPath]))), () => ( ""))}`
|
|
17531
17610
|
);
|
|
17532
17611
|
if (urls.canonicalUrl && urls.canonicalUrl !== urls.publicUrl) {
|
|
17533
17612
|
console.log(`Version URL: ${urls.canonicalUrl}`);
|
|
@@ -17553,9 +17632,9 @@ async function handlePlayShareUpdate(args) {
|
|
|
17553
17632
|
...args.includes("--show-latency") ? { showAverageLatency: true } : args.includes("--hide-latency") ? { showAverageLatency: false } : {},
|
|
17554
17633
|
...seoIndexing ? { seoIndexing } : {}
|
|
17555
17634
|
};
|
|
17556
|
-
const status = await new (0,
|
|
17557
|
-
if (
|
|
17558
|
-
|
|
17635
|
+
const status = await new (0, _chunkOIODIUICjs.DeeplineClient)().updateSharePage(name, request);
|
|
17636
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
17637
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, status);
|
|
17559
17638
|
return 0;
|
|
17560
17639
|
}
|
|
17561
17640
|
console.log(`Updated ${name} share settings.`);
|
|
@@ -17570,13 +17649,13 @@ async function handlePlayShareRegenerate(args) {
|
|
|
17570
17649
|
return 2;
|
|
17571
17650
|
}
|
|
17572
17651
|
const name = parseReferencedPlayTarget2(target).playName;
|
|
17573
|
-
const client = new (0,
|
|
17652
|
+
const client = new (0, _chunkOIODIUICjs.DeeplineClient)();
|
|
17574
17653
|
let revisionId = shareFlagValue(args, "--revision-id");
|
|
17575
17654
|
const versionFlag = shareFlagValue(args, "--version");
|
|
17576
17655
|
if (!revisionId && versionFlag) {
|
|
17577
17656
|
const versions = await client.listPlayVersions(name);
|
|
17578
17657
|
const chosen = versions.find((r) => r.version === Number(versionFlag));
|
|
17579
|
-
if (!_optionalChain([chosen, 'optionalAccess',
|
|
17658
|
+
if (!_optionalChain([chosen, 'optionalAccess', _571 => _571._id])) {
|
|
17580
17659
|
console.error(`Version ${versionFlag} not found for ${name}.`);
|
|
17581
17660
|
return 4;
|
|
17582
17661
|
}
|
|
@@ -17587,12 +17666,12 @@ async function handlePlayShareRegenerate(args) {
|
|
|
17587
17666
|
revisionId ? { revisionId } : {}
|
|
17588
17667
|
);
|
|
17589
17668
|
const outputStatus = shareStatusForOutput(status);
|
|
17590
|
-
if (
|
|
17591
|
-
|
|
17669
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
17670
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, outputStatus);
|
|
17592
17671
|
return 0;
|
|
17593
17672
|
}
|
|
17594
17673
|
const urls = shareUrlFields(outputStatus);
|
|
17595
|
-
const regeneratedPublishedRevision = !revisionId || _optionalChain([outputStatus, 'access',
|
|
17674
|
+
const regeneratedPublishedRevision = !revisionId || _optionalChain([outputStatus, 'access', _572 => _572.share, 'optionalAccess', _573 => _573.publishedRevisionId]) === revisionId;
|
|
17596
17675
|
console.log(
|
|
17597
17676
|
`Regenerated public copy for ${name}${regeneratedPublishedRevision && urls.publicUrl ? `: ${urls.publicUrl}` : "."}`
|
|
17598
17677
|
);
|
|
@@ -17613,9 +17692,9 @@ async function handlePlayShareUnpublish(args) {
|
|
|
17613
17692
|
return 2;
|
|
17614
17693
|
}
|
|
17615
17694
|
const name = parseReferencedPlayTarget2(target).playName;
|
|
17616
|
-
const status = await new (0,
|
|
17617
|
-
if (
|
|
17618
|
-
|
|
17695
|
+
const status = await new (0, _chunkOIODIUICjs.DeeplineClient)().unpublishSharePage(name);
|
|
17696
|
+
if (_chunkWSKN3U4Ujs.argsWantJson.call(void 0, args)) {
|
|
17697
|
+
_chunkWSKN3U4Ujs.printCompactJson.call(void 0, status);
|
|
17619
17698
|
return 0;
|
|
17620
17699
|
}
|
|
17621
17700
|
console.log(`Unpublished ${name}; the public page has been removed.`);
|