deepline 0.3.539 → 0.3.540
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/shared_libs/integration-contracts/billing-entitlements.ts +10 -0
- package/dist/bundling-sources/shared_libs/play-runtime/activity-observation.ts +8 -4
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-execution-queries.ts +2 -2
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-pool.ts +20 -7
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +30 -11
- package/dist/bundling-sources/shared_libs/plays/authoring-contract.ts +1 -1
- package/dist/cli/{auth-QD7QGD3B.mjs → auth-32TURPHH.mjs} +5 -5
- package/dist/cli/auth-XA3K5LH2.js +43 -0
- package/dist/cli/{billing-KOQAF6WS.js → billing-6433M4BX.js} +105 -94
- package/dist/cli/{billing-FIZXMHBW.mjs → billing-NSH3NOHV.mjs} +21 -10
- package/dist/cli/{chunk-FH3P3E4S.js → chunk-2U4VACUA.js} +2 -2
- package/dist/cli/{chunk-GLKUC5PO.mjs → chunk-37VFUQMU.mjs} +2 -2
- package/dist/cli/chunk-3GVIVIER.js +54 -0
- package/dist/cli/{chunk-55ITVU2V.mjs → chunk-AB6DFHGL.mjs} +2 -2
- package/dist/cli/{chunk-V7DEGIYO.js → chunk-AJVK4XC5.js} +4 -4
- package/dist/cli/{chunk-K5MZHTK7.js → chunk-AOYW62XO.js} +3 -3
- package/dist/cli/{chunk-GEO2EMM7.mjs → chunk-B6UZUQ2O.mjs} +1 -1
- package/dist/cli/{chunk-JHEZQMOM.mjs → chunk-BD3VAPB4.mjs} +1 -1
- package/dist/cli/{chunk-XZBXQCRJ.js → chunk-BGBRA2S6.js} +22 -22
- package/dist/cli/{chunk-EAZS52DL.js → chunk-BNNGM2E5.js} +15 -15
- package/dist/cli/{chunk-6NZBLFL4.mjs → chunk-BZVVSUE2.mjs} +1 -1
- package/dist/cli/{chunk-TZBCJHV6.js → chunk-DV3ESQ4X.js} +1 -1
- package/dist/cli/{chunk-FIRV7BXJ.mjs → chunk-DWE2VE5I.mjs} +1 -1
- package/dist/cli/{chunk-KQTX545E.js → chunk-EXAXDEIF.js} +13 -13
- package/dist/cli/chunk-FANIRW74.mjs +9 -0
- package/dist/cli/{chunk-F43MXIN3.mjs → chunk-FR3AII3W.mjs} +2 -2
- package/dist/cli/chunk-GWHA4DAC.js +9 -0
- package/dist/cli/{chunk-FSQCB5SJ.js → chunk-H6IA6XRE.js} +2 -2
- package/dist/cli/{chunk-K22EKW6L.js → chunk-HKWJD45V.js} +5 -5
- package/dist/cli/{chunk-APKZGUTU.mjs → chunk-HLHDCFKL.mjs} +4 -4
- package/dist/cli/{chunk-E7D37PLM.mjs → chunk-IDDKNMFX.mjs} +36 -0
- package/dist/cli/{chunk-RULRGMMM.mjs → chunk-IYQZVEV4.mjs} +5 -5
- package/dist/cli/{chunk-5RUB53KG.js → chunk-J3TAEPFA.js} +26 -26
- package/dist/cli/{chunk-GNCIMHO2.mjs → chunk-JGFGWWOF.mjs} +10 -10
- package/dist/cli/{chunk-Y66ZMOJI.mjs → chunk-JPU5YLQG.mjs} +1 -1
- package/dist/cli/{chunk-JBCQFG7G.mjs → chunk-KFAJYK2N.mjs} +3 -3
- package/dist/cli/chunk-KN6ELDPL.mjs +54 -0
- package/dist/cli/{chunk-NR5PLMNG.js → chunk-LPMI4CYW.js} +107 -107
- package/dist/cli/{chunk-YMQFQO3K.js → chunk-LXLCQP4A.js} +16 -16
- package/dist/cli/{chunk-KAEVL62Q.js → chunk-M4DB6BBP.js} +44 -44
- package/dist/cli/{chunk-GLEGINSP.mjs → chunk-MH22LQKZ.mjs} +2 -2
- package/dist/cli/{chunk-MI53W4DN.js → chunk-MLDLN6WG.js} +53 -53
- package/dist/cli/{chunk-ISXX5DUD.js → chunk-MVIVF4BW.js} +3 -3
- package/dist/cli/{chunk-3YDI2PTN.js → chunk-N6DMKVKO.js} +10 -10
- package/dist/cli/{chunk-ADV2IB2C.mjs → chunk-PJOMRUFP.mjs} +5 -5
- package/dist/cli/{chunk-6V3LNYK5.mjs → chunk-S3ULSGFH.mjs} +2 -2
- package/dist/cli/{chunk-2XMFT44N.mjs → chunk-SGMDRYAD.mjs} +1 -1
- package/dist/cli/{chunk-MKESK3SW.mjs → chunk-SINNEITW.mjs} +4 -4
- package/dist/cli/{chunk-LE5KN7CZ.mjs → chunk-SXVYFOBG.mjs} +3 -3
- package/dist/cli/{chunk-FTBWFDF3.js → chunk-TNUM4DFA.js} +7 -7
- package/dist/cli/{chunk-E4QHTDPF.mjs → chunk-TZVW5JH3.mjs} +1 -1
- package/dist/cli/{chunk-W32KT6LM.js → chunk-UJYX4VLX.js} +5 -5
- package/dist/cli/{chunk-XTYHZEJ2.js → chunk-V4EYJKGJ.js} +36 -0
- package/dist/cli/{chunk-LEREPTAE.js → chunk-VAOGM5VS.js} +19 -19
- package/dist/cli/{chunk-6KG4KVTH.mjs → chunk-WCM64BRH.mjs} +5 -5
- package/dist/cli/{chunk-CQJCLHBE.js → chunk-WDHHQEWQ.js} +41 -41
- package/dist/cli/{chunk-5YF35HAV.js → chunk-WHYNYL3M.js} +6 -6
- package/dist/cli/{chunk-Q4HNK7JX.js → chunk-XIIQNSWA.js} +8 -8
- package/dist/cli/{chunk-VK5UTS5B.js → chunk-XL3CEPZA.js} +9 -9
- package/dist/cli/{chunk-G3UFDUYU.mjs → chunk-XYM3SQZN.mjs} +1 -1
- package/dist/cli/{chunk-SDAP5MCO.mjs → chunk-Y6647AIY.mjs} +2 -2
- package/dist/cli/{chunk-N3LPGGWD.mjs → chunk-Z2OYTXLK.mjs} +1 -1
- package/dist/cli/{chunk-DZFVVP3S.mjs → chunk-ZJFU2COM.mjs} +5 -5
- package/dist/cli/{chunk-5QL4GJB2.js → chunk-ZTJQKHLM.js} +2 -2
- package/dist/cli/command-docs.js +3 -2
- package/dist/cli/command-docs.mjs +2 -1
- package/dist/cli/concurrent-runs-help-DU5STFGB.mjs +21 -0
- package/dist/cli/concurrent-runs-help-HIPM5BBV.js +21 -0
- package/dist/cli/{csv-BWWJYV2C.js → csv-FBNS6SM3.js} +13 -13
- package/dist/cli/{csv-G5RQQ74W.mjs → csv-OJCMBODT.mjs} +4 -4
- package/dist/cli/{db-AJZHWB3V.mjs → db-43RQRF64.mjs} +6 -6
- package/dist/cli/{db-5KNDLADE.js → db-XRGJJ2KA.js} +27 -27
- package/dist/cli/{describe-QY5TKWVD.mjs → describe-I42Y3PWR.mjs} +17 -17
- package/dist/cli/describe-LWZCGAXU.js +49 -0
- package/dist/cli/describe-core.d.mts +3 -3
- package/dist/cli/describe-core.d.ts +3 -3
- package/dist/cli/{executions-BCCW76BI.js → executions-LH46O4PG.js} +8 -8
- package/dist/cli/{executions-SJPH3MZT.mjs → executions-QXGVQHQF.mjs} +6 -6
- package/dist/cli/{feedback-S6SZOFGK.mjs → feedback-ELFINGTM.mjs} +6 -6
- package/dist/cli/{feedback-GF65JKK6.js → feedback-ERYIV6MT.js} +14 -14
- package/dist/cli/git-OV2TGYVE.js +25 -0
- package/dist/cli/{git-F5FT5YVB.mjs → git-V2XWB6LN.mjs} +5 -5
- package/dist/cli/index.js +153 -143
- package/dist/cli/index.mjs +53 -43
- package/dist/cli/{legacy-noops-NOA4P5NE.mjs → legacy-noops-ULL2EA37.mjs} +6 -6
- package/dist/cli/{legacy-noops-ECR6FS6U.js → legacy-noops-Y3OKNVWH.js} +9 -9
- package/dist/cli/{monitors-DEWBSURN.js → monitors-DNQXCRJZ.js} +100 -100
- package/dist/cli/{monitors-CTYSAGP4.mjs → monitors-L34NROM3.mjs} +7 -7
- package/dist/cli/{org-ZM2UUMZZ.js → org-JETA62CO.js} +86 -86
- package/dist/cli/{org-EKSKKT7H.mjs → org-L3HTEEXL.mjs} +6 -6
- package/dist/cli/{play-6JQOM6DE.js → play-GTGJRNWI.js} +473 -455
- package/dist/cli/{play-R2BH374J.mjs → play-JHGLSSJP.mjs} +35 -17
- package/dist/cli/{providers-CMIYHEMN.js → providers-7VH7PH2Q.js} +9 -9
- package/dist/cli/{providers-X7WMIWO4.mjs → providers-IQVHZJ27.mjs} +6 -6
- package/dist/cli/{quickstart-6HVPAMSW.js → quickstart-M25JNU3O.js} +6 -6
- package/dist/cli/{quickstart-ZZ7L6VZJ.mjs → quickstart-ZDBC45PM.mjs} +4 -4
- package/dist/cli/{run-OOHYH3GI.js → run-MPZGX3YD.js} +42 -42
- package/dist/cli/{run-FP32RKBU.mjs → run-NEEWZBTX.mjs} +22 -22
- package/dist/cli/search-HUN2YRQE.js +32 -0
- package/dist/cli/{search-BDDNC23Z.mjs → search-YXAFB4QQ.mjs} +7 -7
- package/dist/cli/{search-output-5VZIQQAM.js → search-output-4PH5HSJC.js} +6 -6
- package/dist/cli/{search-output-QXJ6CV5G.mjs → search-output-67BBIXIZ.mjs} +4 -4
- package/dist/cli/{secrets-Z7CQSQGC.mjs → secrets-445FER3C.mjs} +6 -6
- package/dist/cli/{secrets-EN2HQCO3.js → secrets-HLUBDN3H.js} +15 -15
- package/dist/cli/{sessions-I2H37OTJ.mjs → sessions-CCKXJNWT.mjs} +6 -6
- package/dist/cli/sessions-T2RNWC6B.js +22 -0
- package/dist/cli/{settings-IYSC5PPQ.mjs → settings-3XCZGGVF.mjs} +12 -12
- package/dist/cli/{settings-CTRAPFNZ.js → settings-WXJIQS5J.js} +85 -85
- package/dist/cli/{setup-XIN53GEW.js → setup-CKETRFFN.js} +49 -49
- package/dist/cli/{setup-PU3HOVI3.mjs → setup-TOSX6NER.mjs} +9 -9
- package/dist/cli/skills-FXM2RHHO.js +36 -0
- package/dist/cli/{skills-TYBML2ZO.mjs → skills-Q7NLCIJJ.mjs} +7 -7
- package/dist/cli/{tools-ZVNE6M6J.mjs → tools-GY6QMYTZ.mjs} +16 -16
- package/dist/cli/tools-XLVDZTWQ.js +56 -0
- package/dist/cli/{update-54WENBNT.mjs → update-A7JRUN4S.mjs} +9 -9
- package/dist/cli/update-AZINHILP.js +34 -0
- package/dist/cli/{views-7L75EZOJ.js → views-GUWC4SNI.js} +21 -21
- package/dist/cli/{views-EUBB4ONT.mjs → views-JG7FDEJR.mjs} +6 -6
- package/dist/cli/{workflow-EZVYCR6Y.js → workflow-CXNW7ICH.js} +17 -17
- package/dist/cli/{workflow-GUKGFJ72.mjs → workflow-QZCYSQ5G.mjs} +7 -7
- package/dist/{client-DZTnAv4B.d.ts → client-B1fixtK1.d.ts} +1 -1
- package/dist/{client-D0uDBybG.d.mts → client-CE4QBVbp.d.mts} +1 -1
- package/dist/{client-core-BhWf8Y1b.d.mts → client-core-2BkNBgrx.d.mts} +3 -1
- package/dist/{client-core-og3AP1LL.d.ts → client-core-C-3FVlVq.d.ts} +3 -1
- package/dist/{compiler-manifest-Bes3OVA3.d.ts → compiler-manifest-Cys06iYg.d.mts} +14 -0
- package/dist/{compiler-manifest-Bes3OVA3.d.mts → compiler-manifest-Cys06iYg.d.ts} +14 -0
- package/dist/{errors-Dc5r42ks.d.mts → errors-B6eMjKcr.d.mts} +1 -1
- package/dist/{errors-BJm4lLWc.d.ts → errors-rdOUqcU2.d.ts} +1 -1
- package/dist/{index-DTkiz_Ur.d.mts → index-CZdYO81A.d.mts} +1 -1
- package/dist/{index-BfV7mRPF.d.ts → index-ejWadAL5.d.ts} +1 -1
- package/dist/index.d.mts +7 -7
- package/dist/index.d.ts +7 -7
- package/dist/index.js +9 -9
- package/dist/index.mjs +6 -6
- package/dist/install-integrity.json +118 -112
- package/dist/plays/bundle-play-file.d.mts +3 -3
- package/dist/plays/bundle-play-file.d.ts +3 -3
- package/dist/plays/bundle-play-file.mjs +1 -1
- package/dist/plays/play-description.d.mts +2 -2
- package/dist/plays/play-description.d.ts +2 -2
- package/dist/plays/run-request.d.mts +2 -2
- package/dist/plays/run-request.d.ts +2 -2
- package/dist/release.d.mts +1 -1
- package/dist/release.d.ts +1 -1
- package/dist/release.js +2 -2
- package/dist/release.mjs +1 -1
- package/dist/server.d.mts +4 -4
- package/dist/server.d.ts +4 -4
- package/dist/server.js +5 -5
- package/dist/server.mjs +3 -3
- package/package.json +1 -1
- package/dist/cli/auth-O5Y2VYXK.js +0 -43
- package/dist/cli/describe-B6CN6CFJ.js +0 -49
- package/dist/cli/git-DX6NB7VF.js +0 -25
- package/dist/cli/search-34C6LFOJ.js +0 -32
- package/dist/cli/sessions-RYQX3NDD.js +0 -22
- package/dist/cli/skills-576CX7DK.js +0 -36
- package/dist/cli/tools-EXMUWA3Z.js +0 -56
- package/dist/cli/update-RAHETNL2.js +0 -34
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkXL3CEPZAjs = require('./chunk-XL3CEPZA.js');
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
@@ -18,15 +18,15 @@ var _chunkVK5UTS5Bjs = require('./chunk-VK5UTS5B.js');
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
21
|
-
var
|
|
21
|
+
var _chunkTNUM4DFAjs = require('./chunk-TNUM4DFA.js');
|
|
22
22
|
|
|
23
23
|
|
|
24
|
-
var
|
|
24
|
+
var _chunkN6DMKVKOjs = require('./chunk-N6DMKVKO.js');
|
|
25
25
|
require('./chunk-D3BCSAN7.js');
|
|
26
26
|
|
|
27
27
|
|
|
28
28
|
|
|
29
|
-
var
|
|
29
|
+
var _chunkJ3TAEPFAjs = require('./chunk-J3TAEPFA.js');
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
|
|
@@ -51,10 +51,10 @@ var _chunkCBV7AKWMjs = require('./chunk-CBV7AKWM.js');
|
|
|
51
51
|
|
|
52
52
|
|
|
53
53
|
|
|
54
|
-
var
|
|
54
|
+
var _chunkHKWJD45Vjs = require('./chunk-HKWJD45V.js');
|
|
55
55
|
|
|
56
56
|
|
|
57
|
-
var
|
|
57
|
+
var _chunkUJYX4VLXjs = require('./chunk-UJYX4VLX.js');
|
|
58
58
|
|
|
59
59
|
|
|
60
60
|
|
|
@@ -67,7 +67,7 @@ var _chunkW32KT6LMjs = require('./chunk-W32KT6LM.js');
|
|
|
67
67
|
|
|
68
68
|
|
|
69
69
|
|
|
70
|
-
var
|
|
70
|
+
var _chunkXIIQNSWAjs = require('./chunk-XIIQNSWA.js');
|
|
71
71
|
require('./chunk-E4CABWXL.js');
|
|
72
72
|
|
|
73
73
|
|
|
@@ -91,18 +91,18 @@ require('./chunk-XDVT3GOM.js');
|
|
|
91
91
|
|
|
92
92
|
|
|
93
93
|
|
|
94
|
-
var
|
|
94
|
+
var _chunkWHYNYL3Mjs = require('./chunk-WHYNYL3M.js');
|
|
95
95
|
|
|
96
96
|
|
|
97
97
|
|
|
98
98
|
|
|
99
99
|
|
|
100
|
-
var
|
|
101
|
-
require('./chunk-
|
|
100
|
+
var _chunkH6IA6XREjs = require('./chunk-H6IA6XRE.js');
|
|
101
|
+
require('./chunk-M4DB6BBP.js');
|
|
102
102
|
|
|
103
103
|
|
|
104
104
|
|
|
105
|
-
var
|
|
105
|
+
var _chunkAOYW62XOjs = require('./chunk-AOYW62XO.js');
|
|
106
106
|
|
|
107
107
|
|
|
108
108
|
var _chunkR7J7CJPZjs = require('./chunk-R7J7CJPZ.js');
|
|
@@ -122,17 +122,17 @@ var _chunkYGCKMI5Pjs = require('./chunk-YGCKMI5P.js');
|
|
|
122
122
|
|
|
123
123
|
|
|
124
124
|
|
|
125
|
-
var
|
|
126
|
-
require('./chunk-
|
|
125
|
+
var _chunkVAOGM5VSjs = require('./chunk-VAOGM5VS.js');
|
|
126
|
+
require('./chunk-MVIVF4BW.js');
|
|
127
127
|
|
|
128
128
|
|
|
129
|
-
var
|
|
129
|
+
var _chunkAJVK4XC5js = require('./chunk-AJVK4XC5.js');
|
|
130
130
|
require('./chunk-2GJZLIKW.js');
|
|
131
131
|
require('./chunk-XNYIZMNQ.js');
|
|
132
132
|
|
|
133
133
|
|
|
134
134
|
var _chunkBBTKAASQjs = require('./chunk-BBTKAASQ.js');
|
|
135
|
-
require('./chunk-
|
|
135
|
+
require('./chunk-DV3ESQ4X.js');
|
|
136
136
|
require('./chunk-OG64RBAC.js');
|
|
137
137
|
|
|
138
138
|
|
|
@@ -2114,7 +2114,7 @@ function resolveField(key, command) {
|
|
|
2114
2114
|
function printSettings(result, json, name) {
|
|
2115
2115
|
result = { ...result, settings: parsePlaySettings(result.settings) };
|
|
2116
2116
|
const selected = fields.filter(([key]) => !name || key === name);
|
|
2117
|
-
|
|
2117
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
2118
2118
|
{
|
|
2119
2119
|
...result,
|
|
2120
2120
|
settings: Object.fromEntries(
|
|
@@ -2158,7 +2158,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2158
2158
|
valueSyntax: field.cli.valueSyntax,
|
|
2159
2159
|
examples: field.cli.examples
|
|
2160
2160
|
}));
|
|
2161
|
-
|
|
2161
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
2162
2162
|
{
|
|
2163
2163
|
fields: descriptions,
|
|
2164
2164
|
render: {
|
|
@@ -2183,7 +2183,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2183
2183
|
async (options, command) => {
|
|
2184
2184
|
if (options.name !== void 0) resolveField(options.name, command);
|
|
2185
2185
|
printSettings(
|
|
2186
|
-
await new (0,
|
|
2186
|
+
await new (0, _chunkUJYX4VLXjs.DeeplineClient)().getPlaySettings(options.play),
|
|
2187
2187
|
options.json,
|
|
2188
2188
|
options.name
|
|
2189
2189
|
);
|
|
@@ -2214,7 +2214,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2214
2214
|
);
|
|
2215
2215
|
}
|
|
2216
2216
|
if (options.dryRun) {
|
|
2217
|
-
|
|
2217
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
2218
2218
|
{
|
|
2219
2219
|
dryRun: true,
|
|
2220
2220
|
play,
|
|
@@ -2235,7 +2235,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2235
2235
|
return;
|
|
2236
2236
|
}
|
|
2237
2237
|
printSettings(
|
|
2238
|
-
await new (0,
|
|
2238
|
+
await new (0, _chunkUJYX4VLXjs.DeeplineClient)().updatePlaySettings(play, patch),
|
|
2239
2239
|
options.json
|
|
2240
2240
|
);
|
|
2241
2241
|
};
|
|
@@ -2261,13 +2261,13 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2261
2261
|
"--root must be person or team; --limit must be 1\u2013100.",
|
|
2262
2262
|
{ exitCode: 2 }
|
|
2263
2263
|
);
|
|
2264
|
-
const page = await new (0,
|
|
2264
|
+
const page = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().listPlaySettingsPaths({
|
|
2265
2265
|
root: options.root,
|
|
2266
2266
|
limit,
|
|
2267
2267
|
cursor: options.cursor
|
|
2268
2268
|
});
|
|
2269
2269
|
const nextCommand = page.hasMore ? `deepline plays settings paths --cursor '${page.cursor}'${options.root ? ` --root ${options.root}` : ""}` : null;
|
|
2270
|
-
|
|
2270
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
2271
2271
|
{
|
|
2272
2272
|
...page,
|
|
2273
2273
|
nextCommand,
|
|
@@ -2318,7 +2318,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2318
2318
|
root: _nullishCoalesce(_optionalChain([toPath, 'optionalAccess', _12 => _12.root]), () => ( "person")),
|
|
2319
2319
|
folders: _nullishCoalesce(_optionalChain([toPath, 'optionalAccess', _13 => _13.folders]), () => ( []))
|
|
2320
2320
|
};
|
|
2321
|
-
const client = new (0,
|
|
2321
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
2322
2322
|
const paths = [];
|
|
2323
2323
|
let cursor;
|
|
2324
2324
|
do {
|
|
@@ -2380,7 +2380,7 @@ function registerPlaySettingsCommands(plays) {
|
|
|
2380
2380
|
moved.push(move.playName);
|
|
2381
2381
|
}
|
|
2382
2382
|
}
|
|
2383
|
-
|
|
2383
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
2384
2384
|
{
|
|
2385
2385
|
dryRun: Boolean(options.dryRun),
|
|
2386
2386
|
from: options.from,
|
|
@@ -2508,7 +2508,7 @@ function triggerLines(view) {
|
|
|
2508
2508
|
return lines;
|
|
2509
2509
|
}
|
|
2510
2510
|
function printView(view, json) {
|
|
2511
|
-
|
|
2511
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
2512
2512
|
{
|
|
2513
2513
|
...view,
|
|
2514
2514
|
render: {
|
|
@@ -2521,7 +2521,7 @@ function printView(view, json) {
|
|
|
2521
2521
|
);
|
|
2522
2522
|
}
|
|
2523
2523
|
function printResult(result, json) {
|
|
2524
|
-
|
|
2524
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
2525
2525
|
{
|
|
2526
2526
|
...result,
|
|
2527
2527
|
render: {
|
|
@@ -2551,7 +2551,7 @@ async function mutate(command, options, build) {
|
|
|
2551
2551
|
usage(command, `Invalid trigger: ${formatPlayTriggerConfigError(error)}`);
|
|
2552
2552
|
}
|
|
2553
2553
|
if (options.dryRun) {
|
|
2554
|
-
|
|
2554
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
2555
2555
|
{
|
|
2556
2556
|
dryRun: true,
|
|
2557
2557
|
play: options.play,
|
|
@@ -2570,7 +2570,7 @@ async function mutate(command, options, build) {
|
|
|
2570
2570
|
return;
|
|
2571
2571
|
}
|
|
2572
2572
|
printResult(
|
|
2573
|
-
await new (0,
|
|
2573
|
+
await new (0, _chunkUJYX4VLXjs.DeeplineClient)().updatePlayTriggerConfig(options.play, update),
|
|
2574
2574
|
options.json
|
|
2575
2575
|
);
|
|
2576
2576
|
}
|
|
@@ -2603,7 +2603,7 @@ function registerPlayTriggerConfigCommands(plays) {
|
|
|
2603
2603
|
}).addHelpText("after", help2);
|
|
2604
2604
|
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) => {
|
|
2605
2605
|
printView(
|
|
2606
|
-
await new (0,
|
|
2606
|
+
await new (0, _chunkUJYX4VLXjs.DeeplineClient)().getPlayTriggerConfig(options.play),
|
|
2607
2607
|
options.json
|
|
2608
2608
|
);
|
|
2609
2609
|
});
|
|
@@ -2647,7 +2647,7 @@ function registerPlayTriggerConfigCommands(plays) {
|
|
|
2647
2647
|
if (options.auth === void 0) {
|
|
2648
2648
|
if (secrets.length || options.header || options.signaturePrefix)
|
|
2649
2649
|
usage(setWebhook, "--secret/--header need --auth.");
|
|
2650
|
-
const current = await new (0,
|
|
2650
|
+
const current = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().getPlayTriggerConfig(
|
|
2651
2651
|
options.play
|
|
2652
2652
|
);
|
|
2653
2653
|
return {
|
|
@@ -2724,7 +2724,7 @@ var KIND_DESCRIPTIONS = {
|
|
|
2724
2724
|
"receipt.skipped": "Saved work result: skipped.",
|
|
2725
2725
|
"runtime.event": "Other event."
|
|
2726
2726
|
};
|
|
2727
|
-
var RUN_LOGS_KIND_HELP =
|
|
2727
|
+
var RUN_LOGS_KIND_HELP = _chunkXIIQNSWAjs.RUN_EVENT_SEARCH_KIND_VALUES.map((kind) => ({
|
|
2728
2728
|
kind,
|
|
2729
2729
|
description: KIND_DESCRIPTIONS[kind]
|
|
2730
2730
|
}));
|
|
@@ -2861,9 +2861,9 @@ function configureRunQueryCommandErrors(command, resource) {
|
|
|
2861
2861
|
const args = program.args;
|
|
2862
2862
|
if (error.exitCode !== 0 && (resource === "events" || requestsStructuredLogs(args))) {
|
|
2863
2863
|
error.exitCode = 2;
|
|
2864
|
-
if (
|
|
2865
|
-
|
|
2866
|
-
Object.assign(new (0,
|
|
2864
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args) || command.optsWithGlobals().json === true) {
|
|
2865
|
+
_chunkVAOGM5VSjs.printJsonError.call(void 0,
|
|
2866
|
+
Object.assign(new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(error.message), {
|
|
2867
2867
|
exitCode: 2,
|
|
2868
2868
|
retryable: false
|
|
2869
2869
|
})
|
|
@@ -2907,14 +2907,14 @@ function parseQuery(args, resource) {
|
|
|
2907
2907
|
if (VALUE_FLAGS.has(flag)) {
|
|
2908
2908
|
const value = equals > 0 ? arg.slice(equals + 1) : args[++index];
|
|
2909
2909
|
if (!value || equals < 0 && value.startsWith("--") && flag !== "--query" && flag !== "--where") {
|
|
2910
|
-
throw new (0,
|
|
2910
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2911
2911
|
`${flag} requires a value. Use ${flag} <value>.`
|
|
2912
2912
|
);
|
|
2913
2913
|
}
|
|
2914
2914
|
if (flag === "--sum") sums.push(value);
|
|
2915
2915
|
else {
|
|
2916
2916
|
if (values[flag] !== void 0) {
|
|
2917
|
-
throw new (0,
|
|
2917
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2918
2918
|
`${flag} may only be supplied once.`
|
|
2919
2919
|
);
|
|
2920
2920
|
}
|
|
@@ -2928,12 +2928,12 @@ function parseQuery(args, resource) {
|
|
|
2928
2928
|
}
|
|
2929
2929
|
if (arg.startsWith("-")) {
|
|
2930
2930
|
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.";
|
|
2931
|
-
throw new (0,
|
|
2931
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2932
2932
|
`Unsupported query flag ${flag}. ${correction}`
|
|
2933
2933
|
);
|
|
2934
2934
|
}
|
|
2935
2935
|
if (runId !== void 0) {
|
|
2936
|
-
throw new (0,
|
|
2936
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2937
2937
|
`Unexpected argument ${JSON.stringify(arg)}. Supply one run ID.`
|
|
2938
2938
|
);
|
|
2939
2939
|
}
|
|
@@ -2941,7 +2941,7 @@ function parseQuery(args, resource) {
|
|
|
2941
2941
|
}
|
|
2942
2942
|
if (switches.has("--fields")) {
|
|
2943
2943
|
if (runId !== void 0) {
|
|
2944
|
-
throw new (0,
|
|
2944
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2945
2945
|
"--fields does not use a run ID. Omit the positional run ID."
|
|
2946
2946
|
);
|
|
2947
2947
|
}
|
|
@@ -2954,18 +2954,18 @@ function parseQuery(args, resource) {
|
|
|
2954
2954
|
)
|
|
2955
2955
|
];
|
|
2956
2956
|
if (incompatible.length) {
|
|
2957
|
-
throw new (0,
|
|
2957
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2958
2958
|
`--fields cannot be combined with ${incompatible.join(", ")}. Use --fields alone to discover the query contract.`
|
|
2959
2959
|
);
|
|
2960
2960
|
}
|
|
2961
2961
|
}
|
|
2962
2962
|
if (switches.has("--count") && values["--group-by"] !== void 0) {
|
|
2963
|
-
throw new (0,
|
|
2963
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2964
2964
|
"--count cannot be combined with --group-by. Use --group-by for counts per group."
|
|
2965
2965
|
);
|
|
2966
2966
|
}
|
|
2967
2967
|
if (sums.length && switches.has("--count")) {
|
|
2968
|
-
throw new (0,
|
|
2968
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2969
2969
|
"--sum cannot be combined with --count. Use --sum for the exact count and numeric total."
|
|
2970
2970
|
);
|
|
2971
2971
|
}
|
|
@@ -2973,7 +2973,7 @@ function parseQuery(args, resource) {
|
|
|
2973
2973
|
if (operation === "count") {
|
|
2974
2974
|
for (const flag of ["--limit", "--cursor", "--payloads"]) {
|
|
2975
2975
|
if (values[flag] !== void 0 || switches.has(flag)) {
|
|
2976
|
-
throw new (0,
|
|
2976
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
2977
2977
|
`--count cannot be combined with ${flag}. Remove ${flag} to count all matching retained records.`
|
|
2978
2978
|
);
|
|
2979
2979
|
}
|
|
@@ -3008,16 +3008,16 @@ function parseQuery(args, resource) {
|
|
|
3008
3008
|
];
|
|
3009
3009
|
}
|
|
3010
3010
|
}
|
|
3011
|
-
const request =
|
|
3011
|
+
const request = _chunkXIIQNSWAjs.normalizeRunEventOperationRequest.call(void 0, body);
|
|
3012
3012
|
const namespace = _nullishCoalesce(values["--runtime-namespace"], () => ( (process.env.DEEPLINE_RUNTIME_ENVIRONMENT === "preview" ? process.env.DEEPLINE_RUNTIME_NAMESPACE : void 0)));
|
|
3013
3013
|
const backend = values["--runtime-backend"];
|
|
3014
3014
|
if (backend && backend !== "daytona" && backend !== "modal") {
|
|
3015
|
-
throw new (0,
|
|
3015
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
3016
3016
|
"--runtime-backend must be daytona or modal."
|
|
3017
3017
|
);
|
|
3018
3018
|
}
|
|
3019
3019
|
if (backend && !namespace) {
|
|
3020
|
-
throw new (0,
|
|
3020
|
+
throw new (0, _chunkXIIQNSWAjs.RunEventQueryInputError)(
|
|
3021
3021
|
"--runtime-backend requires --runtime-namespace."
|
|
3022
3022
|
);
|
|
3023
3023
|
}
|
|
@@ -3064,12 +3064,12 @@ async function handleRunEventQuery(args, resource = "logs") {
|
|
|
3064
3064
|
const failure = error instanceof Error ? error : new Error(String(error));
|
|
3065
3065
|
const record4 = failure;
|
|
3066
3066
|
const status = record4.statusCode;
|
|
3067
|
-
const exitCode = error instanceof
|
|
3067
|
+
const exitCode = error instanceof _chunkXIIQNSWAjs.RunEventQueryInputError || status === 400 || status === 422 || record4.code === "INVALID_RUNTIME_SELECTION" ? 2 : status === 401 || status === 403 || record4.code === "CONFIG_ERROR" || record4.code === "RUNTIME_ENVIRONMENT_TOKEN_REQUIRED" ? 3 : status === 404 ? 4 : 5;
|
|
3068
3068
|
const diagnostic = Object.assign(failure, {
|
|
3069
3069
|
exitCode,
|
|
3070
3070
|
retryable: exitCode === 5
|
|
3071
3071
|
});
|
|
3072
|
-
if (
|
|
3072
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) _chunkVAOGM5VSjs.printJsonError.call(void 0, diagnostic);
|
|
3073
3073
|
else console.error(`Error: ${diagnostic.message}`);
|
|
3074
3074
|
return exitCode;
|
|
3075
3075
|
}
|
|
@@ -3084,7 +3084,7 @@ async function executeRunEventQuery(args, resource) {
|
|
|
3084
3084
|
...criteria
|
|
3085
3085
|
} = request;
|
|
3086
3086
|
const options = { ...criteria, ...runtime ? { runtime } : {} };
|
|
3087
|
-
const client = new (0,
|
|
3087
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
3088
3088
|
let result;
|
|
3089
3089
|
if (request.operation === "fields") {
|
|
3090
3090
|
result = await client.runs[resource].fields(runtime ? { runtime } : {});
|
|
@@ -3150,13 +3150,13 @@ async function executeRunEventQuery(args, resource) {
|
|
|
3150
3150
|
lines.push(`Next page: ${nextPage}`);
|
|
3151
3151
|
}
|
|
3152
3152
|
}
|
|
3153
|
-
|
|
3153
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
3154
3154
|
{
|
|
3155
3155
|
...result,
|
|
3156
3156
|
...nextPage ? { next: { page: nextPage } } : {},
|
|
3157
3157
|
render: { sections: [{ title: `run ${resource}`, lines }] }
|
|
3158
3158
|
},
|
|
3159
|
-
{ json:
|
|
3159
|
+
{ json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args), text: `${lines.join("\n")}
|
|
3160
3160
|
` }
|
|
3161
3161
|
);
|
|
3162
3162
|
return 0;
|
|
@@ -4118,7 +4118,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4118
4118
|
...text.split(/\r?\n/).map((key) => key.trim()).filter(Boolean)
|
|
4119
4119
|
);
|
|
4120
4120
|
}
|
|
4121
|
-
const response = await new (0,
|
|
4121
|
+
const response = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().runs.getReceipts(runId, {
|
|
4122
4122
|
keys
|
|
4123
4123
|
});
|
|
4124
4124
|
const failed = response.receipts.filter(
|
|
@@ -4130,7 +4130,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4130
4130
|
JSON.stringify(response, null, 2) + "\n",
|
|
4131
4131
|
{ flag: "wx", mode: 384 }
|
|
4132
4132
|
);
|
|
4133
|
-
|
|
4133
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
4134
4134
|
{
|
|
4135
4135
|
runId,
|
|
4136
4136
|
out: options.out,
|
|
@@ -4140,7 +4140,7 @@ Existing credential redactions and referenced-list previews remain as stored.
|
|
|
4140
4140
|
{ json: true }
|
|
4141
4141
|
);
|
|
4142
4142
|
} else {
|
|
4143
|
-
|
|
4143
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, { ...response }, { json: true });
|
|
4144
4144
|
}
|
|
4145
4145
|
if (failed)
|
|
4146
4146
|
process.exitCode = response.receipts.some(
|
|
@@ -4179,7 +4179,7 @@ includes nextCommand when another page is available.
|
|
|
4179
4179
|
{ exitCode: 2 }
|
|
4180
4180
|
);
|
|
4181
4181
|
}
|
|
4182
|
-
const page = await new (0,
|
|
4182
|
+
const page = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().runs.children(parentRunId, {
|
|
4183
4183
|
launchKey: options.launchKey,
|
|
4184
4184
|
...options.cursor !== void 0 ? { cursor: options.cursor } : {},
|
|
4185
4185
|
limit
|
|
@@ -4194,7 +4194,7 @@ includes nextCommand when another page is available.
|
|
|
4194
4194
|
"--limit",
|
|
4195
4195
|
String(limit)
|
|
4196
4196
|
].join(" ") : null;
|
|
4197
|
-
|
|
4197
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
4198
4198
|
{
|
|
4199
4199
|
parentRunId,
|
|
4200
4200
|
launchKey: options.launchKey,
|
|
@@ -4230,7 +4230,7 @@ async function handleRunsHistory(options) {
|
|
|
4230
4230
|
throw new Error("--limit must be a positive integer.");
|
|
4231
4231
|
}
|
|
4232
4232
|
}
|
|
4233
|
-
const page = await new (0,
|
|
4233
|
+
const page = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().runs.history({
|
|
4234
4234
|
cursor: options.cursor,
|
|
4235
4235
|
orgId: options.org,
|
|
4236
4236
|
search: options.search,
|
|
@@ -4246,7 +4246,7 @@ async function handleRunsHistory(options) {
|
|
|
4246
4246
|
);
|
|
4247
4247
|
}
|
|
4248
4248
|
if (page.hasMore) lines.push(`Next cursor: ${page.nextCursor}`);
|
|
4249
|
-
|
|
4249
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
4250
4250
|
{ ...page, render: { sections: [{ title: "Run history", lines }] } },
|
|
4251
4251
|
options.json ? { json: true } : {}
|
|
4252
4252
|
);
|
|
@@ -4299,12 +4299,12 @@ async function runRunsRerunCommand(runId, options) {
|
|
|
4299
4299
|
}
|
|
4300
4300
|
}
|
|
4301
4301
|
if (options.notice) console.error(options.notice);
|
|
4302
|
-
const result = await new (0,
|
|
4302
|
+
const result = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().runs.rerun(runId, {
|
|
4303
4303
|
...idempotencyKey === void 0 ? {} : { idempotencyKey },
|
|
4304
4304
|
...inputOverrides === void 0 ? {} : { inputOverrides }
|
|
4305
4305
|
});
|
|
4306
|
-
if (
|
|
4307
|
-
|
|
4306
|
+
if (_chunkVAOGM5VSjs.shouldEmitJson.call(void 0, options.json)) {
|
|
4307
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, result, { json: true });
|
|
4308
4308
|
} else if (result.rateLimited) {
|
|
4309
4309
|
console.log(`
|
|
4310
4310
|
${result.rateLimited.message}`);
|
|
@@ -4328,7 +4328,7 @@ Rerun started from ${runId}${inputOverrides ? " with input overrides" : ""}.`
|
|
|
4328
4328
|
// src/cli/operations/runs-resume.ts
|
|
4329
4329
|
async function runRunsResumeCommand(runId) {
|
|
4330
4330
|
try {
|
|
4331
|
-
const result = await new (0,
|
|
4331
|
+
const result = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().runs.resume(runId);
|
|
4332
4332
|
if (result.runId !== runId || result.resumed !== true || !Number.isSafeInteger(result.epoch) || result.epoch < 1)
|
|
4333
4333
|
throw new Error(
|
|
4334
4334
|
"Invalid resume receipt: expected the requested run and a new positive epoch."
|
|
@@ -5170,13 +5170,13 @@ var RunDataset = class _RunDataset {
|
|
|
5170
5170
|
const absolutePath = _path.resolve.call(void 0, outPath);
|
|
5171
5171
|
_fs.writeFileSync.call(void 0,
|
|
5172
5172
|
absolutePath,
|
|
5173
|
-
`${JSON.stringify(
|
|
5173
|
+
`${JSON.stringify(_chunkTNUM4DFAjs.orderRunExportJson.call(void 0, this.rows), null, 2)}
|
|
5174
5174
|
`,
|
|
5175
5175
|
"utf-8"
|
|
5176
5176
|
);
|
|
5177
5177
|
return absolutePath;
|
|
5178
5178
|
}
|
|
5179
|
-
return
|
|
5179
|
+
return _chunkTNUM4DFAjs.writeRunDatasetCsv.call(void 0, {
|
|
5180
5180
|
rows: this.rows,
|
|
5181
5181
|
columns: this.#info.columns,
|
|
5182
5182
|
outPath
|
|
@@ -6681,7 +6681,7 @@ function renderOutcome(outcome) {
|
|
|
6681
6681
|
function printResult2(input) {
|
|
6682
6682
|
const failed = input.status === "failed" || input.status === "cancelled";
|
|
6683
6683
|
if (failed) process.exitCode = 1;
|
|
6684
|
-
|
|
6684
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
6685
6685
|
{
|
|
6686
6686
|
deployment: { ...input.deployment, status: input.status },
|
|
6687
6687
|
plays: input.outcomes,
|
|
@@ -6706,7 +6706,7 @@ async function handlePlaysDeploy(directory, options) {
|
|
|
6706
6706
|
const root = await _promises.realpath.call(void 0, _path.resolve.call(void 0, _nullishCoalesce(directory, () => ( ".")))).catch(() => {
|
|
6707
6707
|
throw new Error(`No such directory: ${_path.resolve.call(void 0, _nullishCoalesce(directory, () => ( ".")))}`);
|
|
6708
6708
|
});
|
|
6709
|
-
const { http, config } =
|
|
6709
|
+
const { http, config } = _chunkVAOGM5VSjs.getAuthedHttpClient.call(void 0, );
|
|
6710
6710
|
const deliveryId = `local:${_crypto.randomUUID.call(void 0, )}`;
|
|
6711
6711
|
const startDeployment = () => http.post("/api/v2/deployments", {
|
|
6712
6712
|
deliveryId,
|
|
@@ -6733,7 +6733,7 @@ async function handlePlaysDeploy(directory, options) {
|
|
|
6733
6733
|
},
|
|
6734
6734
|
{
|
|
6735
6735
|
bundle: bundleDeployPlayFile,
|
|
6736
|
-
fetchImpl:
|
|
6736
|
+
fetchImpl: _chunkAJVK4XC5js.fetchWithDeploymentProtection,
|
|
6737
6737
|
// The plays are already here: "opening" the source is naming it.
|
|
6738
6738
|
openSource: async () => ({
|
|
6739
6739
|
open: async () => ({ repoRoot: root })
|
|
@@ -6859,7 +6859,7 @@ async function checkLocalPlayGraph(input) {
|
|
|
6859
6859
|
// src/cli/renderers/local-play-execution.ts
|
|
6860
6860
|
function renderLocalPlayExecutionPlan(plan, options = {}) {
|
|
6861
6861
|
if (options.dryRun) {
|
|
6862
|
-
|
|
6862
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, { dryRun: true, ...plan }, { json: options.json });
|
|
6863
6863
|
return;
|
|
6864
6864
|
}
|
|
6865
6865
|
process.stderr.write(`Local Play execution plan: ${JSON.stringify(plan)}
|
|
@@ -7031,7 +7031,7 @@ function traceCliSync(phase, fields2, run) {
|
|
|
7031
7031
|
const startedAt = Date.now();
|
|
7032
7032
|
try {
|
|
7033
7033
|
const result = run();
|
|
7034
|
-
|
|
7034
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
7035
7035
|
phase,
|
|
7036
7036
|
ms: Date.now() - startedAt,
|
|
7037
7037
|
ok: true,
|
|
@@ -7039,7 +7039,7 @@ function traceCliSync(phase, fields2, run) {
|
|
|
7039
7039
|
});
|
|
7040
7040
|
return result;
|
|
7041
7041
|
} catch (error) {
|
|
7042
|
-
|
|
7042
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
7043
7043
|
phase,
|
|
7044
7044
|
ms: Date.now() - startedAt,
|
|
7045
7045
|
ok: false,
|
|
@@ -7852,7 +7852,7 @@ function playStatusErrorText(status) {
|
|
|
7852
7852
|
function isRetryablePendingStartFailure(status) {
|
|
7853
7853
|
if (status.status !== "failed") return false;
|
|
7854
7854
|
if (status.runId && status.runId !== "pending") return false;
|
|
7855
|
-
return
|
|
7855
|
+
return _chunkXIIQNSWAjs.isTransientPlayRunReadError.call(void 0, new Error(playStatusErrorText(status)));
|
|
7856
7856
|
}
|
|
7857
7857
|
function isAmbiguousPlayStartOutcomeError(error) {
|
|
7858
7858
|
if (error instanceof _chunkBBTKAASQjs.DeeplineError && typeof error.statusCode === "number") {
|
|
@@ -7902,13 +7902,13 @@ var PlayStartOutcomeUnknownError = (_class = class extends _chunkBBTKAASQjs.Deep
|
|
|
7902
7902
|
}, _class);
|
|
7903
7903
|
function watchSurfaceReaches(state, provenance, level) {
|
|
7904
7904
|
const minimumLevel = _nullishCoalesce(state.logLevel, () => ( (state.verbose ? "debug" : "info")));
|
|
7905
|
-
if (!
|
|
7905
|
+
if (!_chunkXIIQNSWAjs.logLevelReaches.call(void 0, level, minimumLevel)) {
|
|
7906
7906
|
return false;
|
|
7907
7907
|
}
|
|
7908
|
-
if (
|
|
7908
|
+
if (_chunkXIIQNSWAjs.logProvenanceReaches.call(void 0, provenance, "watch")) {
|
|
7909
7909
|
return true;
|
|
7910
7910
|
}
|
|
7911
|
-
return state.verbose === true &&
|
|
7911
|
+
return state.verbose === true && _chunkXIIQNSWAjs.logProvenanceReaches.call(void 0, provenance, "debug");
|
|
7912
7912
|
}
|
|
7913
7913
|
function getEventPayload(event) {
|
|
7914
7914
|
return event.payload && typeof event.payload === "object" ? event.payload : {};
|
|
@@ -8418,7 +8418,7 @@ function resolvePlayRunUrl(input) {
|
|
|
8418
8418
|
}
|
|
8419
8419
|
function openPlayDashboard(url, open2) {
|
|
8420
8420
|
if (open2 && url) {
|
|
8421
|
-
|
|
8421
|
+
_chunkVAOGM5VSjs.openInBrowser.call(void 0, url);
|
|
8422
8422
|
}
|
|
8423
8423
|
}
|
|
8424
8424
|
function printPlayLogLines(input) {
|
|
@@ -8499,7 +8499,7 @@ async function waitForPlayCompletionByWatch(input) {
|
|
|
8499
8499
|
...input.fullJson === void 0 ? {} : { full: input.fullJson }
|
|
8500
8500
|
});
|
|
8501
8501
|
} catch (error) {
|
|
8502
|
-
if (
|
|
8502
|
+
if (_chunkXIIQNSWAjs.isTransientPlayRunReadError.call(void 0, error) || isAdmittedRunVisibilityDelay(error)) {
|
|
8503
8503
|
return null;
|
|
8504
8504
|
}
|
|
8505
8505
|
throw error;
|
|
@@ -8580,9 +8580,9 @@ async function waitForPlayCompletionByWatch(input) {
|
|
|
8580
8580
|
signal: controller.signal,
|
|
8581
8581
|
deferLogs: !input.emitLogs,
|
|
8582
8582
|
omitTerminalLogs: !input.emitLogs,
|
|
8583
|
-
...
|
|
8583
|
+
..._chunkH6IA6XREjs.isCliTraceEnabled.call(void 0, ) ? {
|
|
8584
8584
|
onPoll: (observation) => {
|
|
8585
|
-
|
|
8585
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
8586
8586
|
phase: "play_watch_poll",
|
|
8587
8587
|
workflowId: input.workflowId,
|
|
8588
8588
|
ms: observation.durationMs,
|
|
@@ -8596,7 +8596,7 @@ async function waitForPlayCompletionByWatch(input) {
|
|
|
8596
8596
|
full: input.fullJson,
|
|
8597
8597
|
billing: false,
|
|
8598
8598
|
onStatus: async (status) => {
|
|
8599
|
-
|
|
8599
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
8600
8600
|
phase: "play_watch_terminal_status",
|
|
8601
8601
|
workflowId: input.workflowId,
|
|
8602
8602
|
full: input.fullJson === true
|
|
@@ -8685,7 +8685,7 @@ async function startAndWaitForPlayCompletion(input) {
|
|
|
8685
8685
|
signal: controller.signal,
|
|
8686
8686
|
cliAdmission: useCliAdmission
|
|
8687
8687
|
});
|
|
8688
|
-
|
|
8688
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
8689
8689
|
phase: "cli.play_start_admission_attempt",
|
|
8690
8690
|
ms: Date.now() - postStartedAt,
|
|
8691
8691
|
ok: true,
|
|
@@ -8697,7 +8697,7 @@ async function startAndWaitForPlayCompletion(input) {
|
|
|
8697
8697
|
});
|
|
8698
8698
|
break;
|
|
8699
8699
|
} catch (error) {
|
|
8700
|
-
|
|
8700
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
8701
8701
|
phase: "cli.play_start_admission_attempt",
|
|
8702
8702
|
ms: Date.now() - postStartedAt,
|
|
8703
8703
|
ok: false,
|
|
@@ -8748,7 +8748,7 @@ async function startAndWaitForPlayCompletion(input) {
|
|
|
8748
8748
|
prepared.workflowId
|
|
8749
8749
|
);
|
|
8750
8750
|
}
|
|
8751
|
-
await
|
|
8751
|
+
await _chunkWHYNYL3Mjs.checkPlayRunCompatibility.call(void 0,
|
|
8752
8752
|
input.client.baseUrl,
|
|
8753
8753
|
input.maintenancePolicy
|
|
8754
8754
|
);
|
|
@@ -8766,7 +8766,7 @@ async function startAndWaitForPlayCompletion(input) {
|
|
|
8766
8766
|
`[play start] response was ambiguous; retrying the same caller intent (${error instanceof Error ? error.message : String(error)})`
|
|
8767
8767
|
);
|
|
8768
8768
|
}
|
|
8769
|
-
|
|
8769
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
8770
8770
|
phase: "cli.play_start_json_retry",
|
|
8771
8771
|
ms: 0,
|
|
8772
8772
|
ok: true,
|
|
@@ -8846,7 +8846,7 @@ async function startAndWaitForPlayCompletion(input) {
|
|
|
8846
8846
|
_nullishCoalesce(input.open, () => ( false))
|
|
8847
8847
|
);
|
|
8848
8848
|
input.progress.phase("running");
|
|
8849
|
-
|
|
8849
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
8850
8850
|
phase: "cli.play_start_admitted",
|
|
8851
8851
|
ms: Date.now() - startedAt,
|
|
8852
8852
|
ok: true,
|
|
@@ -8864,7 +8864,7 @@ async function startAndWaitForPlayCompletion(input) {
|
|
|
8864
8864
|
startedAt,
|
|
8865
8865
|
waitTimeoutMs: input.waitTimeoutMs
|
|
8866
8866
|
});
|
|
8867
|
-
const initialStatus =
|
|
8867
|
+
const initialStatus = _chunkXIIQNSWAjs.normalizePlayStatus.call(void 0, initialTerminal);
|
|
8868
8868
|
const status2 = await resolvePlayRunOutputStatus({
|
|
8869
8869
|
client: input.client,
|
|
8870
8870
|
status: initialStatus,
|
|
@@ -8872,7 +8872,7 @@ async function startAndWaitForPlayCompletion(input) {
|
|
|
8872
8872
|
jsonOutput: input.jsonOutput,
|
|
8873
8873
|
fromDurableStatus: true
|
|
8874
8874
|
});
|
|
8875
|
-
|
|
8875
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
8876
8876
|
phase: "play_watch_terminal_status",
|
|
8877
8877
|
workflowId,
|
|
8878
8878
|
full: true,
|
|
@@ -8977,7 +8977,7 @@ async function startAndWaitForPlayCompletionByStream(input) {
|
|
|
8977
8977
|
});
|
|
8978
8978
|
}
|
|
8979
8979
|
if (error instanceof _chunkCQDQNZGHjs.CliPlayAdmissionUnsupportedError && input.cliAdmission) {
|
|
8980
|
-
await
|
|
8980
|
+
await _chunkWHYNYL3Mjs.checkPlayRunCompatibility.call(void 0,
|
|
8981
8981
|
input.client.baseUrl,
|
|
8982
8982
|
input.maintenancePolicy,
|
|
8983
8983
|
admissionDeadline.signal
|
|
@@ -9018,7 +9018,7 @@ async function startAndWaitForPlayCompletionByStream(input) {
|
|
|
9018
9018
|
`[play watch] start response was ambiguous; retrying the same caller intent (${error.message})`
|
|
9019
9019
|
);
|
|
9020
9020
|
}
|
|
9021
|
-
|
|
9021
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9022
9022
|
phase: "cli.play_start_stream_retry",
|
|
9023
9023
|
ms: 0,
|
|
9024
9024
|
ok: true,
|
|
@@ -9039,7 +9039,7 @@ async function startAndWaitForPlayCompletionByStream(input) {
|
|
|
9039
9039
|
`[play watch] start failed before run id with a transient error; retrying (${playStatusErrorText(status)})`
|
|
9040
9040
|
);
|
|
9041
9041
|
}
|
|
9042
|
-
|
|
9042
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9043
9043
|
phase: "cli.play_start_stream_retry",
|
|
9044
9044
|
ms: 0,
|
|
9045
9045
|
ok: true,
|
|
@@ -9096,7 +9096,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9096
9096
|
if (launchConfirmed || !runId || runId === "pending") return;
|
|
9097
9097
|
launchConfirmed = true;
|
|
9098
9098
|
await _optionalChain([input, 'access', _314 => _314.onRunAdmitted, 'optionalCall', _315 => _315(runId)]);
|
|
9099
|
-
|
|
9099
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9100
9100
|
phase: "cli.play_start_admitted",
|
|
9101
9101
|
ms: Date.now() - startedAt,
|
|
9102
9102
|
ok: true,
|
|
@@ -9130,7 +9130,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9130
9130
|
full: input.fullJson
|
|
9131
9131
|
});
|
|
9132
9132
|
} catch (error) {
|
|
9133
|
-
if (
|
|
9133
|
+
if (_chunkXIIQNSWAjs.isTransientPlayRunReadError.call(void 0, error) || isAdmittedRunVisibilityDelay(error)) {
|
|
9134
9134
|
return null;
|
|
9135
9135
|
}
|
|
9136
9136
|
throw error;
|
|
@@ -9301,7 +9301,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9301
9301
|
};
|
|
9302
9302
|
}
|
|
9303
9303
|
if (!canonicalTerminal) {
|
|
9304
|
-
|
|
9304
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9305
9305
|
phase: "cli.play_start_stream_stale_terminal_ignored",
|
|
9306
9306
|
ms: Date.now() - startedAt,
|
|
9307
9307
|
ok: true,
|
|
@@ -9322,14 +9322,14 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9322
9322
|
fromDurableStatus
|
|
9323
9323
|
}) : canonicalTerminal;
|
|
9324
9324
|
if (input.fullJson === true) {
|
|
9325
|
-
|
|
9325
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9326
9326
|
phase: "play_watch_terminal_status",
|
|
9327
9327
|
workflowId: outputTerminal.runId || lastKnownWorkflowId || void 0,
|
|
9328
9328
|
full: true,
|
|
9329
9329
|
source: outputTerminal === canonicalTerminal ? fromDurableStatus ? "start_stream_durable" : "start_stream" : "durable_repair"
|
|
9330
9330
|
});
|
|
9331
9331
|
}
|
|
9332
|
-
|
|
9332
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9333
9333
|
phase: "cli.play_start_stream_terminal",
|
|
9334
9334
|
ms: Date.now() - startedAt,
|
|
9335
9335
|
ok: true,
|
|
@@ -9349,7 +9349,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9349
9349
|
clearTimeout(timeout);
|
|
9350
9350
|
}
|
|
9351
9351
|
controller.abort();
|
|
9352
|
-
|
|
9352
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9353
9353
|
phase: "cli.play_start_stream_handoff_to_tail",
|
|
9354
9354
|
ms: Date.now() - startedAt,
|
|
9355
9355
|
ok: true,
|
|
@@ -9380,7 +9380,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9380
9380
|
if (timedOut) {
|
|
9381
9381
|
const terminal = await fetchKnownTerminalStatus();
|
|
9382
9382
|
if (terminal) {
|
|
9383
|
-
|
|
9383
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9384
9384
|
phase: "cli.play_start_stream_timeout_status_reconcile",
|
|
9385
9385
|
ms: Date.now() - startedAt,
|
|
9386
9386
|
ok: true,
|
|
@@ -9400,7 +9400,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9400
9400
|
lastPhase
|
|
9401
9401
|
});
|
|
9402
9402
|
}
|
|
9403
|
-
if (lastKnownWorkflowId && (terminalWindowExpired ||
|
|
9403
|
+
if (lastKnownWorkflowId && (terminalWindowExpired || _chunkXIIQNSWAjs.isTransientPlayRunReadError.call(void 0, error))) {
|
|
9404
9404
|
if (timeout) {
|
|
9405
9405
|
clearTimeout(timeout);
|
|
9406
9406
|
}
|
|
@@ -9411,7 +9411,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9411
9411
|
`
|
|
9412
9412
|
);
|
|
9413
9413
|
}
|
|
9414
|
-
|
|
9414
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9415
9415
|
phase: "cli.play_start_stream_reconnect",
|
|
9416
9416
|
ms: Date.now() - startedAt,
|
|
9417
9417
|
ok: true,
|
|
@@ -9438,7 +9438,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9438
9438
|
});
|
|
9439
9439
|
}
|
|
9440
9440
|
if (!lastKnownWorkflowId && isAmbiguousPlayStartOutcomeError(error)) {
|
|
9441
|
-
|
|
9441
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9442
9442
|
phase: "cli.play_start_stream_transient_failure",
|
|
9443
9443
|
ms: Date.now() - startedAt,
|
|
9444
9444
|
ok: false,
|
|
@@ -9466,7 +9466,7 @@ async function startAndWaitForPlayCompletionByStreamOnce(input) {
|
|
|
9466
9466
|
`[play watch] start stream ended after run ${lastKnownWorkflowId}; reconnecting to canonical run stream`
|
|
9467
9467
|
);
|
|
9468
9468
|
}
|
|
9469
|
-
|
|
9469
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
9470
9470
|
phase: "cli.play_start_stream_reconnect",
|
|
9471
9471
|
ms: Date.now() - startedAt,
|
|
9472
9472
|
ok: true,
|
|
@@ -9546,7 +9546,7 @@ var BULKY_RETURN_KEYS = /* @__PURE__ */ new Set([
|
|
|
9546
9546
|
"logs"
|
|
9547
9547
|
]);
|
|
9548
9548
|
function formatPlayLogLine(rawLine, state) {
|
|
9549
|
-
const classified =
|
|
9549
|
+
const classified = _chunkXIIQNSWAjs.classifyLogLine.call(void 0, rawLine);
|
|
9550
9550
|
const line = classified.line;
|
|
9551
9551
|
const timestampMatch = line.match(/^\[([^\]]+)\]\s*(.*)$/);
|
|
9552
9552
|
const parsedTimestamp = _optionalChain([timestampMatch, 'optionalAccess', _337 => _337[1]]) ? new Date(timestampMatch[1]) : null;
|
|
@@ -9561,14 +9561,14 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
9561
9561
|
if (!state.verbose && isProviderRowWaitLogLine(line)) return null;
|
|
9562
9562
|
const providerWait = formatProviderCapacityWaitLogLine(line);
|
|
9563
9563
|
if (providerWait && !state.verbose) {
|
|
9564
|
-
return
|
|
9564
|
+
return _chunkXIIQNSWAjs.logLevelReaches.call(void 0, "warn", _nullishCoalesce(state.logLevel, () => ( "info"))) ? `${prefix}${providerWait}` : null;
|
|
9565
9565
|
}
|
|
9566
9566
|
const mapProgress = formatMapProgressDiagnosticLogLine(line);
|
|
9567
9567
|
if (mapProgress && !state.verbose) {
|
|
9568
|
-
return
|
|
9568
|
+
return _chunkXIIQNSWAjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info"))) ? `${prefix}${mapProgress}` : null;
|
|
9569
9569
|
}
|
|
9570
9570
|
if (/\[worker\] picked up run\b/.test(message)) {
|
|
9571
|
-
if (!
|
|
9571
|
+
if (!_chunkXIIQNSWAjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
9572
9572
|
return null;
|
|
9573
9573
|
}
|
|
9574
9574
|
if (state.emittedRunnerStarted) {
|
|
@@ -9581,7 +9581,7 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
9581
9581
|
/^Starting map over (\d+) items with (\d+) fields \(key: ([^;]+); (\d+) already satisfied; (\d+) pending\)$/
|
|
9582
9582
|
);
|
|
9583
9583
|
if (mapStart) {
|
|
9584
|
-
if (!
|
|
9584
|
+
if (!_chunkXIIQNSWAjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
9585
9585
|
return null;
|
|
9586
9586
|
}
|
|
9587
9587
|
const [, rows, fields2, namespace, cached, pending] = mapStart;
|
|
@@ -9591,7 +9591,7 @@ function formatPlayLogLine(rawLine, state) {
|
|
|
9591
9591
|
/^Map completed: (\d+) results \((\d+) executed, (\d+) already satisfied\)$/
|
|
9592
9592
|
);
|
|
9593
9593
|
if (mapDone) {
|
|
9594
|
-
if (!
|
|
9594
|
+
if (!_chunkXIIQNSWAjs.logLevelReaches.call(void 0, "info", _nullishCoalesce(state.logLevel, () => ( "info")))) {
|
|
9595
9595
|
return null;
|
|
9596
9596
|
}
|
|
9597
9597
|
const [, results, executed, cached] = mapDone;
|
|
@@ -10772,6 +10772,24 @@ function buildRunActivityTextLines(run) {
|
|
|
10772
10772
|
` activity: ${kind}${summary ? ` \u2014 ${summary}` : ""}${unclassified ? " (unclassified evidence; may be stale)" : ""}`
|
|
10773
10773
|
);
|
|
10774
10774
|
if (target) lines.push(` target: ${activityTargetLabel(target)}`);
|
|
10775
|
+
if (observation.activityId === "run:sandbox-capacity" && kind === "queued" && _optionalChain([target, 'optionalAccess', _402 => _402.kind]) === "capacity") {
|
|
10776
|
+
if (typeof target.limit === "number") {
|
|
10777
|
+
lines.push(
|
|
10778
|
+
` concurrency limit: ${target.limit} simultaneous Play runs per workspace`
|
|
10779
|
+
);
|
|
10780
|
+
}
|
|
10781
|
+
if (target.limitSource === "admission") {
|
|
10782
|
+
lines.push(
|
|
10783
|
+
" limit source: recorded at admission; plan changes apply to new launches"
|
|
10784
|
+
);
|
|
10785
|
+
}
|
|
10786
|
+
lines.push(
|
|
10787
|
+
" plan guidance: deepline billing entitlements; deepline billing plans"
|
|
10788
|
+
);
|
|
10789
|
+
lines.push(
|
|
10790
|
+
" next action: watch this run; do not submit it again to retry capacity admission"
|
|
10791
|
+
);
|
|
10792
|
+
}
|
|
10775
10793
|
if (typeof observation.stepId === "string" && observation.stepId.trim()) {
|
|
10776
10794
|
lines.push(` step: ${observation.stepId.trim()}`);
|
|
10777
10795
|
}
|
|
@@ -10806,11 +10824,11 @@ function buildRunActivityTextLines(run) {
|
|
|
10806
10824
|
}
|
|
10807
10825
|
function formatObservedRunCounter(value) {
|
|
10808
10826
|
const counter = readRecord(value);
|
|
10809
|
-
const count2 = _optionalChain([counter, 'optionalAccess',
|
|
10827
|
+
const count2 = _optionalChain([counter, 'optionalAccess', _403 => _403.value]);
|
|
10810
10828
|
if (typeof count2 !== "number" || !Number.isSafeInteger(count2) || count2 < 0) {
|
|
10811
10829
|
return "unknown";
|
|
10812
10830
|
}
|
|
10813
|
-
return _optionalChain([counter, 'optionalAccess',
|
|
10831
|
+
return _optionalChain([counter, 'optionalAccess', _404 => _404.confirmed]) === true ? formatInteger(count2) : `${formatInteger(count2)} observed`;
|
|
10814
10832
|
}
|
|
10815
10833
|
function buildRunStatusEvidenceTextLines(packaged) {
|
|
10816
10834
|
const evidence = readRecord(packaged.runStatus);
|
|
@@ -10823,13 +10841,13 @@ function buildRunStatusEvidenceTextLines(packaged) {
|
|
|
10823
10841
|
);
|
|
10824
10842
|
}
|
|
10825
10843
|
const source = readRecord(evidence.source);
|
|
10826
|
-
if (_optionalChain([source, 'optionalAccess',
|
|
10844
|
+
if (_optionalChain([source, 'optionalAccess', _405 => _405.aligned]) === false) {
|
|
10827
10845
|
lines.push(
|
|
10828
10846
|
` consistency: run snapshot event ${String(source.runSnapshotLedgerNextSeq)} and progress event ${String(source.ledgerNextSeq)} differ; retry this read to align them`
|
|
10829
10847
|
);
|
|
10830
10848
|
}
|
|
10831
10849
|
const focus = readRecord(evidence.focusStep);
|
|
10832
|
-
const rows = readRecord(_optionalChain([focus, 'optionalAccess',
|
|
10850
|
+
const rows = readRecord(_optionalChain([focus, 'optionalAccess', _406 => _406.rows]));
|
|
10833
10851
|
if (focus) {
|
|
10834
10852
|
const id = typeof focus.id === "string" && focus.id.trim() ? focus.id.trim() : "unknown step";
|
|
10835
10853
|
const label = typeof focus.label === "string" && focus.label.trim() ? ` (${focus.label.trim()})` : "";
|
|
@@ -10837,7 +10855,7 @@ function buildRunStatusEvidenceTextLines(packaged) {
|
|
|
10837
10855
|
const known = readRecordArray(packaged.steps).find(
|
|
10838
10856
|
(step) => typeof step.id === "string" && (id === step.id || id.endsWith(`:${step.id}`)) && typeof step.label === "string"
|
|
10839
10857
|
);
|
|
10840
|
-
const state = typeof _optionalChain([known, 'optionalAccess',
|
|
10858
|
+
const state = typeof _optionalChain([known, 'optionalAccess', _407 => _407.label]) === "string" ? known.label : typeof focus.status === "string" && focus.status.trim() ? formatNodeExecutionState(
|
|
10841
10859
|
deriveNodeExecutionState({
|
|
10842
10860
|
reported: {
|
|
10843
10861
|
status: focus.status.trim(),
|
|
@@ -10847,7 +10865,7 @@ function buildRunStatusEvidenceTextLines(packaged) {
|
|
|
10847
10865
|
total: rows.total
|
|
10848
10866
|
} : null
|
|
10849
10867
|
},
|
|
10850
|
-
runStatus: _optionalChain([run, 'optionalAccess',
|
|
10868
|
+
runStatus: _optionalChain([run, 'optionalAccess', _408 => _408.status])
|
|
10851
10869
|
})
|
|
10852
10870
|
) : null;
|
|
10853
10871
|
lines.push(` current step: ${id}${label}${state ? `: ${state}` : ""}`);
|
|
@@ -10895,7 +10913,7 @@ function formatRecentRunLogLines(value) {
|
|
|
10895
10913
|
(line) => typeof line === "string"
|
|
10896
10914
|
);
|
|
10897
10915
|
if (tail.length === 0) return [];
|
|
10898
|
-
const shown = tail.map((line) =>
|
|
10916
|
+
const shown = tail.map((line) => _chunkXIIQNSWAjs.classifyLogLine.call(void 0, line)).filter(
|
|
10899
10917
|
(entry) => entry.level !== "debug" && !isProviderRowWaitLogLine(entry.line)
|
|
10900
10918
|
).slice(-8);
|
|
10901
10919
|
const total = readNonNegativeInteger(logs.totalCount);
|
|
@@ -10939,7 +10957,7 @@ function buildRunPackageTextLines(packaged) {
|
|
|
10939
10957
|
lines.push(` recovery: ${mode}${sourceRunId}`);
|
|
10940
10958
|
}
|
|
10941
10959
|
const runError = typeof run.error === "string" && run.error.trim() ? run.error.trim() : null;
|
|
10942
|
-
const structuredRuntimeLimitMessage = typeof _optionalChain([runtimeLimitFailure, 'optionalAccess',
|
|
10960
|
+
const structuredRuntimeLimitMessage = typeof _optionalChain([runtimeLimitFailure, 'optionalAccess', _409 => _409.message]) === "string" && runtimeLimitFailure.message.trim() ? `${typeof runtimeLimitFailure.code === "string" ? runtimeLimitFailure.code : "RUNTIME_LIMIT_EXCEEDED"}: ${runtimeLimitFailure.message.trim()}` : null;
|
|
10943
10961
|
const displayRunError = _nullishCoalesce(structuredRuntimeLimitMessage, () => ( runError));
|
|
10944
10962
|
if (!isRuntimeLimitCheckpoint && displayRunError && (status === "failed" || status === "cancelled")) {
|
|
10945
10963
|
lines.push(` error: ${truncateErrorForDisplay(displayRunError, runId)}`);
|
|
@@ -10950,11 +10968,11 @@ function buildRunPackageTextLines(packaged) {
|
|
|
10950
10968
|
}
|
|
10951
10969
|
}
|
|
10952
10970
|
const failedLogs = readRecord(packaged.failedLogs);
|
|
10953
|
-
const failedLogEntries = Array.isArray(_optionalChain([failedLogs, 'optionalAccess',
|
|
10971
|
+
const failedLogEntries = Array.isArray(_optionalChain([failedLogs, 'optionalAccess', _410 => _410.entries])) ? failedLogs.entries.filter(
|
|
10954
10972
|
(entry) => typeof entry === "string"
|
|
10955
10973
|
) : [];
|
|
10956
|
-
const failedLogAssociation = typeof _optionalChain([failedLogs, 'optionalAccess',
|
|
10957
|
-
const failedLogWarning = typeof _optionalChain([failedLogs, 'optionalAccess',
|
|
10974
|
+
const failedLogAssociation = typeof _optionalChain([failedLogs, 'optionalAccess', _411 => _411.association]) === "string" ? failedLogs.association : null;
|
|
10975
|
+
const failedLogWarning = typeof _optionalChain([failedLogs, 'optionalAccess', _412 => _412.warning]) === "string" && failedLogs.warning.trim() ? failedLogs.warning.trim() : null;
|
|
10958
10976
|
if (failedLogEntries.length > 0) {
|
|
10959
10977
|
lines.push(" failed logs:");
|
|
10960
10978
|
lines.push(...failedLogEntries.map((entry) => ` ${entry}`));
|
|
@@ -10973,8 +10991,8 @@ function buildRunPackageTextLines(packaged) {
|
|
|
10973
10991
|
)
|
|
10974
10992
|
).slice(0, 16) : [];
|
|
10975
10993
|
lines.push(...packageWarnings.map((warning) => ` warning: ${warning}`));
|
|
10976
|
-
const failedLogNext = readRecord(_optionalChain([failedLogs, 'optionalAccess',
|
|
10977
|
-
if (failedLogWarning && typeof _optionalChain([failedLogNext, 'optionalAccess',
|
|
10994
|
+
const failedLogNext = readRecord(_optionalChain([failedLogs, 'optionalAccess', _413 => _413.next]));
|
|
10995
|
+
if (failedLogWarning && typeof _optionalChain([failedLogNext, 'optionalAccess', _414 => _414.logs]) === "string") {
|
|
10978
10996
|
lines.push(
|
|
10979
10997
|
failedLogAssociation === "retained_before_truncation" ? ` retained logs: ${failedLogNext.logs}` : ` retry failed logs: ${failedLogNext.logs}`
|
|
10980
10998
|
);
|
|
@@ -11002,20 +11020,20 @@ function buildRunPackageTextLines(packaged) {
|
|
|
11002
11020
|
const stepStatus = typeof step.status === "string" ? step.status : status;
|
|
11003
11021
|
const output = step.output && typeof step.output === "object" && !Array.isArray(step.output) ? step.output : null;
|
|
11004
11022
|
const rowCount = output && typeof output.rowCount === "number" ? ` rows=${formatInteger(output.rowCount)}` : "";
|
|
11005
|
-
const preview = _optionalChain([output, 'optionalAccess',
|
|
11006
|
-
const previewRows = Array.isArray(_optionalChain([preview, 'optionalAccess',
|
|
11023
|
+
const preview = _optionalChain([output, 'optionalAccess', _415 => _415.preview]) && typeof output.preview === "object" && !Array.isArray(output.preview) ? output.preview : null;
|
|
11024
|
+
const previewRows = Array.isArray(_optionalChain([preview, 'optionalAccess', _416 => _416.rows])) ? preview.rows.length : null;
|
|
11007
11025
|
lines.push(` ${kind} ${id}: ${stepStatus}${rowCount}`);
|
|
11008
|
-
lines.push(...formatPackageDatasetSummaryLines(_optionalChain([output, 'optionalAccess',
|
|
11026
|
+
lines.push(...formatPackageDatasetSummaryLines(_optionalChain([output, 'optionalAccess', _417 => _417.summary])));
|
|
11009
11027
|
if (previewRows !== null) {
|
|
11010
11028
|
lines.push(
|
|
11011
|
-
` preview=${previewRows}${_optionalChain([preview, 'optionalAccess',
|
|
11029
|
+
` preview=${previewRows}${_optionalChain([preview, 'optionalAccess', _418 => _418.truncated]) ? " truncated" : ""}`
|
|
11012
11030
|
);
|
|
11013
11031
|
}
|
|
11014
11032
|
}
|
|
11015
11033
|
const inspectCommand = actionToCommand(next.inspect);
|
|
11016
11034
|
const fullResultCommand = actionToCommand(next.full);
|
|
11017
11035
|
const hasCatalogExportAction = packageDatasetRecords(packaged).some(
|
|
11018
|
-
(dataset) => Boolean(actionToCommand(_optionalChain([readRecord, 'call',
|
|
11036
|
+
(dataset) => Boolean(actionToCommand(_optionalChain([readRecord, 'call', _419 => _419(dataset.actions), 'optionalAccess', _420 => _420.exportCsv])))
|
|
11019
11037
|
);
|
|
11020
11038
|
const legacyExportCommand = hasCatalogExportAction ? null : actionToCommand(next.export);
|
|
11021
11039
|
if (inspectCommand) lines.push(` inspect: ${inspectCommand}`);
|
|
@@ -11081,7 +11099,7 @@ function withOrdinaryRunAgainCommand(status, options, resolvedRevisionId) {
|
|
|
11081
11099
|
}
|
|
11082
11100
|
function buildBillingRollupTextLines(status) {
|
|
11083
11101
|
const billing = status.billing;
|
|
11084
|
-
const rollup = _optionalChain([billing, 'optionalAccess',
|
|
11102
|
+
const rollup = _optionalChain([billing, 'optionalAccess', _421 => _421.rollup]);
|
|
11085
11103
|
if (!rollup) return [];
|
|
11086
11104
|
const total = formatCreditAmount2(rollup.totalCreditsRollup);
|
|
11087
11105
|
if (rollup.childCredits > 0 && rollup.descendantRunCount > 0) {
|
|
@@ -11100,7 +11118,7 @@ function buildBillingRollupTextLines(status) {
|
|
|
11100
11118
|
return [` cost: ${total} credits`];
|
|
11101
11119
|
}
|
|
11102
11120
|
function playRunRateLimitedNotice(status) {
|
|
11103
|
-
const notice = _nullishCoalesce(_optionalChain([getPlayRunPackage, 'call',
|
|
11121
|
+
const notice = _nullishCoalesce(_optionalChain([getPlayRunPackage, 'call', _422 => _422(status), 'optionalAccess', _423 => _423.rateLimited]), () => ( status.rateLimited));
|
|
11104
11122
|
return notice && typeof notice === "object" ? notice : null;
|
|
11105
11123
|
}
|
|
11106
11124
|
function withRateLimitedNotice(status, notice) {
|
|
@@ -11141,7 +11159,7 @@ function buildPlayCompletionTextLines(status) {
|
|
|
11141
11159
|
const overview = buildRunOverview(status);
|
|
11142
11160
|
const { run } = overview;
|
|
11143
11161
|
const failed = run.status === "failed";
|
|
11144
|
-
const label = run.status === "completed" ? _optionalChain([overview, 'access',
|
|
11162
|
+
const label = run.status === "completed" ? _optionalChain([overview, 'access', _424 => _424.rowOutcomes, 'optionalAccess', _425 => _425.hasRowFailures]) ? "Completed with row failures" : "Completed" : failed ? "Failed" : run.status;
|
|
11145
11163
|
const rateLimited = playRunRateLimitedNotice(status);
|
|
11146
11164
|
const lines = [
|
|
11147
11165
|
...rateLimited ? [rateLimited.message] : [],
|
|
@@ -11165,7 +11183,7 @@ function buildPlayCompletionTextLines(status) {
|
|
|
11165
11183
|
...formatJsonPreview(compactReturnValue(overview.result))
|
|
11166
11184
|
);
|
|
11167
11185
|
}
|
|
11168
|
-
if (_optionalChain([overview, 'access',
|
|
11186
|
+
if (_optionalChain([overview, 'access', _426 => _426.rowOutcomes, 'optionalAccess', _427 => _427.hasRowFailures])) {
|
|
11169
11187
|
lines.push(
|
|
11170
11188
|
`Rows: ${overview.rowOutcomes.completedRows} completed, ${overview.rowOutcomes.failedRows} failed`
|
|
11171
11189
|
);
|
|
@@ -11200,17 +11218,17 @@ function buildPlayCompletionTextLines(status) {
|
|
|
11200
11218
|
}
|
|
11201
11219
|
function writePlayResult(status, jsonOutput, options) {
|
|
11202
11220
|
const packaged = getPlayRunPackage(status);
|
|
11203
|
-
if (status.package)
|
|
11204
|
-
const hits = _nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
11221
|
+
if (status.package) _chunkTNUM4DFAjs.recordPlayTermination.call(void 0, buildRunOverview(status).run);
|
|
11222
|
+
const hits = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _428 => _428.hits]), () => ( null));
|
|
11205
11223
|
if (jsonOutput) {
|
|
11206
|
-
const payload2 = _optionalChain([options, 'optionalAccess',
|
|
11207
|
-
|
|
11224
|
+
const payload2 = _optionalChain([options, 'optionalAccess', _429 => _429.fullJson]) ? status.package ? buildRunOverview(status, status) : { ...buildRunLaunch(status), diagnostics: status } : buildRunLaunch(status);
|
|
11225
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
11208
11226
|
hits ? { ...payload2, hits } : payload2,
|
|
11209
|
-
{ json: true, fields: _optionalChain([options, 'optionalAccess',
|
|
11227
|
+
{ json: true, fields: _optionalChain([options, 'optionalAccess', _430 => _430.jsonFields]) }
|
|
11210
11228
|
);
|
|
11211
11229
|
return;
|
|
11212
11230
|
}
|
|
11213
|
-
if (packaged && !_optionalChain([options, 'optionalAccess',
|
|
11231
|
+
if (packaged && !_optionalChain([options, 'optionalAccess', _431 => _431.fullJson])) {
|
|
11214
11232
|
const {
|
|
11215
11233
|
logs: _logs,
|
|
11216
11234
|
failedLogs: _failedLogs,
|
|
@@ -11220,7 +11238,7 @@ function writePlayResult(status, jsonOutput, options) {
|
|
|
11220
11238
|
...buildPlayCompletionTextLines(status),
|
|
11221
11239
|
...formatRunHitsLines(hits)
|
|
11222
11240
|
];
|
|
11223
|
-
|
|
11241
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, displayPackage, {
|
|
11224
11242
|
json: false,
|
|
11225
11243
|
text: `${lines2.join("\n")}
|
|
11226
11244
|
`
|
|
@@ -11269,8 +11287,8 @@ function writePlayResult(status, jsonOutput, options) {
|
|
|
11269
11287
|
lines.push(...renderedServerView.actions);
|
|
11270
11288
|
lines.push(...buildBillingRollupTextLines(status));
|
|
11271
11289
|
const compact = compactPlayStatus(status);
|
|
11272
|
-
const payload = _optionalChain([options, 'optionalAccess',
|
|
11273
|
-
|
|
11290
|
+
const payload = _optionalChain([options, 'optionalAccess', _432 => _432.fullJson]) ? status : compact;
|
|
11291
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
11274
11292
|
{
|
|
11275
11293
|
...payload,
|
|
11276
11294
|
render: {
|
|
@@ -11331,7 +11349,7 @@ async function resolvePlayRunOutputStatus(input) {
|
|
|
11331
11349
|
const fromDurableStatus = input.fromDurableStatus === true || fullDurableTerminalStatuses.has(input.status);
|
|
11332
11350
|
const refreshForFullJson = input.fullJson && !fromDurableStatus;
|
|
11333
11351
|
const streamedTextPackageIncomplete = input.status.status === "completed" && playRunPackageTextLedgerIncomplete(streamedPackage);
|
|
11334
|
-
const refreshFailedTerminal = input.status.status === "failed" && (!fromDurableStatus || _optionalChain([readRecord, 'call',
|
|
11352
|
+
const refreshFailedTerminal = input.status.status === "failed" && (!fromDurableStatus || _optionalChain([readRecord, 'call', _433 => _433(_optionalChain([streamedPackage, 'optionalAccess', _434 => _434.run])), 'optionalAccess', _435 => _435.status]) !== "failed");
|
|
11335
11353
|
if (!refreshForFullJson && !streamedTextPackageIncomplete && !refreshFailedTerminal) {
|
|
11336
11354
|
if (input.fullJson && fromDurableStatus && TERMINAL_PLAY_STATUSES.has(input.status.status)) {
|
|
11337
11355
|
fullDurableTerminalStatuses.add(input.status);
|
|
@@ -11438,14 +11456,14 @@ function mergeExportColumns(preferredColumns, rows) {
|
|
|
11438
11456
|
return columns;
|
|
11439
11457
|
}
|
|
11440
11458
|
function sqlSafeExportColumnName(id) {
|
|
11441
|
-
const prefix = _nullishCoalesce(_optionalChain([id, 'access',
|
|
11459
|
+
const prefix = _nullishCoalesce(_optionalChain([id, 'access', _436 => _436.trim, 'call', _437 => _437(), 'access', _438 => _438.match, 'call', _439 => _439(/^_+/), 'optionalAccess', _440 => _440[0]]), () => ( ""));
|
|
11442
11460
|
const normalized = id.trim().replace(/\.+/g, "__").replace(/[^A-Za-z0-9_]+/g, "_").replace(/^_+|_+$/g, "").toLowerCase();
|
|
11443
11461
|
const safe = `${prefix}${normalized || "column"}`;
|
|
11444
11462
|
return /^[A-Za-z_]/.test(safe) ? safe : `c_${safe}`;
|
|
11445
11463
|
}
|
|
11446
11464
|
async function fetchBackingDatasetRows(input) {
|
|
11447
11465
|
const playName = extractRunPlayName(input.status);
|
|
11448
|
-
const tableNamespace = _optionalChain([input, 'access',
|
|
11466
|
+
const tableNamespace = _optionalChain([input, 'access', _441 => _441.rowsInfo, 'access', _442 => _442.tableNamespace, 'optionalAccess', _443 => _443.trim, 'call', _444 => _444()]);
|
|
11449
11467
|
if (!playName || !tableNamespace) {
|
|
11450
11468
|
return null;
|
|
11451
11469
|
}
|
|
@@ -11485,7 +11503,7 @@ async function fetchBackingDatasetRows(input) {
|
|
|
11485
11503
|
seenEnvelopeKeys.add(key);
|
|
11486
11504
|
}
|
|
11487
11505
|
sheetRows.push(...page.rows);
|
|
11488
|
-
const summaryTotal = _optionalChain([page, 'access',
|
|
11506
|
+
const summaryTotal = _optionalChain([page, 'access', _445 => _445.summary, 'optionalAccess', _446 => _446.stats, 'optionalAccess', _447 => _447.total]);
|
|
11489
11507
|
if (typeof summaryTotal === "number" && Number.isFinite(summaryTotal)) {
|
|
11490
11508
|
settledTotal = Math.max(_nullishCoalesce(settledTotal, () => ( 0)), Math.trunc(summaryTotal));
|
|
11491
11509
|
}
|
|
@@ -11494,7 +11512,7 @@ async function fetchBackingDatasetRows(input) {
|
|
|
11494
11512
|
}
|
|
11495
11513
|
offset += page.rows.length;
|
|
11496
11514
|
}
|
|
11497
|
-
const withError =
|
|
11515
|
+
const withError = _chunkTNUM4DFAjs.tableExportHasFailedRows.call(void 0,
|
|
11498
11516
|
sheetRows.filter(
|
|
11499
11517
|
(row) => Boolean(row) && typeof row === "object" && !Array.isArray(row)
|
|
11500
11518
|
)
|
|
@@ -11510,7 +11528,7 @@ async function fetchBackingDatasetRows(input) {
|
|
|
11510
11528
|
return [
|
|
11511
11529
|
withError ? {
|
|
11512
11530
|
...exported,
|
|
11513
|
-
[
|
|
11531
|
+
[_chunkTNUM4DFAjs.TABLE_EXPORT_ERROR_COLUMN]: _chunkTNUM4DFAjs.tableExportErrorCell.call(void 0,
|
|
11514
11532
|
row
|
|
11515
11533
|
)
|
|
11516
11534
|
} : exported
|
|
@@ -11579,7 +11597,7 @@ function assertDatasetHasExportableRows(input) {
|
|
|
11579
11597
|
const rowOutcomes = _nullishCoalesce(readRowOutcomeSummary(input.status), () => ( readRowOutcomeSummary(
|
|
11580
11598
|
getRecordField(getRecordField(input.status, "result"), "_metadata")
|
|
11581
11599
|
)));
|
|
11582
|
-
if (input.allowEmpty === true && input.status.status === "completed" && !getRecordField(input.status, "error") && !getRecordField(input.status.progress, "error") && structuredErrorsForStatus(input.status).length === 0 && input.rowsInfo.complete && input.rowsInfo.totalRows === 0 && _optionalChain([rowOutcomes, 'optionalAccess',
|
|
11600
|
+
if (input.allowEmpty === true && input.status.status === "completed" && !getRecordField(input.status, "error") && !getRecordField(input.status.progress, "error") && structuredErrorsForStatus(input.status).length === 0 && input.rowsInfo.complete && input.rowsInfo.totalRows === 0 && _optionalChain([rowOutcomes, 'optionalAccess', _448 => _448.failedRows]) === 0 && !rowOutcomes.hasRowFailures) {
|
|
11583
11601
|
return input.rowsInfo;
|
|
11584
11602
|
}
|
|
11585
11603
|
const datasetLabel = _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(input.datasetPath, () => ( input.rowsInfo.tableNamespace)), () => ( input.rowsInfo.source)), () => ( "result.rows"));
|
|
@@ -11651,8 +11669,8 @@ async function exportPlayStatusRows(client, status, outPath, options = {}) {
|
|
|
11651
11669
|
path: dataset.exportFile(outPath, options),
|
|
11652
11670
|
rowsInfo: dataset.info(),
|
|
11653
11671
|
currentTable: false,
|
|
11654
|
-
datasetPath: _nullishCoalesce(_optionalChain([selectedDataset, 'optionalAccess',
|
|
11655
|
-
datasetInfo: _nullishCoalesce(_optionalChain([selectedDataset, 'optionalAccess',
|
|
11672
|
+
datasetPath: _nullishCoalesce(_optionalChain([selectedDataset, 'optionalAccess', _449 => _449.source]), () => ( null)),
|
|
11673
|
+
datasetInfo: _nullishCoalesce(_optionalChain([selectedDataset, 'optionalAccess', _450 => _450.info, 'call', _451 => _451()]), () => ( null))
|
|
11656
11674
|
};
|
|
11657
11675
|
};
|
|
11658
11676
|
const run = Run.open({
|
|
@@ -11664,7 +11682,7 @@ async function exportPlayStatusRows(client, status, outPath, options = {}) {
|
|
|
11664
11682
|
const returnedRows = datasets.returned().map((dataset) => dataset.info());
|
|
11665
11683
|
const recoveredRows = datasets.recovered().map((dataset) => dataset.info());
|
|
11666
11684
|
const selectedDataset = run.dataset(options.datasetPath);
|
|
11667
|
-
const rowsInfo = _nullishCoalesce(_optionalChain([selectedDataset, 'optionalAccess',
|
|
11685
|
+
const rowsInfo = _nullishCoalesce(_optionalChain([selectedDataset, 'optionalAccess', _452 => _452.info, 'call', _453 => _453()]), () => ( null));
|
|
11668
11686
|
if (!selectedDataset && options.datasetPath) {
|
|
11669
11687
|
const available = availableRows.map((info) => info.source).filter((source) => typeof source === "string");
|
|
11670
11688
|
const commands = datasetChoiceLines({
|
|
@@ -11777,7 +11795,7 @@ ${commands.join("\n")}`,
|
|
|
11777
11795
|
throw error;
|
|
11778
11796
|
}
|
|
11779
11797
|
}
|
|
11780
|
-
if (_optionalChain([fetchedRowsInfo, 'optionalAccess',
|
|
11798
|
+
if (_optionalChain([fetchedRowsInfo, 'optionalAccess', _454 => _454.complete])) {
|
|
11781
11799
|
const guarded2 = assertDatasetHasExportableRows({
|
|
11782
11800
|
rowsInfo: fetchedRowsInfo,
|
|
11783
11801
|
status,
|
|
@@ -11842,7 +11860,7 @@ function extractActiveRunsFromError(error) {
|
|
|
11842
11860
|
if (!(error instanceof _chunkBBTKAASQjs.DeeplineError)) {
|
|
11843
11861
|
return [];
|
|
11844
11862
|
}
|
|
11845
|
-
const response = _optionalChain([error, 'access',
|
|
11863
|
+
const response = _optionalChain([error, 'access', _455 => _455.details, 'optionalAccess', _456 => _456.response]);
|
|
11846
11864
|
if (!response || typeof response !== "object" || Array.isArray(response)) {
|
|
11847
11865
|
return [];
|
|
11848
11866
|
}
|
|
@@ -11959,8 +11977,8 @@ function renderServerResultView(value) {
|
|
|
11959
11977
|
return { lines: [], actions: [] };
|
|
11960
11978
|
}
|
|
11961
11979
|
const view = value;
|
|
11962
|
-
const renderedSections = Array.isArray(_optionalChain([view, 'access',
|
|
11963
|
-
const renderedActions = Array.isArray(_optionalChain([view, 'access',
|
|
11980
|
+
const renderedSections = Array.isArray(_optionalChain([view, 'access', _457 => _457.render, 'optionalAccess', _458 => _458.sections])) ? view.render.sections : [];
|
|
11981
|
+
const renderedActions = Array.isArray(_optionalChain([view, 'access', _459 => _459.render, 'optionalAccess', _460 => _460.actions])) ? view.render.actions : [];
|
|
11964
11982
|
if (renderedSections.length > 0 || renderedActions.length > 0) {
|
|
11965
11983
|
const lines2 = [];
|
|
11966
11984
|
for (const section of renderedSections) {
|
|
@@ -11998,7 +12016,7 @@ function renderServerResultView(value) {
|
|
|
11998
12016
|
}
|
|
11999
12017
|
const tables = Array.isArray(view.tables) ? view.tables : [];
|
|
12000
12018
|
const topLevelOutputTable = view.topLevelOutputTable && typeof view.topLevelOutputTable === "object" && !Array.isArray(view.topLevelOutputTable) ? view.topLevelOutputTable : null;
|
|
12001
|
-
if (typeof _optionalChain([topLevelOutputTable, 'optionalAccess',
|
|
12019
|
+
if (typeof _optionalChain([topLevelOutputTable, 'optionalAccess', _461 => _461.queryCommand]) === "string") {
|
|
12002
12020
|
lines.push(` top-level outputs: ${topLevelOutputTable.queryCommand}`);
|
|
12003
12021
|
}
|
|
12004
12022
|
if (tables.length > 0) {
|
|
@@ -12045,7 +12063,7 @@ function renderServerResultView(value) {
|
|
|
12045
12063
|
function writeStartedPlayRun(input) {
|
|
12046
12064
|
if (input.package && isPlayRunPackageValue(input.package)) {
|
|
12047
12065
|
const run = input.package.run;
|
|
12048
|
-
|
|
12066
|
+
_chunkTNUM4DFAjs.recordPlayTermination.call(void 0, {
|
|
12049
12067
|
id: run.id,
|
|
12050
12068
|
status: run.status,
|
|
12051
12069
|
finishedAt: run.finishedAt
|
|
@@ -12058,7 +12076,7 @@ function writeStartedPlayRun(input) {
|
|
|
12058
12076
|
dashboardUrl: input.dashboardUrl,
|
|
12059
12077
|
package: input.package
|
|
12060
12078
|
};
|
|
12061
|
-
|
|
12079
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, buildRunLaunch(status), {
|
|
12062
12080
|
json: true,
|
|
12063
12081
|
fields: input.jsonFields
|
|
12064
12082
|
});
|
|
@@ -12080,7 +12098,7 @@ function writeStartedPlayRun(input) {
|
|
|
12080
12098
|
input.progress.writeLine(output2, process.stdout);
|
|
12081
12099
|
return;
|
|
12082
12100
|
}
|
|
12083
|
-
|
|
12101
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, input.package, {
|
|
12084
12102
|
json: false,
|
|
12085
12103
|
text: `${output2}
|
|
12086
12104
|
`
|
|
@@ -12115,7 +12133,7 @@ function writeStartedPlayRun(input) {
|
|
|
12115
12133
|
) ? [`Stop: deepline runs stop ${_chunkAID3OYVJjs.shellQuote.call(void 0, input.runId)}`] : []
|
|
12116
12134
|
];
|
|
12117
12135
|
if (input.jsonOutput) {
|
|
12118
|
-
|
|
12136
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, payload, { json: true, fields: input.jsonFields });
|
|
12119
12137
|
return;
|
|
12120
12138
|
}
|
|
12121
12139
|
const output = lines.join("\n");
|
|
@@ -12123,7 +12141,7 @@ function writeStartedPlayRun(input) {
|
|
|
12123
12141
|
input.progress.writeLine(output, process.stdout);
|
|
12124
12142
|
return;
|
|
12125
12143
|
}
|
|
12126
|
-
|
|
12144
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
12127
12145
|
{
|
|
12128
12146
|
...payload,
|
|
12129
12147
|
render: { sections: [{ title: "play run", lines }] }
|
|
@@ -12133,7 +12151,7 @@ function writeStartedPlayRun(input) {
|
|
|
12133
12151
|
);
|
|
12134
12152
|
}
|
|
12135
12153
|
function parsePlayCheckOptions(args) {
|
|
12136
|
-
const selection =
|
|
12154
|
+
const selection = _chunkVAOGM5VSjs.parseJsonFields.call(void 0, args, "check");
|
|
12137
12155
|
args = selection.args;
|
|
12138
12156
|
const target = args[0];
|
|
12139
12157
|
if (!target || target.startsWith("-")) {
|
|
@@ -12145,7 +12163,7 @@ function parsePlayCheckOptions(args) {
|
|
|
12145
12163
|
if (arg !== "--json" && arg !== "--full")
|
|
12146
12164
|
throw new Error(`Unknown plays check option: ${arg}`);
|
|
12147
12165
|
}
|
|
12148
|
-
const jsonOutput =
|
|
12166
|
+
const jsonOutput = _chunkVAOGM5VSjs.argsWantJson.call(void 0, args);
|
|
12149
12167
|
return {
|
|
12150
12168
|
target,
|
|
12151
12169
|
jsonOutput,
|
|
@@ -12221,7 +12239,7 @@ ${PLAY_PUBLISH_USAGE}`
|
|
|
12221
12239
|
useLatest,
|
|
12222
12240
|
expectedArtifactHash,
|
|
12223
12241
|
dryRun,
|
|
12224
|
-
jsonOutput:
|
|
12242
|
+
jsonOutput: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args)
|
|
12225
12243
|
};
|
|
12226
12244
|
}
|
|
12227
12245
|
var PLAY_SAVE_USAGE = "Usage: deepline plays save <play-file.ts> [--expected-artifact <hash>] [--watch-play <play-reference>] [--dry-run] [--json]\nUse --watch-play to show invalid source on your own open working canvas while keeping the last valid diagram.";
|
|
@@ -12270,7 +12288,7 @@ ${PLAY_SAVE_USAGE}`);
|
|
|
12270
12288
|
expectedArtifactHash,
|
|
12271
12289
|
watchPlay,
|
|
12272
12290
|
dryRun,
|
|
12273
|
-
jsonOutput:
|
|
12291
|
+
jsonOutput: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args)
|
|
12274
12292
|
};
|
|
12275
12293
|
}
|
|
12276
12294
|
function printScheduledPlayCapacity(capacity) {
|
|
@@ -12323,7 +12341,7 @@ function checkHintExpression(value) {
|
|
|
12323
12341
|
return stringValue2(value).replace(/^toolExecutionResult\./, "result.");
|
|
12324
12342
|
}
|
|
12325
12343
|
function checkHintRawPath(value) {
|
|
12326
|
-
return _optionalChain([value, 'optionalAccess',
|
|
12344
|
+
return _optionalChain([value, 'optionalAccess', _462 => _462.startsWith, 'call', _463 => _463("toolResponse.rawV2")]) ? value.replace(/^toolResponse\./, "result.toolResponse.") : void 0;
|
|
12327
12345
|
}
|
|
12328
12346
|
function collectStaticPipelineToolIds(staticPipeline) {
|
|
12329
12347
|
const seen = /* @__PURE__ */ new Set();
|
|
@@ -12398,30 +12416,30 @@ function cronExecutionLabel(status) {
|
|
|
12398
12416
|
}
|
|
12399
12417
|
function readLiveCronMetadata(play) {
|
|
12400
12418
|
const record4 = readRecord(play);
|
|
12401
|
-
const metadata = readRecord(_optionalChain([record4, 'optionalAccess',
|
|
12419
|
+
const metadata = readRecord(_optionalChain([record4, 'optionalAccess', _464 => _464.triggerMetadata]));
|
|
12402
12420
|
return {
|
|
12403
|
-
schedule: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12404
|
-
timezone: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12405
|
-
nextScheduledAt: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12406
|
-
blockedAt: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12407
|
-
blockedReasonCode: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12421
|
+
schedule: typeof _optionalChain([metadata, 'optionalAccess', _465 => _465.cronSchedule]) === "string" ? metadata.cronSchedule : null,
|
|
12422
|
+
timezone: typeof _optionalChain([metadata, 'optionalAccess', _466 => _466.cronTimezone]) === "string" ? metadata.cronTimezone : null,
|
|
12423
|
+
nextScheduledAt: typeof _optionalChain([metadata, 'optionalAccess', _467 => _467.nextScheduledAt]) === "number" ? metadata.nextScheduledAt : null,
|
|
12424
|
+
blockedAt: typeof _optionalChain([metadata, 'optionalAccess', _468 => _468.blockedAt]) === "number" ? metadata.blockedAt : null,
|
|
12425
|
+
blockedReasonCode: typeof _optionalChain([metadata, 'optionalAccess', _469 => _469.blockedReasonCode]) === "string" ? metadata.blockedReasonCode : null
|
|
12408
12426
|
};
|
|
12409
12427
|
}
|
|
12410
12428
|
function liveTriggerStatusLines(status, play) {
|
|
12411
12429
|
const cron = readLiveCronMetadata(play);
|
|
12412
|
-
if (!_optionalChain([status, 'optionalAccess',
|
|
12430
|
+
if (!_optionalChain([status, 'optionalAccess', _470 => _470.cron]) && !cron.schedule && !_optionalChain([status, 'optionalAccess', _471 => _471.webhook])) return [];
|
|
12413
12431
|
const lines = [];
|
|
12414
|
-
if (_optionalChain([status, 'optionalAccess',
|
|
12432
|
+
if (_optionalChain([status, 'optionalAccess', _472 => _472.cron]) || cron.schedule) {
|
|
12415
12433
|
const timezone = cron.timezone ? ` (${cron.timezone})` : "";
|
|
12416
12434
|
lines.push(
|
|
12417
|
-
` Scheduled execution: ${cronExecutionLabel(_nullishCoalesce(_optionalChain([status, 'optionalAccess',
|
|
12435
|
+
` Scheduled execution: ${cronExecutionLabel(_nullishCoalesce(_optionalChain([status, 'optionalAccess', _473 => _473.cron]), () => ( null)))}${cron.schedule ? ` \u2014 ${cron.schedule}${timezone}` : ""}`
|
|
12418
12436
|
);
|
|
12419
|
-
if (cron.nextScheduledAt !== null && _optionalChain([status, 'optionalAccess',
|
|
12437
|
+
if (cron.nextScheduledAt !== null && _optionalChain([status, 'optionalAccess', _474 => _474.cron]) === "active") {
|
|
12420
12438
|
lines.push(
|
|
12421
12439
|
` Next scheduled run: ${formatTimestamp(cron.nextScheduledAt)}`
|
|
12422
12440
|
);
|
|
12423
12441
|
}
|
|
12424
|
-
if (_optionalChain([status, 'optionalAccess',
|
|
12442
|
+
if (_optionalChain([status, 'optionalAccess', _475 => _475.blockedReason])) {
|
|
12425
12443
|
lines.push(` Schedule issue: ${status.blockedReason}`);
|
|
12426
12444
|
if (status.blockedReasonCode || cron.blockedReasonCode) {
|
|
12427
12445
|
lines.push(
|
|
@@ -12437,7 +12455,7 @@ function liveTriggerStatusLines(status, play) {
|
|
|
12437
12455
|
);
|
|
12438
12456
|
}
|
|
12439
12457
|
}
|
|
12440
|
-
if (_optionalChain([status, 'optionalAccess',
|
|
12458
|
+
if (_optionalChain([status, 'optionalAccess', _476 => _476.webhook])) {
|
|
12441
12459
|
lines.push(` Webhook: ${status.webhook}`);
|
|
12442
12460
|
}
|
|
12443
12461
|
return lines;
|
|
@@ -12445,11 +12463,11 @@ function liveTriggerStatusLines(status, play) {
|
|
|
12445
12463
|
function triggerStatusFromMetadata(value) {
|
|
12446
12464
|
const metadata = readRecord(value);
|
|
12447
12465
|
return {
|
|
12448
|
-
cron: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12449
|
-
webhook: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12450
|
-
blockedReason: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12451
|
-
blockedReasonCode: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12452
|
-
blockedAt: typeof _optionalChain([metadata, 'optionalAccess',
|
|
12466
|
+
cron: typeof _optionalChain([metadata, 'optionalAccess', _477 => _477.cronStatus]) === "string" ? metadata.cronStatus : null,
|
|
12467
|
+
webhook: typeof _optionalChain([metadata, 'optionalAccess', _478 => _478.webhookStatus]) === "string" ? metadata.webhookStatus : null,
|
|
12468
|
+
blockedReason: typeof _optionalChain([metadata, 'optionalAccess', _479 => _479.blockedReason]) === "string" ? metadata.blockedReason : null,
|
|
12469
|
+
blockedReasonCode: typeof _optionalChain([metadata, 'optionalAccess', _480 => _480.blockedReasonCode]) === "string" ? metadata.blockedReasonCode : null,
|
|
12470
|
+
blockedAt: typeof _optionalChain([metadata, 'optionalAccess', _481 => _481.blockedAt]) === "number" ? metadata.blockedAt : null
|
|
12453
12471
|
};
|
|
12454
12472
|
}
|
|
12455
12473
|
function printPublishReceipt(input) {
|
|
@@ -12481,7 +12499,7 @@ function printBundledRuntimeWarning(bundle) {
|
|
|
12481
12499
|
async function handlePlayCheck(args) {
|
|
12482
12500
|
const options = parsePlayCheckOptions(args);
|
|
12483
12501
|
if (!isFileTarget(options.target)) {
|
|
12484
|
-
const client = new (0,
|
|
12502
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
12485
12503
|
try {
|
|
12486
12504
|
await assertCanonicalNamedPlayReference(client, options.target, {
|
|
12487
12505
|
command: "check"
|
|
@@ -12510,7 +12528,7 @@ async function handlePlayCheck(args) {
|
|
|
12510
12528
|
},
|
|
12511
12529
|
...options.full ? { diagnostics: { staticPipeline: _nullishCoalesce(play.staticPipeline, () => ( null)) } } : {}
|
|
12512
12530
|
};
|
|
12513
|
-
|
|
12531
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, result, {
|
|
12514
12532
|
json: options.jsonOutput,
|
|
12515
12533
|
fields: options.jsonFields,
|
|
12516
12534
|
text: renderPlayCheckOutput(result) + "\n"
|
|
@@ -12520,7 +12538,7 @@ async function handlePlayCheck(args) {
|
|
|
12520
12538
|
const resolved = _path.resolve.call(void 0, options.target);
|
|
12521
12539
|
const message = error instanceof Error && error.message ? error.message : `File not found: ${resolved}`;
|
|
12522
12540
|
if (options.jsonOutput) {
|
|
12523
|
-
|
|
12541
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
12524
12542
|
{
|
|
12525
12543
|
kind: "play_check",
|
|
12526
12544
|
checked: "named_contract",
|
|
@@ -12549,9 +12567,9 @@ async function handlePlayCheck(args) {
|
|
|
12549
12567
|
target: options.target,
|
|
12550
12568
|
full: options.full,
|
|
12551
12569
|
detailsCommand: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.target)} --full`,
|
|
12552
|
-
publishCommand: _optionalChain([primary, 'optionalAccess',
|
|
12570
|
+
publishCommand: _optionalChain([primary, 'optionalAccess', _482 => _482.result, 'access', _483 => _483.artifactHash]) ? `deepline plays publish ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.target)} --expected-artifact ${primary.result.artifactHash}` : void 0
|
|
12553
12571
|
});
|
|
12554
|
-
|
|
12572
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, output, {
|
|
12555
12573
|
json: options.jsonOutput,
|
|
12556
12574
|
fields: options.jsonFields,
|
|
12557
12575
|
text: renderPlayCheckOutput(output) + "\n"
|
|
@@ -12564,7 +12582,7 @@ function resolvePlayCheckExportNames(sourceCode) {
|
|
|
12564
12582
|
return exports.map((entry) => entry.name);
|
|
12565
12583
|
}
|
|
12566
12584
|
function artifactForProductionCompatibilityCheck(artifact) {
|
|
12567
|
-
const rawEdition = _optionalChain([process, 'access',
|
|
12585
|
+
const rawEdition = _optionalChain([process, 'access', _484 => _484.env, 'access', _485 => _485.DEEPLINE_PROD_CHECK_AUTHORING_CONTRACT_EDITION, 'optionalAccess', _486 => _486.trim, 'call', _487 => _487()]);
|
|
12568
12586
|
if (!rawEdition) return artifact;
|
|
12569
12587
|
if (!/^\d+$/.test(rawEdition)) {
|
|
12570
12588
|
throw new Error(
|
|
@@ -12619,7 +12637,7 @@ async function checkOneExportedPlay(input) {
|
|
|
12619
12637
|
}
|
|
12620
12638
|
const playName = _nullishCoalesce(graph.root.playName, () => ( fallbackName));
|
|
12621
12639
|
const authoringErrors = collectPlayGraphAuthoringErrors(graph);
|
|
12622
|
-
const client = _nullishCoalesce(input.client, () => ( new (0,
|
|
12640
|
+
const client = _nullishCoalesce(input.client, () => ( new (0, _chunkUJYX4VLXjs.DeeplineClient)()));
|
|
12623
12641
|
const integrationMode = resolveEvalIntegrationMode();
|
|
12624
12642
|
const checked = await checkLocalPlayGraph({
|
|
12625
12643
|
client,
|
|
@@ -12629,7 +12647,7 @@ async function checkOneExportedPlay(input) {
|
|
|
12629
12647
|
integrationMode,
|
|
12630
12648
|
prepareArtifact: artifactForProductionCompatibilityCheck
|
|
12631
12649
|
});
|
|
12632
|
-
const importedPlayName = _optionalChain([checked, 'access',
|
|
12650
|
+
const importedPlayName = _optionalChain([checked, 'access', _488 => _488.failedChild, 'optionalAccess', _489 => _489.playName]);
|
|
12633
12651
|
const diagnosticPrefix = importedPlayName ? `Imported Play ${importedPlayName}: ` : "";
|
|
12634
12652
|
const valid = checked.result.valid && !checked.failedChild && authoringErrors.length === 0;
|
|
12635
12653
|
const errors = [
|
|
@@ -12645,7 +12663,7 @@ async function checkOneExportedPlay(input) {
|
|
|
12645
12663
|
valid,
|
|
12646
12664
|
errors: valid ? checked.result.errors : addPlayCheckRepairHints({
|
|
12647
12665
|
errors,
|
|
12648
|
-
sourceCode: _nullishCoalesce(_optionalChain([checked, 'access',
|
|
12666
|
+
sourceCode: _nullishCoalesce(_optionalChain([checked, 'access', _490 => _490.failedChild, 'optionalAccess', _491 => _491.sourceCode]), () => ( graph.root.sourceCode))
|
|
12649
12667
|
}),
|
|
12650
12668
|
...checked.failedChild && checked.result.issues ? {
|
|
12651
12669
|
issues: checked.result.issues.map((issue) => ({
|
|
@@ -12675,9 +12693,9 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12675
12693
|
let prefetchClient;
|
|
12676
12694
|
let admissionCapability;
|
|
12677
12695
|
let cancelAdmissionCapability;
|
|
12678
|
-
let cliAdmission =
|
|
12679
|
-
const progress = _nullishCoalesce(
|
|
12680
|
-
const reportError = _nullishCoalesce(_optionalChain([hooks, 'optionalAccess',
|
|
12696
|
+
let cliAdmission = _chunkWHYNYL3Mjs.usesCliPlayAdmission.call(void 0, "plays run", process.argv.slice(2));
|
|
12697
|
+
const progress = _nullishCoalesce(_chunkAOYW62XOjs.getActiveCliProgress.call(void 0, ), () => ( _chunkAOYW62XOjs.createCliProgress.call(void 0, !options.jsonOutput)));
|
|
12698
|
+
const reportError = _nullishCoalesce(_optionalChain([hooks, 'optionalAccess', _492 => _492.writeDryRunError]), () => ( ((error) => console.error(error instanceof Error ? error.message : String(error)))));
|
|
12681
12699
|
const absolutePlayPath = _path.resolve.call(void 0, options.target.path);
|
|
12682
12700
|
progress.phase("compiling play");
|
|
12683
12701
|
const sourceCode = traceCliSync(
|
|
@@ -12693,11 +12711,11 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12693
12711
|
return 1;
|
|
12694
12712
|
}
|
|
12695
12713
|
if (!options.dryRun && options.watch && cliAdmission && Boolean(options.runIdFile) && options.maxTotalCredits === null && !inputContainsLocalFilePath(runtimeInput)) {
|
|
12696
|
-
const clientForPrefetch = new (0,
|
|
12714
|
+
const clientForPrefetch = new (0, _chunkUJYX4VLXjs.DeeplineClient)(playRunClientOptions(options));
|
|
12697
12715
|
prefetchClient = clientForPrefetch;
|
|
12698
12716
|
const capabilityController = new AbortController();
|
|
12699
12717
|
cancelAdmissionCapability = () => capabilityController.abort();
|
|
12700
|
-
admissionCapability =
|
|
12718
|
+
admissionCapability = _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
12701
12719
|
"cli.play_admission_capability_prefetch",
|
|
12702
12720
|
{ targetKind: "file" },
|
|
12703
12721
|
() => clientForPrefetch.prefetchPlayRunAdmissionCapability({
|
|
@@ -12708,7 +12726,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12708
12726
|
}
|
|
12709
12727
|
let graph;
|
|
12710
12728
|
try {
|
|
12711
|
-
graph = await
|
|
12729
|
+
graph = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
12712
12730
|
"cli.play_file_bundle_graph",
|
|
12713
12731
|
{ targetKind: "file" },
|
|
12714
12732
|
() => collectBundledPlayGraph(
|
|
@@ -12721,10 +12739,10 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12721
12739
|
assertPlayGraphAuthoring(graph);
|
|
12722
12740
|
if (options.dryRun) {
|
|
12723
12741
|
progress.complete();
|
|
12724
|
-
const plan =
|
|
12742
|
+
const plan = _chunkHKWJD45Vjs.planLocalPlayExecution.call(void 0, graph, {
|
|
12725
12743
|
runIdFile: options.runIdFile
|
|
12726
12744
|
});
|
|
12727
|
-
if (_optionalChain([hooks, 'optionalAccess',
|
|
12745
|
+
if (_optionalChain([hooks, 'optionalAccess', _493 => _493.writeDryRunPlan])) hooks.writeDryRunPlan(plan);
|
|
12728
12746
|
else
|
|
12729
12747
|
renderLocalPlayExecutionPlan(plan, {
|
|
12730
12748
|
dryRun: true,
|
|
@@ -12732,9 +12750,9 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12732
12750
|
});
|
|
12733
12751
|
return 0;
|
|
12734
12752
|
}
|
|
12735
|
-
client = _nullishCoalesce(prefetchClient, () => ( new (0,
|
|
12753
|
+
client = _nullishCoalesce(prefetchClient, () => ( new (0, _chunkUJYX4VLXjs.DeeplineClient)(playRunClientOptions(options))));
|
|
12736
12754
|
if (cliAdmission && (graph.root.importedPlayDependencies.length > 0 || inputContainsLocalFilePath(runtimeInput))) {
|
|
12737
|
-
await
|
|
12755
|
+
await _chunkWHYNYL3Mjs.checkPlayRunCompatibility.call(void 0,
|
|
12738
12756
|
client.baseUrl,
|
|
12739
12757
|
options.maintenancePolicy
|
|
12740
12758
|
);
|
|
@@ -12747,7 +12765,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12747
12765
|
});
|
|
12748
12766
|
const canDeferCompilerManifest = graph.root.importedPlayDependencies.length === 0 && !sourceGraphMentionsRunPlay(graph.root) && !inputContainsLocalFilePath(runtimeInput) && !mayBindBareFileName(graph.root, runtimeInput);
|
|
12749
12767
|
if (canDeferCompilerManifest) {
|
|
12750
|
-
|
|
12768
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
12751
12769
|
phase: "cli.play_file_compile_manifests",
|
|
12752
12770
|
ms: 0,
|
|
12753
12771
|
ok: true,
|
|
@@ -12756,7 +12774,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12756
12774
|
reason: "validated_by_run_route"
|
|
12757
12775
|
});
|
|
12758
12776
|
} else {
|
|
12759
|
-
await
|
|
12777
|
+
await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
12760
12778
|
"cli.play_file_compile_manifests",
|
|
12761
12779
|
{ targetKind: "file", skipped: false },
|
|
12762
12780
|
() => compileBundledPlayGraphManifests(client, graph)
|
|
@@ -12764,7 +12782,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12764
12782
|
}
|
|
12765
12783
|
progress.phase("compiled play");
|
|
12766
12784
|
} catch (error) {
|
|
12767
|
-
if (error instanceof
|
|
12785
|
+
if (error instanceof _chunkTNUM4DFAjs.ExecutionOutputError) throw error;
|
|
12768
12786
|
progress.fail();
|
|
12769
12787
|
reportError(normalizePlayValidationError(error));
|
|
12770
12788
|
return 1;
|
|
@@ -12775,13 +12793,13 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12775
12793
|
if (bundleResult.importedPlayDependencies.length > 0) {
|
|
12776
12794
|
try {
|
|
12777
12795
|
renderLocalPlayExecutionPlan(
|
|
12778
|
-
|
|
12796
|
+
_chunkHKWJD45Vjs.planLocalPlayExecution.call(void 0, graph, { runIdFile: options.runIdFile })
|
|
12779
12797
|
);
|
|
12780
12798
|
progress.phase("pinning imported plays");
|
|
12781
|
-
graph = await
|
|
12799
|
+
graph = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
12782
12800
|
"cli.play_file_pin_imports",
|
|
12783
12801
|
{ targetKind: "file" },
|
|
12784
|
-
() =>
|
|
12802
|
+
() => _chunkHKWJD45Vjs.pinLocalPlayImports.call(void 0, client, graph)
|
|
12785
12803
|
);
|
|
12786
12804
|
bundleResult = graph.root;
|
|
12787
12805
|
} catch (error) {
|
|
@@ -12795,10 +12813,10 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12795
12813
|
);
|
|
12796
12814
|
const compilerManifest = _nullishCoalesce(bundleResult.compilerManifest, () => ( null));
|
|
12797
12815
|
const fileInputBindings = _chunkCQDQNZGHjs.playRunFileInputBindings.call(void 0, {
|
|
12798
|
-
inputSchema: _optionalChain([compilerManifest, 'optionalAccess',
|
|
12799
|
-
staticPipeline: _optionalChain([compilerManifest, 'optionalAccess',
|
|
12816
|
+
inputSchema: _optionalChain([compilerManifest, 'optionalAccess', _494 => _494.authoringContract, 'optionalAccess', _495 => _495.inputSchema]),
|
|
12817
|
+
staticPipeline: _optionalChain([compilerManifest, 'optionalAccess', _496 => _496.staticPipeline])
|
|
12800
12818
|
});
|
|
12801
|
-
const stagedFileInputs = await
|
|
12819
|
+
const stagedFileInputs = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
12802
12820
|
"cli.play_stage_inputs",
|
|
12803
12821
|
{
|
|
12804
12822
|
targetKind: "file",
|
|
@@ -12848,7 +12866,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12848
12866
|
};
|
|
12849
12867
|
if (options.watch) {
|
|
12850
12868
|
progress.phase("starting run");
|
|
12851
|
-
const finalStatus = await
|
|
12869
|
+
const finalStatus = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
12852
12870
|
"cli.play_start_watch",
|
|
12853
12871
|
{ targetKind: "file", playName },
|
|
12854
12872
|
() => (options.runIdFile ? startAndWaitForPlayCompletionByStream : startAndWaitForPlayCompletion)({
|
|
@@ -12862,9 +12880,9 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12862
12880
|
waitTimeoutMs: options.waitTimeoutMs,
|
|
12863
12881
|
open: options.open,
|
|
12864
12882
|
progress,
|
|
12865
|
-
onRunStarted: _optionalChain([hooks, 'optionalAccess',
|
|
12866
|
-
onSubmission: _optionalChain([hooks, 'optionalAccess',
|
|
12867
|
-
onRunAdmitted: _optionalChain([hooks, 'optionalAccess',
|
|
12883
|
+
onRunStarted: _optionalChain([hooks, 'optionalAccess', _497 => _497.onRunStarted]),
|
|
12884
|
+
onSubmission: _optionalChain([hooks, 'optionalAccess', _498 => _498.onSubmission]),
|
|
12885
|
+
onRunAdmitted: _optionalChain([hooks, 'optionalAccess', _499 => _499.onRunAdmitted]),
|
|
12868
12886
|
maintenancePolicy: options.maintenancePolicy,
|
|
12869
12887
|
...!options.runIdFile || options.fullJson ? { fullJson: options.fullJson } : {},
|
|
12870
12888
|
...cliAdmission ? {
|
|
@@ -12894,8 +12912,8 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12894
12912
|
),
|
|
12895
12913
|
options
|
|
12896
12914
|
);
|
|
12897
|
-
_optionalChain([hooks, 'optionalAccess',
|
|
12898
|
-
if (_optionalChain([hooks, 'optionalAccess',
|
|
12915
|
+
_optionalChain([hooks, 'optionalAccess', _500 => _500.onTerminalStatus, 'optionalCall', _501 => _501(outputStatus)]);
|
|
12916
|
+
if (_optionalChain([hooks, 'optionalAccess', _502 => _502.writeResult])) {
|
|
12899
12917
|
await hooks.writeResult(client, outputStatus);
|
|
12900
12918
|
return outputStatus.status === "completed" ? 0 : 1;
|
|
12901
12919
|
}
|
|
@@ -12910,15 +12928,15 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12910
12928
|
return outputStatus.status === "completed" ? 0 : 1;
|
|
12911
12929
|
}
|
|
12912
12930
|
progress.phase("starting run");
|
|
12913
|
-
const started = await
|
|
12931
|
+
const started = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
12914
12932
|
"cli.play_start_unwatched",
|
|
12915
12933
|
{ targetKind: "file", playName },
|
|
12916
|
-
() => client.startPlayRun(startRequest, { onSubmission: _optionalChain([hooks, 'optionalAccess',
|
|
12934
|
+
() => client.startPlayRun(startRequest, { onSubmission: _optionalChain([hooks, 'optionalAccess', _503 => _503.onSubmission]) }).catch(async (error) => {
|
|
12917
12935
|
throw await normalizePlayStartError(client, error, playName);
|
|
12918
12936
|
})
|
|
12919
12937
|
);
|
|
12920
|
-
await _optionalChain([hooks, 'optionalAccess',
|
|
12921
|
-
await _optionalChain([hooks, 'optionalAccess',
|
|
12938
|
+
await _optionalChain([hooks, 'optionalAccess', _504 => _504.onRunStarted, 'optionalCall', _505 => _505(started.workflowId)]);
|
|
12939
|
+
await _optionalChain([hooks, 'optionalAccess', _506 => _506.onRunAdmitted, 'optionalCall', _507 => _507(started.workflowId)]);
|
|
12922
12940
|
const resolvedDashboardUrl = _chunkXYIECA7Mjs.buildPlayDashboardUrl.call(void 0, client.baseUrl, playName);
|
|
12923
12941
|
openPlayDashboard(
|
|
12924
12942
|
resolvePlayRunUrl({
|
|
@@ -12930,7 +12948,7 @@ async function handleFileBackedRun(options, hooks) {
|
|
|
12930
12948
|
);
|
|
12931
12949
|
progress.phase("started run");
|
|
12932
12950
|
progress.complete();
|
|
12933
|
-
if (_optionalChain([hooks, 'optionalAccess',
|
|
12951
|
+
if (_optionalChain([hooks, 'optionalAccess', _508 => _508.writeStarted])) {
|
|
12934
12952
|
hooks.writeStarted(
|
|
12935
12953
|
started.workflowId,
|
|
12936
12954
|
_nullishCoalesce(started.status, () => ( "started")),
|
|
@@ -12965,7 +12983,7 @@ async function resolveNamedRunRevisionId(input) {
|
|
|
12965
12983
|
if (input.selector === "latest") {
|
|
12966
12984
|
const versions = await input.client.listPlayVersions(input.playName);
|
|
12967
12985
|
const latest = versions[0];
|
|
12968
|
-
if (!_optionalChain([latest, 'optionalAccess',
|
|
12986
|
+
if (!_optionalChain([latest, 'optionalAccess', _509 => _509._id])) {
|
|
12969
12987
|
throw new Error(`No saved revisions found for ${input.playName}.`);
|
|
12970
12988
|
}
|
|
12971
12989
|
return latest._id;
|
|
@@ -12976,9 +12994,9 @@ async function handleNamedRun(options, hooks) {
|
|
|
12976
12994
|
if (options.target.kind !== "name") {
|
|
12977
12995
|
throw new Error("Expected a named play run target.");
|
|
12978
12996
|
}
|
|
12979
|
-
const client = new (0,
|
|
12980
|
-
let cliAdmission =
|
|
12981
|
-
const progress = _nullishCoalesce(
|
|
12997
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)(playRunClientOptions(options));
|
|
12998
|
+
let cliAdmission = _chunkWHYNYL3Mjs.usesCliPlayAdmission.call(void 0, "plays run", process.argv.slice(2));
|
|
12999
|
+
const progress = _nullishCoalesce(_chunkAOYW62XOjs.getActiveCliProgress.call(void 0, ), () => ( _chunkAOYW62XOjs.createCliProgress.call(void 0, !options.jsonOutput)));
|
|
12982
13000
|
const playName = options.target.name;
|
|
12983
13001
|
const runtimeInput = options.input ? { ...options.input } : {};
|
|
12984
13002
|
try {
|
|
@@ -12996,7 +13014,7 @@ async function handleNamedRun(options, hooks) {
|
|
|
12996
13014
|
if (options.watch && cliAdmission && Boolean(options.runIdFile) && options.maxTotalCredits === null && !needsPlayDefinition && !inputContainsLocalFilePath(runtimeInput)) {
|
|
12997
13015
|
const capabilityController = new AbortController();
|
|
12998
13016
|
cancelAdmissionCapability = () => capabilityController.abort();
|
|
12999
|
-
admissionCapability =
|
|
13017
|
+
admissionCapability = _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
13000
13018
|
"cli.play_admission_capability_prefetch",
|
|
13001
13019
|
{ targetKind: "name", playName },
|
|
13002
13020
|
() => client.prefetchPlayRunAdmissionCapability({
|
|
@@ -13007,14 +13025,14 @@ async function handleNamedRun(options, hooks) {
|
|
|
13007
13025
|
}
|
|
13008
13026
|
const playDetail = needsPlayDefinition ? await (async () => {
|
|
13009
13027
|
progress.phase("loading play definition");
|
|
13010
|
-
return
|
|
13028
|
+
return _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
13011
13029
|
"cli.play_load_definition",
|
|
13012
13030
|
{ targetKind: "name", playName, skipped: false },
|
|
13013
13031
|
() => assertCanonicalNamedPlayReference(client, playName, {
|
|
13014
13032
|
command: "run"
|
|
13015
13033
|
})
|
|
13016
13034
|
);
|
|
13017
|
-
})() : (
|
|
13035
|
+
})() : (_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
13018
13036
|
phase: "cli.play_load_definition",
|
|
13019
13037
|
ms: 0,
|
|
13020
13038
|
ok: true,
|
|
@@ -13023,7 +13041,7 @@ async function handleNamedRun(options, hooks) {
|
|
|
13023
13041
|
skipped: true
|
|
13024
13042
|
}), null);
|
|
13025
13043
|
progress.phase("selecting revision");
|
|
13026
|
-
const selectedRevisionId = await
|
|
13044
|
+
const selectedRevisionId = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
13027
13045
|
"cli.play_select_revision",
|
|
13028
13046
|
{
|
|
13029
13047
|
targetKind: "name",
|
|
@@ -13048,10 +13066,10 @@ async function handleNamedRun(options, hooks) {
|
|
|
13048
13066
|
..._chunkCQDQNZGHjs.fileInputBindingsFromStaticPipeline.call(void 0, playDetail.play.staticPipeline)
|
|
13049
13067
|
] : [];
|
|
13050
13068
|
if (cliAdmission && fileInputBindings.length > 0) {
|
|
13051
|
-
await
|
|
13069
|
+
await _chunkWHYNYL3Mjs.checkPlayRunCompatibility.call(void 0, client.baseUrl, options.maintenancePolicy);
|
|
13052
13070
|
cliAdmission = false;
|
|
13053
13071
|
}
|
|
13054
|
-
const stagedFileInputs = await
|
|
13072
|
+
const stagedFileInputs = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
13055
13073
|
"cli.play_stage_inputs",
|
|
13056
13074
|
{
|
|
13057
13075
|
targetKind: "name",
|
|
@@ -13095,7 +13113,7 @@ async function handleNamedRun(options, hooks) {
|
|
|
13095
13113
|
});
|
|
13096
13114
|
if (options.watch) {
|
|
13097
13115
|
progress.phase("starting run");
|
|
13098
|
-
const finalStatus = await
|
|
13116
|
+
const finalStatus = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
13099
13117
|
"cli.play_start_watch",
|
|
13100
13118
|
{ targetKind: "name", playName },
|
|
13101
13119
|
() => (options.runIdFile ? startAndWaitForPlayCompletionByStream : startAndWaitForPlayCompletion)({
|
|
@@ -13109,9 +13127,9 @@ async function handleNamedRun(options, hooks) {
|
|
|
13109
13127
|
waitTimeoutMs: options.waitTimeoutMs,
|
|
13110
13128
|
open: options.open,
|
|
13111
13129
|
progress,
|
|
13112
|
-
onRunStarted: _optionalChain([hooks, 'optionalAccess',
|
|
13113
|
-
onSubmission: _optionalChain([hooks, 'optionalAccess',
|
|
13114
|
-
onRunAdmitted: _optionalChain([hooks, 'optionalAccess',
|
|
13130
|
+
onRunStarted: _optionalChain([hooks, 'optionalAccess', _510 => _510.onRunStarted]),
|
|
13131
|
+
onSubmission: _optionalChain([hooks, 'optionalAccess', _511 => _511.onSubmission]),
|
|
13132
|
+
onRunAdmitted: _optionalChain([hooks, 'optionalAccess', _512 => _512.onRunAdmitted]),
|
|
13115
13133
|
maintenancePolicy: options.maintenancePolicy,
|
|
13116
13134
|
...!options.runIdFile || options.fullJson ? { fullJson: options.fullJson } : {},
|
|
13117
13135
|
...cliAdmission ? {
|
|
@@ -13144,8 +13162,8 @@ async function handleNamedRun(options, hooks) {
|
|
|
13144
13162
|
options,
|
|
13145
13163
|
_nullishCoalesce(finalStatus.revisionId, () => ( selectedRevisionId))
|
|
13146
13164
|
);
|
|
13147
|
-
_optionalChain([hooks, 'optionalAccess',
|
|
13148
|
-
if (_optionalChain([hooks, 'optionalAccess',
|
|
13165
|
+
_optionalChain([hooks, 'optionalAccess', _513 => _513.onTerminalStatus, 'optionalCall', _514 => _514(outputStatus)]);
|
|
13166
|
+
if (_optionalChain([hooks, 'optionalAccess', _515 => _515.writeResult])) {
|
|
13149
13167
|
await hooks.writeResult(client, outputStatus);
|
|
13150
13168
|
return outputStatus.status === "completed" ? 0 : 1;
|
|
13151
13169
|
}
|
|
@@ -13160,17 +13178,17 @@ async function handleNamedRun(options, hooks) {
|
|
|
13160
13178
|
return outputStatus.status === "completed" ? 0 : 1;
|
|
13161
13179
|
}
|
|
13162
13180
|
progress.phase("starting run");
|
|
13163
|
-
const started = await
|
|
13181
|
+
const started = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
13164
13182
|
"cli.play_start_unwatched",
|
|
13165
13183
|
{ targetKind: "name", playName },
|
|
13166
|
-
() => client.startPlayRun(startRequest, { onSubmission: _optionalChain([hooks, 'optionalAccess',
|
|
13184
|
+
() => client.startPlayRun(startRequest, { onSubmission: _optionalChain([hooks, 'optionalAccess', _516 => _516.onSubmission]) }).catch(async (error) => {
|
|
13167
13185
|
throw await normalizePlayStartError(client, error, playName, {
|
|
13168
13186
|
suggestMissingPlay: true
|
|
13169
13187
|
});
|
|
13170
13188
|
})
|
|
13171
13189
|
);
|
|
13172
|
-
await _optionalChain([hooks, 'optionalAccess',
|
|
13173
|
-
await _optionalChain([hooks, 'optionalAccess',
|
|
13190
|
+
await _optionalChain([hooks, 'optionalAccess', _517 => _517.onRunStarted, 'optionalCall', _518 => _518(started.workflowId)]);
|
|
13191
|
+
await _optionalChain([hooks, 'optionalAccess', _519 => _519.onRunAdmitted, 'optionalCall', _520 => _520(started.workflowId)]);
|
|
13174
13192
|
const resolvedDashboardUrl = _chunkXYIECA7Mjs.buildPlayDashboardUrl.call(void 0, client.baseUrl, playName);
|
|
13175
13193
|
openPlayDashboard(
|
|
13176
13194
|
resolvePlayRunUrl({
|
|
@@ -13182,7 +13200,7 @@ async function handleNamedRun(options, hooks) {
|
|
|
13182
13200
|
);
|
|
13183
13201
|
progress.phase("started run");
|
|
13184
13202
|
progress.complete();
|
|
13185
|
-
if (_optionalChain([hooks, 'optionalAccess',
|
|
13203
|
+
if (_optionalChain([hooks, 'optionalAccess', _521 => _521.writeStarted])) {
|
|
13186
13204
|
hooks.writeStarted(
|
|
13187
13205
|
started.workflowId,
|
|
13188
13206
|
_nullishCoalesce(started.status, () => ( "started")),
|
|
@@ -13215,12 +13233,12 @@ async function writePlayRunReceipt(client, status, output) {
|
|
|
13215
13233
|
const compact = compactPlayStatus(status);
|
|
13216
13234
|
const errors = Array.isArray(compact.errors) ? compact.errors : [];
|
|
13217
13235
|
const error = status.status === "failed" ? _nullishCoalesce(errors[0], () => ( {
|
|
13218
|
-
message: _nullishCoalesce(_nullishCoalesce(compact.error, () => ( _optionalChain([status, 'access',
|
|
13236
|
+
message: _nullishCoalesce(_nullishCoalesce(compact.error, () => ( _optionalChain([status, 'access', _522 => _522.progress, 'optionalAccess', _523 => _523.error]))), () => ( "Play failed. Inspect the run for details."))
|
|
13219
13237
|
})) : null;
|
|
13220
13238
|
const next = { status: `deepline runs get ${status.runId}` };
|
|
13221
|
-
const playName = _nullishCoalesce(_nullishCoalesce(_optionalChain([/^play\/(.+)\/run\//, 'access',
|
|
13239
|
+
const playName = _nullishCoalesce(_nullishCoalesce(_optionalChain([/^play\/(.+)\/run\//, 'access', _524 => _524.exec, 'call', _525 => _525(status.runId), 'optionalAccess', _526 => _526[1]]), () => ( extractRunPlayName(status))), () => ( null));
|
|
13222
13240
|
if (!terminal) {
|
|
13223
|
-
|
|
13241
|
+
_chunkTNUM4DFAjs.writeExecutionOutput.call(void 0,
|
|
13224
13242
|
{
|
|
13225
13243
|
id: status.runId,
|
|
13226
13244
|
status: status.status,
|
|
@@ -13284,11 +13302,11 @@ async function writePlayRunReceipt(client, status, output) {
|
|
|
13284
13302
|
Object.entries(handle).filter(([key]) => source !== "result" || key !== "_metadata").map(([key, child]) => [key, materialize(child, `${source}.${key}`)])
|
|
13285
13303
|
);
|
|
13286
13304
|
};
|
|
13287
|
-
const packagedOutputs = readRecord(_optionalChain([getPlayRunPackage, 'call',
|
|
13305
|
+
const packagedOutputs = readRecord(_optionalChain([getPlayRunPackage, 'call', _527 => _527(status), 'optionalAccess', _528 => _528.outputs]));
|
|
13288
13306
|
const returned = status.result !== void 0 ? status.result : packagedOutputs ? Object.fromEntries(
|
|
13289
13307
|
Object.entries(packagedOutputs).map(([key, value]) => [
|
|
13290
13308
|
key,
|
|
13291
|
-
_optionalChain([readRecord, 'call',
|
|
13309
|
+
_optionalChain([readRecord, 'call', _529 => _529(value), 'optionalAccess', _530 => _530.kind]) === "value" ? _optionalChain([readRecord, 'call', _531 => _531(value), 'optionalAccess', _532 => _532.value]) : value
|
|
13292
13310
|
])
|
|
13293
13311
|
) : null;
|
|
13294
13312
|
let data = materialize(returned);
|
|
@@ -13300,10 +13318,10 @@ async function writePlayRunReceipt(client, status, output) {
|
|
|
13300
13318
|
};
|
|
13301
13319
|
}
|
|
13302
13320
|
const byRows = new Map(collections.map((c) => [c.rows, c]));
|
|
13303
|
-
const allCollections =
|
|
13321
|
+
const allCollections = _chunkTNUM4DFAjs.outputCollections.call(void 0, data).map(
|
|
13304
13322
|
(collection) => _nullishCoalesce(byRows.get(collection.rows), () => ( collection))
|
|
13305
13323
|
);
|
|
13306
|
-
|
|
13324
|
+
_chunkTNUM4DFAjs.writeExecutionOutput.call(void 0,
|
|
13307
13325
|
{
|
|
13308
13326
|
id: status.runId,
|
|
13309
13327
|
status: status.status,
|
|
@@ -13311,7 +13329,7 @@ async function writePlayRunReceipt(client, status, output) {
|
|
|
13311
13329
|
...allCollections.length ? { collections: allCollections } : {},
|
|
13312
13330
|
complete: allCollections.every((c) => c.complete === true) ? true : allCollections.some((c) => c.complete === false) ? false : null,
|
|
13313
13331
|
error,
|
|
13314
|
-
credits: _nullishCoalesce(_nullishCoalesce(status.billingTotalCreditsRollup, () => ( _optionalChain([status, 'access',
|
|
13332
|
+
credits: _nullishCoalesce(_nullishCoalesce(status.billingTotalCreditsRollup, () => ( _optionalChain([status, 'access', _533 => _533.billing, 'optionalAccess', _534 => _534.totalCredits]))), () => ( null)),
|
|
13315
13333
|
...playName ? { page: _chunkXYIECA7Mjs.buildPlayRunUrl.call(void 0, client.baseUrl, playName, status.runId) } : {},
|
|
13316
13334
|
warnings: [
|
|
13317
13335
|
...buildRunWarnings(status, null),
|
|
@@ -13324,7 +13342,7 @@ async function writePlayRunReceipt(client, status, output) {
|
|
|
13324
13342
|
}
|
|
13325
13343
|
var TOOL_EXECUTION_ID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
13326
13344
|
async function handlePlayRun(args, hooks) {
|
|
13327
|
-
const parsedOptions = Array.isArray(args) ?
|
|
13345
|
+
const parsedOptions = Array.isArray(args) ? _chunkXL3CEPZAjs.parsePlayRunOptions.call(void 0, args) : args;
|
|
13328
13346
|
const options = parsedOptions.runIdFile ? {
|
|
13329
13347
|
...parsedOptions,
|
|
13330
13348
|
runIdFile: parsedOptions.dryRun ? _path.resolve.call(void 0, parsedOptions.runIdFile) : await preflightRunIdFile(parsedOptions.runIdFile)
|
|
@@ -13341,7 +13359,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
13341
13359
|
JSON.stringify({
|
|
13342
13360
|
version: 1,
|
|
13343
13361
|
admissionState: "submitted_unknown",
|
|
13344
|
-
baseUrl: new (0,
|
|
13362
|
+
baseUrl: new (0, _chunkUJYX4VLXjs.DeeplineClient)().baseUrl,
|
|
13345
13363
|
...intent
|
|
13346
13364
|
})
|
|
13347
13365
|
);
|
|
@@ -13353,7 +13371,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
13353
13371
|
} finally {
|
|
13354
13372
|
await removeRunIdTempFile(tempPath);
|
|
13355
13373
|
}
|
|
13356
|
-
await _optionalChain([hooks, 'optionalAccess',
|
|
13374
|
+
await _optionalChain([hooks, 'optionalAccess', _535 => _535.onSubmission, 'optionalCall', _536 => _536(intent)]);
|
|
13357
13375
|
},
|
|
13358
13376
|
onRunStarted: async (runId) => {
|
|
13359
13377
|
try {
|
|
@@ -13364,7 +13382,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
13364
13382
|
{ cause: error }
|
|
13365
13383
|
);
|
|
13366
13384
|
}
|
|
13367
|
-
await _optionalChain([hooks, 'optionalAccess',
|
|
13385
|
+
await _optionalChain([hooks, 'optionalAccess', _537 => _537.onRunStarted, 'optionalCall', _538 => _538(runId)]);
|
|
13368
13386
|
},
|
|
13369
13387
|
onRunAdmitted: async (runId) => {
|
|
13370
13388
|
try {
|
|
@@ -13377,7 +13395,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
13377
13395
|
{ cause: error }
|
|
13378
13396
|
);
|
|
13379
13397
|
}
|
|
13380
|
-
await _optionalChain([hooks, 'optionalAccess',
|
|
13398
|
+
await _optionalChain([hooks, 'optionalAccess', _539 => _539.onRunAdmitted, 'optionalCall', _540 => _540(runId)]);
|
|
13381
13399
|
}
|
|
13382
13400
|
} : hooks;
|
|
13383
13401
|
if (options.target.kind === "file") {
|
|
@@ -13386,7 +13404,7 @@ async function handlePlayRun(args, hooks) {
|
|
|
13386
13404
|
}
|
|
13387
13405
|
const resolved = _path.resolve.call(void 0, options.target.path);
|
|
13388
13406
|
const message = `File not found: ${resolved}`;
|
|
13389
|
-
if (_optionalChain([runHooks, 'optionalAccess',
|
|
13407
|
+
if (_optionalChain([runHooks, 'optionalAccess', _541 => _541.writeDryRunError])) {
|
|
13390
13408
|
runHooks.writeDryRunError(message);
|
|
13391
13409
|
return 1;
|
|
13392
13410
|
}
|
|
@@ -13465,10 +13483,10 @@ function renderRunOverviewText(overview, extras = {}) {
|
|
|
13465
13483
|
...buildRunActivityTextLines(run),
|
|
13466
13484
|
...buildRunStatusEvidenceTextLines(overview)
|
|
13467
13485
|
];
|
|
13468
|
-
if (_optionalChain([overview, 'access',
|
|
13486
|
+
if (_optionalChain([overview, 'access', _542 => _542.runStatus, 'optionalAccess', _543 => _543.available]) === false)
|
|
13469
13487
|
lines.push(` call progress: unavailable (${overview.runStatus.reason})`);
|
|
13470
|
-
const work = readRecord(_optionalChain([readRecord, 'call',
|
|
13471
|
-
if (work && !_optionalChain([overview, 'access',
|
|
13488
|
+
const work = readRecord(_optionalChain([readRecord, 'call', _544 => _544(run), 'optionalAccess', _545 => _545.work]));
|
|
13489
|
+
if (work && !_optionalChain([overview, 'access', _546 => _546.runStatus, 'optionalAccess', _547 => _547.available]))
|
|
13472
13490
|
lines.push(
|
|
13473
13491
|
` calls (${_nullishCoalesce(work.scope, () => ( "attempt scope unknown"))}): ${formatObservedRunCounter({ value: work.logicalCalls, confirmed: true })} logical, ${formatObservedRunCounter({ value: work.providerRequests, confirmed: true })} provider requests`
|
|
13474
13492
|
);
|
|
@@ -13534,7 +13552,7 @@ function renderRunOverviewText(overview, extras = {}) {
|
|
|
13534
13552
|
...overview.failedLogs.warning ? [`warning: ${overview.failedLogs.warning}`] : [],
|
|
13535
13553
|
...overview.failedLogs.logsTruncated ? ["Older log bodies were not retained."] : [],
|
|
13536
13554
|
...overview.failedLogs.entries,
|
|
13537
|
-
..._optionalChain([overview, 'access',
|
|
13555
|
+
..._optionalChain([overview, 'access', _548 => _548.failedLogs, 'access', _549 => _549.next, 'optionalAccess', _550 => _550.logs]) ? [`More logs: ${overview.failedLogs.next.logs}`] : []
|
|
13538
13556
|
]
|
|
13539
13557
|
});
|
|
13540
13558
|
sections.push({
|
|
@@ -13594,7 +13612,7 @@ function renderRunOverviewText(overview, extras = {}) {
|
|
|
13594
13612
|
);
|
|
13595
13613
|
return `${lines.join("\n")}
|
|
13596
13614
|
|
|
13597
|
-
${
|
|
13615
|
+
${_chunkVAOGM5VSjs.renderCommandEnvelopeText.call(void 0, { render: { sections, actions: actions2 } })}`;
|
|
13598
13616
|
}
|
|
13599
13617
|
var RUN_READ_TIMING_PROGRESS_INTERVAL_MS = 15e3;
|
|
13600
13618
|
async function withRunReadTiming(command, stage, enabled, action) {
|
|
@@ -13605,7 +13623,7 @@ async function withRunReadTiming(command, stage, enabled, action) {
|
|
|
13605
13623
|
const progressTimer = setInterval(() => {
|
|
13606
13624
|
console.error(`[${command}] ${stage} still running after ${elapsedMs()}ms`);
|
|
13607
13625
|
}, RUN_READ_TIMING_PROGRESS_INTERVAL_MS);
|
|
13608
|
-
_optionalChain([progressTimer, 'access',
|
|
13626
|
+
_optionalChain([progressTimer, 'access', _551 => _551.unref, 'optionalCall', _552 => _552()]);
|
|
13609
13627
|
try {
|
|
13610
13628
|
const result = await action();
|
|
13611
13629
|
console.error(`[${command}] ${stage} completed in ${elapsedMs()}ms`);
|
|
@@ -13618,7 +13636,7 @@ async function withRunReadTiming(command, stage, enabled, action) {
|
|
|
13618
13636
|
}
|
|
13619
13637
|
}
|
|
13620
13638
|
async function handleRunGet(args) {
|
|
13621
|
-
const selection =
|
|
13639
|
+
const selection = _chunkVAOGM5VSjs.parseJsonFields.call(void 0,
|
|
13622
13640
|
args,
|
|
13623
13641
|
args.includes("--config") ? "config" : "get"
|
|
13624
13642
|
);
|
|
@@ -13631,7 +13649,7 @@ async function handleRunGet(args) {
|
|
|
13631
13649
|
console.error(error instanceof Error ? error.message : usage2);
|
|
13632
13650
|
return 1;
|
|
13633
13651
|
}
|
|
13634
|
-
const client = new (0,
|
|
13652
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
13635
13653
|
const timing = args.includes("--timing");
|
|
13636
13654
|
const web = args.includes("--web");
|
|
13637
13655
|
if (web || args.includes("--web-url")) {
|
|
@@ -13649,8 +13667,8 @@ async function handleRunGet(args) {
|
|
|
13649
13667
|
const dashboardUrl2 = _chunkXYIECA7Mjs.buildPlayDashboardUrl.call(void 0, client.baseUrl, playName2);
|
|
13650
13668
|
const runUrl2 = _chunkXYIECA7Mjs.buildPlayRunUrl.call(void 0, client.baseUrl, playName2, runId);
|
|
13651
13669
|
if (web) {
|
|
13652
|
-
const opened =
|
|
13653
|
-
|
|
13670
|
+
const opened = _chunkVAOGM5VSjs.openInBrowser.call(void 0, runUrl2);
|
|
13671
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
13654
13672
|
{ dashboardUrl: dashboardUrl2, runUrl: runUrl2, opened: opened === "opened" },
|
|
13655
13673
|
{
|
|
13656
13674
|
json: args.includes("--json"),
|
|
@@ -13661,7 +13679,7 @@ async function handleRunGet(args) {
|
|
|
13661
13679
|
);
|
|
13662
13680
|
return 0;
|
|
13663
13681
|
}
|
|
13664
|
-
|
|
13682
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
13665
13683
|
{ dashboardUrl: dashboardUrl2, runUrl: runUrl2 },
|
|
13666
13684
|
{ json: args.includes("--json"), text: `${runUrl2}
|
|
13667
13685
|
` }
|
|
@@ -13686,7 +13704,7 @@ async function handleRunGet(args) {
|
|
|
13686
13704
|
"This server does not support recorded configuration reads."
|
|
13687
13705
|
);
|
|
13688
13706
|
}
|
|
13689
|
-
|
|
13707
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
13690
13708
|
{ runId, contract: _nullishCoalesce(status2.contract, () => ( null)) },
|
|
13691
13709
|
{ json: true, fields: selection.fields }
|
|
13692
13710
|
);
|
|
@@ -13699,7 +13717,7 @@ async function handleRunGet(args) {
|
|
|
13699
13717
|
timing,
|
|
13700
13718
|
() => client.getRunInput(runId)
|
|
13701
13719
|
);
|
|
13702
|
-
|
|
13720
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, input, { json: true });
|
|
13703
13721
|
return 0;
|
|
13704
13722
|
}
|
|
13705
13723
|
const full = args.includes("--full");
|
|
@@ -13714,7 +13732,7 @@ async function handleRunGet(args) {
|
|
|
13714
13732
|
failedLogs: args.includes("--log-failed")
|
|
13715
13733
|
})
|
|
13716
13734
|
);
|
|
13717
|
-
if (status.package)
|
|
13735
|
+
if (status.package) _chunkTNUM4DFAjs.recordPlayTermination.call(void 0, buildRunOverview(status).run);
|
|
13718
13736
|
if (!status.package) {
|
|
13719
13737
|
const legacyStatus = full ? await withRunReadTiming(
|
|
13720
13738
|
"runs get",
|
|
@@ -13728,8 +13746,8 @@ async function handleRunGet(args) {
|
|
|
13728
13746
|
const legacyPlayName = resolveRunPlayName(legacyStatus, runId);
|
|
13729
13747
|
const legacyDashboardUrl = legacyPlayName ? _chunkXYIECA7Mjs.buildPlayDashboardUrl.call(void 0, client.baseUrl, legacyPlayName) : null;
|
|
13730
13748
|
const legacyRunUrl = legacyPlayName ? _chunkXYIECA7Mjs.buildPlayRunUrl.call(void 0, client.baseUrl, legacyPlayName, runId) : null;
|
|
13731
|
-
if (
|
|
13732
|
-
|
|
13749
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
13750
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
13733
13751
|
{
|
|
13734
13752
|
...full ? legacyStatus : compactPlayStatus(legacyStatus),
|
|
13735
13753
|
...legacyDashboardUrl ? { dashboardUrl: legacyDashboardUrl } : {},
|
|
@@ -13740,7 +13758,7 @@ async function handleRunGet(args) {
|
|
|
13740
13758
|
} else {
|
|
13741
13759
|
writePlayResult(legacyStatus, false, { fullJson: full });
|
|
13742
13760
|
if (legacyRunUrl)
|
|
13743
|
-
|
|
13761
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
13744
13762
|
{ dashboardUrl: legacyDashboardUrl, runUrl: legacyRunUrl },
|
|
13745
13763
|
{ json: false, text: `run page: ${legacyRunUrl}
|
|
13746
13764
|
` }
|
|
@@ -13770,11 +13788,11 @@ async function handleRunGet(args) {
|
|
|
13770
13788
|
)
|
|
13771
13789
|
]);
|
|
13772
13790
|
const hitLines = formatRunHitsLines(hits);
|
|
13773
|
-
const json =
|
|
13791
|
+
const json = _chunkVAOGM5VSjs.argsWantJson.call(void 0, args);
|
|
13774
13792
|
const playName = resolveRunPlayName(status, runId);
|
|
13775
13793
|
const dashboardUrl = playName ? _chunkXYIECA7Mjs.buildPlayDashboardUrl.call(void 0, client.baseUrl, playName) : void 0;
|
|
13776
13794
|
const runUrl = playName ? _chunkXYIECA7Mjs.buildPlayRunUrl.call(void 0, client.baseUrl, playName, runId) : void 0;
|
|
13777
|
-
|
|
13795
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
13778
13796
|
{
|
|
13779
13797
|
...overview,
|
|
13780
13798
|
...dashboardUrl ? { dashboardUrl } : {},
|
|
@@ -13879,9 +13897,9 @@ async function handleRunLifecycleStatus(args) {
|
|
|
13879
13897
|
console.error(error instanceof Error ? error.message : usage2);
|
|
13880
13898
|
return 1;
|
|
13881
13899
|
}
|
|
13882
|
-
const status = await new (0,
|
|
13883
|
-
if (
|
|
13884
|
-
|
|
13900
|
+
const status = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().runs.status(runId);
|
|
13901
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
13902
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, status, { json: true });
|
|
13885
13903
|
return 0;
|
|
13886
13904
|
}
|
|
13887
13905
|
if (!status.available) {
|
|
@@ -13947,7 +13965,7 @@ async function handleRunsRerun(args) {
|
|
|
13947
13965
|
console.error(error instanceof Error ? error.message : usage2);
|
|
13948
13966
|
return 1;
|
|
13949
13967
|
}
|
|
13950
|
-
const options = { json:
|
|
13968
|
+
const options = { json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args) };
|
|
13951
13969
|
for (let index = 0; index < args.length; index += 1) {
|
|
13952
13970
|
if (args[index] === "--idempotency-key") {
|
|
13953
13971
|
options.idempotencyKey = _nullishCoalesce(args[++index], () => ( ""));
|
|
@@ -14013,8 +14031,8 @@ ${usage2}
|
|
|
14013
14031
|
Discover Plays: ${next.discover}
|
|
14014
14032
|
Active runs: ${next.running}`
|
|
14015
14033
|
);
|
|
14016
|
-
if (
|
|
14017
|
-
|
|
14034
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
14035
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14018
14036
|
{ ok: false, exitCode: 1, code: "RUN_FILTER_REQUIRED", message, next },
|
|
14019
14037
|
{ json: true }
|
|
14020
14038
|
);
|
|
@@ -14029,7 +14047,7 @@ Active runs: ${next.running}`
|
|
|
14029
14047
|
console.error("--offset requires --play.");
|
|
14030
14048
|
return 1;
|
|
14031
14049
|
}
|
|
14032
|
-
const client = new (0,
|
|
14050
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
14033
14051
|
const page = await withRunReadTiming(
|
|
14034
14052
|
"runs list",
|
|
14035
14053
|
"run inventory",
|
|
@@ -14064,7 +14082,7 @@ Active runs: ${next.running}`
|
|
|
14064
14082
|
executionTime: run.executionTime,
|
|
14065
14083
|
billingTotalCredits: run.billingTotalCredits,
|
|
14066
14084
|
billingMaxCreditsPerRun: run.billingMaxCreditsPerRun,
|
|
14067
|
-
playName: _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(run.playName, () => ( _optionalChain([run, 'access',
|
|
14085
|
+
playName: _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(run.playName, () => ( _optionalChain([run, 'access', _553 => _553.memo, 'optionalAccess', _554 => _554.playName]))), () => ( playName)), () => ( null)),
|
|
14068
14086
|
...nodeId ? { nodeObservation: _nullishCoalesce(run.nodeObservation, () => ( null)) } : {}
|
|
14069
14087
|
}));
|
|
14070
14088
|
const lines = runs.length === 0 ? [
|
|
@@ -14096,14 +14114,14 @@ Active runs: ${next.running}`
|
|
|
14096
14114
|
return lines2.join("\n");
|
|
14097
14115
|
});
|
|
14098
14116
|
const nextOffset = (_nullishCoalesce(_nullishCoalesce(page.offset, () => ( offset)), () => ( 0))) + runs.length;
|
|
14099
|
-
const nextPage = page.hasMore && playName ? `deepline runs list --play ${_chunkAID3OYVJjs.shellQuote.call(void 0, playName)}${nodeId ? ` --node ${_chunkAID3OYVJjs.shellQuote.call(void 0, nodeId)}` : ""}${statusFilter ? ` --status ${_chunkAID3OYVJjs.shellQuote.call(void 0, statusFilter)}` : ""} --limit ${_nullishCoalesce(_nullishCoalesce(page.limit, () => ( limit)), () => ( 20))} --offset ${nextOffset}${
|
|
14117
|
+
const nextPage = page.hasMore && playName ? `deepline runs list --play ${_chunkAID3OYVJjs.shellQuote.call(void 0, playName)}${nodeId ? ` --node ${_chunkAID3OYVJjs.shellQuote.call(void 0, nodeId)}` : ""}${statusFilter ? ` --status ${_chunkAID3OYVJjs.shellQuote.call(void 0, statusFilter)}` : ""} --limit ${_nullishCoalesce(_nullishCoalesce(page.limit, () => ( limit)), () => ( 20))} --offset ${nextOffset}${_chunkVAOGM5VSjs.argsWantJson.call(void 0, args) ? " --json" : ""}` : null;
|
|
14100
14118
|
if (page.hasMore) {
|
|
14101
14119
|
lines.push("List truncated \u2014 more runs match this filter.");
|
|
14102
14120
|
lines.push(
|
|
14103
14121
|
nextPage ? `Next page: ${nextPage}` : "Narrow with --play <play-name> to page through runs."
|
|
14104
14122
|
);
|
|
14105
14123
|
}
|
|
14106
|
-
|
|
14124
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14107
14125
|
{
|
|
14108
14126
|
runs,
|
|
14109
14127
|
count: runs.length,
|
|
@@ -14113,11 +14131,11 @@ Active runs: ${next.running}`
|
|
|
14113
14131
|
...page.hasMore !== void 0 ? { has_more: page.hasMore, is_truncated: page.hasMore } : {},
|
|
14114
14132
|
next: {
|
|
14115
14133
|
page: nextPage,
|
|
14116
|
-
get: _optionalChain([runs, 'access',
|
|
14134
|
+
get: _optionalChain([runs, 'access', _555 => _555[0], 'optionalAccess', _556 => _556.id]) ? `deepline runs get ${runs[0].id}` : null
|
|
14117
14135
|
},
|
|
14118
14136
|
render: { sections: [{ title: "runs", lines }] }
|
|
14119
14137
|
},
|
|
14120
|
-
{ json:
|
|
14138
|
+
{ json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args) }
|
|
14121
14139
|
);
|
|
14122
14140
|
return 0;
|
|
14123
14141
|
}
|
|
@@ -14147,7 +14165,7 @@ async function handleRunTail(args) {
|
|
|
14147
14165
|
console.error("--log-level requires one of: debug, info, warn, error.");
|
|
14148
14166
|
return 1;
|
|
14149
14167
|
}
|
|
14150
|
-
const parsed =
|
|
14168
|
+
const parsed = _chunkXIIQNSWAjs.parseLogLevel.call(void 0, value);
|
|
14151
14169
|
if (!parsed) {
|
|
14152
14170
|
console.error(
|
|
14153
14171
|
`Unsupported --log-level ${JSON.stringify(value)}. Use debug, info, warn, or error.`
|
|
@@ -14185,9 +14203,9 @@ async function handleRunTail(args) {
|
|
|
14185
14203
|
);
|
|
14186
14204
|
return 1;
|
|
14187
14205
|
}
|
|
14188
|
-
const client = new (0,
|
|
14206
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
14189
14207
|
const jsonLines = args.includes("--jsonl");
|
|
14190
|
-
const jsonOutput = !jsonLines &&
|
|
14208
|
+
const jsonOutput = !jsonLines && _chunkVAOGM5VSjs.argsWantJson.call(void 0, args);
|
|
14191
14209
|
const compact = args.includes("--compact");
|
|
14192
14210
|
const showLiveLogs = debug || hasExplicitLogLevel || !jsonOutput && !compact;
|
|
14193
14211
|
const compactState = {
|
|
@@ -14268,7 +14286,7 @@ async function handleRunLogs(args) {
|
|
|
14268
14286
|
]);
|
|
14269
14287
|
const cursorIndex = args.indexOf("--cursor");
|
|
14270
14288
|
const cursorValue = cursorIndex >= 0 ? args[cursorIndex + 1] : void 0;
|
|
14271
|
-
const continuesEventSearch = cursorIndex >= 0 && !(cursorValue &&
|
|
14289
|
+
const continuesEventSearch = cursorIndex >= 0 && !(cursorValue && _chunkXIIQNSWAjs.isRunLogsCursor.call(void 0, cursorValue));
|
|
14272
14290
|
if (!args[0] || args[0].startsWith("--") || continuesEventSearch || args.some((arg) => searchFlags.has(arg))) {
|
|
14273
14291
|
return handleRunEventSearch(args);
|
|
14274
14292
|
}
|
|
@@ -14302,7 +14320,7 @@ async function handleRunLogs(args) {
|
|
|
14302
14320
|
console.error("--log-level requires one of: debug, info, warn, error.");
|
|
14303
14321
|
return 1;
|
|
14304
14322
|
}
|
|
14305
|
-
const parsed =
|
|
14323
|
+
const parsed = _chunkXIIQNSWAjs.parseLogLevel.call(void 0, value);
|
|
14306
14324
|
if (!parsed) {
|
|
14307
14325
|
console.error(
|
|
14308
14326
|
`Unsupported --log-level ${JSON.stringify(value)}. Use debug, info, warn, or error.`
|
|
@@ -14349,12 +14367,12 @@ async function handleRunLogs(args) {
|
|
|
14349
14367
|
);
|
|
14350
14368
|
return 1;
|
|
14351
14369
|
}
|
|
14352
|
-
const client = new (0,
|
|
14370
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
14353
14371
|
if (outPath) {
|
|
14354
14372
|
const result2 = await client.runs.logs(runId, { all: true });
|
|
14355
|
-
const logs = result2.entries.filter((line) =>
|
|
14373
|
+
const logs = result2.entries.filter((line) => _chunkXIIQNSWAjs.logLevelReaches.call(void 0, _chunkXIIQNSWAjs.classifyLogLine.call(void 0, line).level, logLevel)).map((line) => _chunkXIIQNSWAjs.classifyLogLine.call(void 0, line).line);
|
|
14356
14374
|
_fs.writeFileSync.call(void 0, outPath, `${logs.join("\n")}${logs.length > 0 ? "\n" : ""}`);
|
|
14357
|
-
|
|
14375
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14358
14376
|
{
|
|
14359
14377
|
runId: result2.runId,
|
|
14360
14378
|
log_path: outPath,
|
|
@@ -14377,7 +14395,7 @@ async function handleRunLogs(args) {
|
|
|
14377
14395
|
]
|
|
14378
14396
|
}
|
|
14379
14397
|
},
|
|
14380
|
-
{ json:
|
|
14398
|
+
{ json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args) }
|
|
14381
14399
|
);
|
|
14382
14400
|
return 0;
|
|
14383
14401
|
}
|
|
@@ -14408,7 +14426,7 @@ async function handleRunLogs(args) {
|
|
|
14408
14426
|
}
|
|
14409
14427
|
};
|
|
14410
14428
|
const text = buildRunLogsText(filteredResult);
|
|
14411
|
-
|
|
14429
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14412
14430
|
{
|
|
14413
14431
|
runId: result.runId,
|
|
14414
14432
|
totalCount: result.totalCount,
|
|
@@ -14432,7 +14450,7 @@ async function handleRunLogs(args) {
|
|
|
14432
14450
|
render: { sections: [{ title: "run logs", lines: entries }] }
|
|
14433
14451
|
},
|
|
14434
14452
|
{
|
|
14435
|
-
json:
|
|
14453
|
+
json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args),
|
|
14436
14454
|
text
|
|
14437
14455
|
}
|
|
14438
14456
|
);
|
|
@@ -14456,17 +14474,17 @@ function selectRunLogTailPage(result, logLevel, limit) {
|
|
|
14456
14474
|
);
|
|
14457
14475
|
}
|
|
14458
14476
|
const matching = result.entries.map((line, index) => ({ line, seq: first + index })).filter(
|
|
14459
|
-
(entry) =>
|
|
14477
|
+
(entry) => _chunkXIIQNSWAjs.logLevelReaches.call(void 0, _chunkXIIQNSWAjs.classifyLogLine.call(void 0, entry.line).level, logLevel)
|
|
14460
14478
|
);
|
|
14461
14479
|
const selected = matching.slice(-limit);
|
|
14462
14480
|
const olderMatchesExist = matching.length > selected.length;
|
|
14463
14481
|
return {
|
|
14464
14482
|
entries: selected.map((entry) => entry.line),
|
|
14465
|
-
firstSequence: _nullishCoalesce(_optionalChain([selected, 'access',
|
|
14466
|
-
lastSequence: _nullishCoalesce(_optionalChain([selected, 'access',
|
|
14483
|
+
firstSequence: _nullishCoalesce(_optionalChain([selected, 'access', _557 => _557[0], 'optionalAccess', _558 => _558.seq]), () => ( null)),
|
|
14484
|
+
lastSequence: _nullishCoalesce(_optionalChain([selected, 'access', _559 => _559.at, 'call', _560 => _560(-1), 'optionalAccess', _561 => _561.seq]), () => ( null)),
|
|
14467
14485
|
truncated: result.truncated || olderMatchesExist,
|
|
14468
14486
|
hasMore: olderMatchesExist,
|
|
14469
|
-
nextCursor: olderMatchesExist ?
|
|
14487
|
+
nextCursor: olderMatchesExist ? _chunkXIIQNSWAjs.encodeRunLogsCursor.call(void 0, selected[0].seq) : null
|
|
14470
14488
|
};
|
|
14471
14489
|
}
|
|
14472
14490
|
async function handleRunEventSearch(args) {
|
|
@@ -14533,7 +14551,7 @@ ${usage2}`);
|
|
|
14533
14551
|
namespace,
|
|
14534
14552
|
...backend ? { backend } : {}
|
|
14535
14553
|
} : void 0;
|
|
14536
|
-
const client = new (0,
|
|
14554
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
14537
14555
|
const result = await client.runs.searchEvents({
|
|
14538
14556
|
...runId ? { runId } : {},
|
|
14539
14557
|
...values["--since"] ? { since: values["--since"] } : {},
|
|
@@ -14605,7 +14623,7 @@ ${renderedDetails}` : ""}`;
|
|
|
14605
14623
|
"--limit",
|
|
14606
14624
|
String(limit)
|
|
14607
14625
|
].join(" ") : null;
|
|
14608
|
-
|
|
14626
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14609
14627
|
{
|
|
14610
14628
|
events,
|
|
14611
14629
|
nextCursor: result.nextCursor,
|
|
@@ -14616,19 +14634,19 @@ ${renderedDetails}` : ""}`;
|
|
|
14616
14634
|
render: { sections: [{ title: "runtime events", lines }] }
|
|
14617
14635
|
},
|
|
14618
14636
|
{
|
|
14619
|
-
json:
|
|
14637
|
+
json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args),
|
|
14620
14638
|
text: `${lines.join("\n")}${lines.length ? "\n" : ""}`
|
|
14621
14639
|
}
|
|
14622
14640
|
);
|
|
14623
14641
|
return 0;
|
|
14624
14642
|
}
|
|
14625
14643
|
function buildRunLogsText(result) {
|
|
14626
|
-
const lines = result.entries.map((line) =>
|
|
14644
|
+
const lines = result.entries.map((line) => _chunkXIIQNSWAjs.classifyLogLine.call(void 0, line).line);
|
|
14627
14645
|
if (result.warning) {
|
|
14628
14646
|
if (lines.length > 0) lines.push("");
|
|
14629
14647
|
lines.push(`warning: ${result.warning}`);
|
|
14630
14648
|
lines.push(
|
|
14631
|
-
`retained logs: ${_nullishCoalesce(_optionalChain([result, 'access',
|
|
14649
|
+
`retained logs: ${_nullishCoalesce(_optionalChain([result, 'access', _562 => _562.next, 'optionalAccess', _563 => _563.logs]), () => ( `deepline runs logs ${result.runId} --out run.log`))}`
|
|
14632
14650
|
);
|
|
14633
14651
|
}
|
|
14634
14652
|
return `${lines.join("\n")}${lines.length > 0 ? "\n" : ""}`;
|
|
@@ -14657,7 +14675,7 @@ async function handleRunStop(args) {
|
|
|
14657
14675
|
reason = args[++index];
|
|
14658
14676
|
}
|
|
14659
14677
|
}
|
|
14660
|
-
const client = new (0,
|
|
14678
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
14661
14679
|
const result = await client.runs.stop(runId, { reason });
|
|
14662
14680
|
const state = resolveRunStopState(result);
|
|
14663
14681
|
const hitlCleanupIncomplete = state === "cancelling" && result.hitlCancellationPending === true;
|
|
@@ -14672,7 +14690,7 @@ async function handleRunStop(args) {
|
|
|
14672
14690
|
...result.hitlCancelledCount > 0 ? [`cancelled HITL waits: ${result.hitlCancelledCount}`] : [],
|
|
14673
14691
|
`inspect: deepline runs get ${runId} --full`
|
|
14674
14692
|
];
|
|
14675
|
-
|
|
14693
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14676
14694
|
{
|
|
14677
14695
|
...cancelling,
|
|
14678
14696
|
state,
|
|
@@ -14687,7 +14705,7 @@ async function handleRunStop(args) {
|
|
|
14687
14705
|
]
|
|
14688
14706
|
}
|
|
14689
14707
|
},
|
|
14690
|
-
{ json:
|
|
14708
|
+
{ json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args) }
|
|
14691
14709
|
);
|
|
14692
14710
|
return 0;
|
|
14693
14711
|
}
|
|
@@ -14704,7 +14722,7 @@ async function handleRunStop(args) {
|
|
|
14704
14722
|
];
|
|
14705
14723
|
process.stderr.write(`${lines2.join("\n")}
|
|
14706
14724
|
`);
|
|
14707
|
-
|
|
14725
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14708
14726
|
{
|
|
14709
14727
|
...result,
|
|
14710
14728
|
render: {
|
|
@@ -14719,7 +14737,7 @@ async function handleRunStop(args) {
|
|
|
14719
14737
|
]
|
|
14720
14738
|
}
|
|
14721
14739
|
},
|
|
14722
|
-
{ json:
|
|
14740
|
+
{ json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args) }
|
|
14723
14741
|
);
|
|
14724
14742
|
return 1;
|
|
14725
14743
|
}
|
|
@@ -14730,12 +14748,12 @@ async function handleRunStop(args) {
|
|
|
14730
14748
|
`warning: HITL cancellation or Slack card refresh is still pending; retry 'deepline runs stop ${runId}'`
|
|
14731
14749
|
] : []
|
|
14732
14750
|
];
|
|
14733
|
-
|
|
14751
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14734
14752
|
{
|
|
14735
14753
|
...result,
|
|
14736
14754
|
render: { sections: [{ title: "run stop", lines }] }
|
|
14737
14755
|
},
|
|
14738
|
-
{ json:
|
|
14756
|
+
{ json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args) }
|
|
14739
14757
|
);
|
|
14740
14758
|
return 0;
|
|
14741
14759
|
}
|
|
@@ -14785,18 +14803,18 @@ async function handleRunStopAll(args) {
|
|
|
14785
14803
|
reason = args[++index];
|
|
14786
14804
|
}
|
|
14787
14805
|
}
|
|
14788
|
-
const client = new (0,
|
|
14806
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
14789
14807
|
if (dryRun) {
|
|
14790
14808
|
const result2 = await client.runs.stopAll({ dryRun: true, reason });
|
|
14791
14809
|
const lines2 = buildStopAllDryRunTextLines(result2);
|
|
14792
|
-
|
|
14810
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14793
14811
|
{
|
|
14794
14812
|
...result2,
|
|
14795
14813
|
render: {
|
|
14796
14814
|
sections: [{ title: "workspace stop-all (dry run)", lines: lines2 }]
|
|
14797
14815
|
}
|
|
14798
14816
|
},
|
|
14799
|
-
{ json:
|
|
14817
|
+
{ json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args), text: `${lines2.join("\n")}
|
|
14800
14818
|
` }
|
|
14801
14819
|
);
|
|
14802
14820
|
return 0;
|
|
@@ -14809,17 +14827,17 @@ async function handleRunStopAll(args) {
|
|
|
14809
14827
|
...result.failed > 0 ? [`failed stops: ${result.failed}`] : [],
|
|
14810
14828
|
...result.skipped > 0 ? [`skipped: ${result.skipped}`] : []
|
|
14811
14829
|
];
|
|
14812
|
-
|
|
14830
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
14813
14831
|
{
|
|
14814
14832
|
...result,
|
|
14815
14833
|
render: { sections: [{ title: "workspace stop-all", lines }] }
|
|
14816
14834
|
},
|
|
14817
|
-
{ json:
|
|
14835
|
+
{ json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args) }
|
|
14818
14836
|
);
|
|
14819
14837
|
return result.failed > 0 || result.partial ? 1 : 0;
|
|
14820
14838
|
}
|
|
14821
14839
|
async function handleRunExport(args) {
|
|
14822
|
-
const selection =
|
|
14840
|
+
const selection = _chunkVAOGM5VSjs.parseJsonFields.call(void 0, args, "export");
|
|
14823
14841
|
args = selection.args;
|
|
14824
14842
|
const usage2 = "Usage: deepline runs export <run-id> [--dataset result.rows] --out <path> [--format csv|json] [--summary full|counts] [--wait] [--timeout-ms 300000] [--metadata-out export.json] [--allow-empty] [--json]";
|
|
14825
14843
|
let runId;
|
|
@@ -14890,17 +14908,17 @@ async function handleRunExport(args) {
|
|
|
14890
14908
|
"INVALID_ARGUMENT"
|
|
14891
14909
|
);
|
|
14892
14910
|
}
|
|
14893
|
-
const client = new (0,
|
|
14911
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
14894
14912
|
let status = await client.getPlayStatus(runId, { full: true });
|
|
14895
14913
|
assertRunExportStatusIdentity(status, runId);
|
|
14896
14914
|
if (wait && !TERMINAL_PLAY_STATUSES.has(status.status)) {
|
|
14897
|
-
const progress =
|
|
14915
|
+
const progress = _chunkAOYW62XOjs.createCliProgress.call(void 0, !_chunkVAOGM5VSjs.argsWantJson.call(void 0, args));
|
|
14898
14916
|
try {
|
|
14899
14917
|
await waitForPlayCompletionByWatch({
|
|
14900
14918
|
client,
|
|
14901
14919
|
playName: _nullishCoalesce(extractRunPlayName(status), () => ( runId)),
|
|
14902
14920
|
workflowId: runId,
|
|
14903
|
-
jsonOutput:
|
|
14921
|
+
jsonOutput: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args),
|
|
14904
14922
|
emitLogs: false,
|
|
14905
14923
|
waitTimeoutMs,
|
|
14906
14924
|
startedAt: Date.now(),
|
|
@@ -14926,26 +14944,26 @@ async function handleRunExport(args) {
|
|
|
14926
14944
|
format,
|
|
14927
14945
|
summary
|
|
14928
14946
|
});
|
|
14929
|
-
const source = _nullishCoalesce(_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
14930
|
-
const currentTableNotice = _optionalChain([exportResult, 'optionalAccess',
|
|
14947
|
+
const source = _nullishCoalesce(_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _564 => _564.rowsInfo, 'access', _565 => _565.source]), () => ( datasetPath)), () => ( null));
|
|
14948
|
+
const currentTableNotice = _optionalChain([exportResult, 'optionalAccess', _566 => _566.currentTable]) ? {
|
|
14931
14949
|
code: "CURRENT_SHARED_DATASET",
|
|
14932
14950
|
message: "This export is the current shared dataset and may include writes from another run.",
|
|
14933
14951
|
full_run_output_command: `deepline runs get ${status.runId} --full`
|
|
14934
14952
|
} : null;
|
|
14935
14953
|
const navigation = buildRunNavigation(status);
|
|
14936
|
-
const resolved = _optionalChain([exportResult, 'optionalAccess',
|
|
14954
|
+
const resolved = _optionalChain([exportResult, 'optionalAccess', _567 => _567.datasetInfo]);
|
|
14937
14955
|
const identity = navigation.datasets.find(
|
|
14938
|
-
(dataset) => _optionalChain([resolved, 'optionalAccess',
|
|
14956
|
+
(dataset) => _optionalChain([resolved, 'optionalAccess', _568 => _568.datasetId]) ? dataset.datasetId === resolved.datasetId : dataset.name === _optionalChain([resolved, 'optionalAccess', _569 => _569.tableNamespace])
|
|
14939
14957
|
);
|
|
14940
14958
|
const unambiguousName = identity && !identity.exportUnavailable && navigation.datasets.filter((dataset) => dataset.name === identity.name).length === 1 ? identity.name : void 0;
|
|
14941
14959
|
const exportCommand = runExportRetryCommand(
|
|
14942
14960
|
status.runId,
|
|
14943
14961
|
outPath,
|
|
14944
|
-
_nullishCoalesce(_nullishCoalesce(unambiguousName, () => ( datasetPath)), () => ( _optionalChain([exportResult, 'optionalAccess',
|
|
14962
|
+
_nullishCoalesce(_nullishCoalesce(unambiguousName, () => ( datasetPath)), () => ( _optionalChain([exportResult, 'optionalAccess', _570 => _570.datasetPath]))),
|
|
14945
14963
|
{ format, summary }
|
|
14946
14964
|
) + (args.includes("--allow-empty") ? " --allow-empty" : "");
|
|
14947
|
-
const fileLocation = format === "json" ? { json_path: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
14948
|
-
const exportedRowOutcomes = _optionalChain([exportResult, 'optionalAccess',
|
|
14965
|
+
const fileLocation = format === "json" ? { json_path: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _571 => _571.path]), () => ( null)) } : { csv_path: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _572 => _572.path]), () => ( null)) };
|
|
14966
|
+
const exportedRowOutcomes = _optionalChain([exportResult, 'optionalAccess', _573 => _573.rowsInfo, 'access', _574 => _574.exportedRowOutcomes]);
|
|
14949
14967
|
const rowFailures = exportedRowOutcomes && exportedRowOutcomes.failed > 0 ? {
|
|
14950
14968
|
count: exportedRowOutcomes.failed,
|
|
14951
14969
|
message: "Failed rows can retain values from stages that completed earlier; those values do not prove the row succeeded.",
|
|
@@ -14965,17 +14983,17 @@ async function handleRunExport(args) {
|
|
|
14965
14983
|
...fileLocation,
|
|
14966
14984
|
format,
|
|
14967
14985
|
source,
|
|
14968
|
-
rowCount: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
14986
|
+
rowCount: _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _575 => _575.rowsInfo, 'access', _576 => _576.totalRows]), () => ( null)),
|
|
14969
14987
|
...exportedRowOutcomes ? { rowOutcomes: exportedRowOutcomes } : {},
|
|
14970
14988
|
...rowFailures ? { rowFailures } : {},
|
|
14971
|
-
columns:
|
|
14989
|
+
columns: _chunkTNUM4DFAjs.underscoreKeysLast.call(void 0, _nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _577 => _577.rowsInfo, 'access', _578 => _578.columns]), () => ( []))),
|
|
14972
14990
|
...currentTableNotice ? { notice: currentTableNotice } : {},
|
|
14973
14991
|
...metadataOutPath ? { metadata_path: metadataOutPath } : {},
|
|
14974
14992
|
...!TERMINAL_PLAY_STATUSES.has(status.status) ? { completionCommand: `${exportCommand} --wait` } : {}
|
|
14975
14993
|
};
|
|
14976
14994
|
const lines = withRunNavigationLines(
|
|
14977
14995
|
[
|
|
14978
|
-
`Exported ${status.runId} to ${_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess',
|
|
14996
|
+
`Exported ${status.runId} to ${_nullishCoalesce(_optionalChain([exportResult, 'optionalAccess', _579 => _579.path]), () => ( outPath))}`,
|
|
14979
14997
|
...!TERMINAL_PLAY_STATUSES.has(status.status) ? [
|
|
14980
14998
|
`Partial export: run is ${status.status}; more rows may be saved.`,
|
|
14981
14999
|
`Export after completion: ${exportCommand} --wait`
|
|
@@ -15002,8 +15020,8 @@ async function handleRunExport(args) {
|
|
|
15002
15020
|
"utf-8"
|
|
15003
15021
|
);
|
|
15004
15022
|
}
|
|
15005
|
-
|
|
15006
|
-
json:
|
|
15023
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, payload, {
|
|
15024
|
+
json: _chunkVAOGM5VSjs.argsWantJson.call(void 0, args),
|
|
15007
15025
|
fields: selection.fields,
|
|
15008
15026
|
text: `${lines.join("\n")}
|
|
15009
15027
|
`
|
|
@@ -15037,10 +15055,10 @@ async function handlePlayGet(args) {
|
|
|
15037
15055
|
);
|
|
15038
15056
|
return 2;
|
|
15039
15057
|
}
|
|
15040
|
-
const client = new (0,
|
|
15058
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
15041
15059
|
const explicitJson = args.includes("--json");
|
|
15042
15060
|
const sourceOutput = args.includes("--source");
|
|
15043
|
-
const jsonOutput = sourceOutput ? explicitJson :
|
|
15061
|
+
const jsonOutput = sourceOutput ? explicitJson : _chunkVAOGM5VSjs.argsWantJson.call(void 0, args);
|
|
15044
15062
|
const requestedRevisionFlags = [
|
|
15045
15063
|
args.includes("--working"),
|
|
15046
15064
|
args.includes("--live"),
|
|
@@ -15093,7 +15111,7 @@ async function handlePlayGet(args) {
|
|
|
15093
15111
|
...includeSource ? { source: sourceSelector } : {}
|
|
15094
15112
|
});
|
|
15095
15113
|
const source = detail.source;
|
|
15096
|
-
const resolvedSource = _nullishCoalesce(_optionalChain([source, 'optionalAccess',
|
|
15114
|
+
const resolvedSource = _nullishCoalesce(_optionalChain([source, 'optionalAccess', _580 => _580.files, 'access', _581 => _581[source.entryFile]]), () => ( ""));
|
|
15097
15115
|
let materializedFile = null;
|
|
15098
15116
|
try {
|
|
15099
15117
|
materializedFile = outPath && source ? materializeRemotePlaySource({ target, playName, source, outPath }) : null;
|
|
@@ -15103,7 +15121,7 @@ async function handlePlayGet(args) {
|
|
|
15103
15121
|
}
|
|
15104
15122
|
const loadedMessage = materializedFile ? formatLoadedPlayMessage(materializedFile) : null;
|
|
15105
15123
|
if (jsonOutput) {
|
|
15106
|
-
|
|
15124
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, {
|
|
15107
15125
|
...detail,
|
|
15108
15126
|
...materializedFile ? {
|
|
15109
15127
|
message: loadedMessage,
|
|
@@ -15144,16 +15162,16 @@ async function handlePlayGet(args) {
|
|
|
15144
15162
|
}
|
|
15145
15163
|
console.log(`Play: ${formatPlayReference(detail.play)}`);
|
|
15146
15164
|
console.log(
|
|
15147
|
-
`Working version: ${_nullishCoalesce(_optionalChain([detail, 'access',
|
|
15165
|
+
`Working version: ${_nullishCoalesce(_optionalChain([detail, 'access', _582 => _582.play, 'access', _583 => _583.workingRevision, 'optionalAccess', _584 => _584.version]), () => ( "\u2014"))}`
|
|
15148
15166
|
);
|
|
15149
|
-
console.log(`Live version: ${_nullishCoalesce(_optionalChain([detail, 'access',
|
|
15167
|
+
console.log(`Live version: ${_nullishCoalesce(_optionalChain([detail, 'access', _585 => _585.play, 'access', _586 => _586.liveRevision, 'optionalAccess', _587 => _587.version]), () => ( "\u2014"))}`);
|
|
15150
15168
|
if (detail.play.liveRevision) {
|
|
15151
15169
|
console.log(
|
|
15152
15170
|
`Live max credits per run: ${liveMaxCreditsPerRun(detail.play.liveRevision.sourceCode)}`
|
|
15153
15171
|
);
|
|
15154
15172
|
}
|
|
15155
15173
|
console.log(`Draft dirty: ${detail.play.isDraftDirty ? "yes" : "no"}`);
|
|
15156
|
-
if (detail.play.isDraftDirty && _optionalChain([detail, 'access',
|
|
15174
|
+
if (detail.play.isDraftDirty && _optionalChain([detail, 'access', _588 => _588.play, 'access', _589 => _589.liveRevision, 'optionalAccess', _590 => _590.version])) {
|
|
15157
15175
|
console.log(
|
|
15158
15176
|
` Scheduled and named runs continue to use live v${detail.play.liveRevision.version}.`
|
|
15159
15177
|
);
|
|
@@ -15165,7 +15183,7 @@ async function handlePlayGet(args) {
|
|
|
15165
15183
|
console.log(line);
|
|
15166
15184
|
}
|
|
15167
15185
|
console.log(`Updated: ${formatTimestamp(detail.play.updatedAt)}`);
|
|
15168
|
-
console.log(`Sheet rows: ${_nullishCoalesce(_optionalChain([detail, 'access',
|
|
15186
|
+
console.log(`Sheet rows: ${_nullishCoalesce(_optionalChain([detail, 'access', _591 => _591.sheetSummary, 'optionalAccess', _592 => _592.stats, 'optionalAccess', _593 => _593.total]), () => ( 0))}`);
|
|
15169
15187
|
if (detail.customerDbUrl) {
|
|
15170
15188
|
console.log(`Customer DB: ${detail.customerDbUrl}`);
|
|
15171
15189
|
}
|
|
@@ -15181,7 +15199,7 @@ async function handlePlayGet(args) {
|
|
|
15181
15199
|
return 0;
|
|
15182
15200
|
}
|
|
15183
15201
|
function formatVersionLine(version) {
|
|
15184
|
-
const revisionLabel = _nullishCoalesce(_optionalChain([version, 'access',
|
|
15202
|
+
const revisionLabel = _nullishCoalesce(_optionalChain([version, 'access', _594 => _594.artifactHash, 'optionalAccess', _595 => _595.slice, 'call', _596 => _596(0, 12)]), () => ( "unknown-revision"));
|
|
15185
15203
|
const state = [
|
|
15186
15204
|
version.isLive ? "live" : null,
|
|
15187
15205
|
version.isWorking ? "working" : null
|
|
@@ -15195,8 +15213,8 @@ async function handlePlayVersions(args) {
|
|
|
15195
15213
|
console.error("Usage: deepline plays versions --name <name> [--json]");
|
|
15196
15214
|
return 1;
|
|
15197
15215
|
}
|
|
15198
|
-
const client = new (0,
|
|
15199
|
-
const jsonOutput =
|
|
15216
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
15217
|
+
const jsonOutput = _chunkVAOGM5VSjs.argsWantJson.call(void 0, args);
|
|
15200
15218
|
await assertCanonicalNamedPlayReference(client, playName, {
|
|
15201
15219
|
command: "versions"
|
|
15202
15220
|
});
|
|
@@ -15204,7 +15222,7 @@ async function handlePlayVersions(args) {
|
|
|
15204
15222
|
parseReferencedPlayTarget(playName).playName
|
|
15205
15223
|
);
|
|
15206
15224
|
if (jsonOutput) {
|
|
15207
|
-
|
|
15225
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, { versions });
|
|
15208
15226
|
return 0;
|
|
15209
15227
|
}
|
|
15210
15228
|
if (versions.length === 0) {
|
|
@@ -15243,8 +15261,8 @@ async function handlePlayCost(args) {
|
|
|
15243
15261
|
console.error("Usage: deepline plays cost <play> [--json]");
|
|
15244
15262
|
return 2;
|
|
15245
15263
|
}
|
|
15246
|
-
const result = await new (0,
|
|
15247
|
-
if (
|
|
15264
|
+
const result = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().getPlayCostEstimate(name);
|
|
15265
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) console.log(JSON.stringify(result, null, 2));
|
|
15248
15266
|
else
|
|
15249
15267
|
console.log(
|
|
15250
15268
|
`${result.reference}: ${formatPlayCostEstimate(result.costEstimate)}`
|
|
@@ -15252,11 +15270,11 @@ async function handlePlayCost(args) {
|
|
|
15252
15270
|
return 0;
|
|
15253
15271
|
}
|
|
15254
15272
|
async function handlePlayList(args) {
|
|
15255
|
-
const jsonOutput =
|
|
15273
|
+
const jsonOutput = _chunkVAOGM5VSjs.argsWantJson.call(void 0, args);
|
|
15256
15274
|
const showCost = args.includes("--show-cost");
|
|
15257
|
-
const client = new (0,
|
|
15275
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
15258
15276
|
const categoriesIndex = args.indexOf("--categories");
|
|
15259
|
-
const categories = categoriesIndex >= 0 ? _optionalChain([args, 'access',
|
|
15277
|
+
const categories = categoriesIndex >= 0 ? _optionalChain([args, 'access', _597 => _597[categoriesIndex + 1], 'optionalAccess', _598 => _598.trim, 'call', _599 => _599()]) : void 0;
|
|
15260
15278
|
const tags = args.flatMap((arg, index) => arg === "--tag" ? [args[index + 1]] : []).flatMap((value) => (_nullishCoalesce(value, () => ( ""))).split(",")).map((value) => value.trim()).filter(Boolean);
|
|
15261
15279
|
if (args.includes("--tag") && tags.length === 0) {
|
|
15262
15280
|
console.error(
|
|
@@ -15277,7 +15295,7 @@ async function handlePlayList(args) {
|
|
|
15277
15295
|
const cursorIndex = args.indexOf("--cursor");
|
|
15278
15296
|
const limit = limitIndex >= 0 ? Number(args[limitIndex + 1]) : void 0;
|
|
15279
15297
|
const cursor = cursorIndex >= 0 ? args[cursorIndex + 1] : void 0;
|
|
15280
|
-
if (limitIndex >= 0 && (!Number.isSafeInteger(limit) || limit < 1) || cursorIndex >= 0 && !_optionalChain([cursor, 'optionalAccess',
|
|
15298
|
+
if (limitIndex >= 0 && (!Number.isSafeInteger(limit) || limit < 1) || cursorIndex >= 0 && !_optionalChain([cursor, 'optionalAccess', _600 => _600.trim, 'call', _601 => _601()])) {
|
|
15281
15299
|
console.error("Pass a positive --limit and a non-empty --cursor.");
|
|
15282
15300
|
return 2;
|
|
15283
15301
|
}
|
|
@@ -15318,7 +15336,7 @@ async function handlePlayList(args) {
|
|
|
15318
15336
|
if (play.inputSchema || play.hasInputSchema) {
|
|
15319
15337
|
lines.push(" inputSchema: yes");
|
|
15320
15338
|
}
|
|
15321
|
-
if (_optionalChain([play, 'access',
|
|
15339
|
+
if (_optionalChain([play, 'access', _602 => _602.triggerStatus, 'optionalAccess', _603 => _603.cron])) {
|
|
15322
15340
|
lines.push(
|
|
15323
15341
|
` scheduled execution: ${cronExecutionLabel(play.triggerStatus.cron)}`
|
|
15324
15342
|
);
|
|
@@ -15338,12 +15356,12 @@ async function handlePlayList(args) {
|
|
|
15338
15356
|
} else {
|
|
15339
15357
|
lines.push(" scheduled execution: not configured");
|
|
15340
15358
|
}
|
|
15341
|
-
if (_optionalChain([play, 'access',
|
|
15359
|
+
if (_optionalChain([play, 'access', _604 => _604.triggerStatus, 'optionalAccess', _605 => _605.webhook])) {
|
|
15342
15360
|
lines.push(` webhook: ${play.triggerStatus.webhook}`);
|
|
15343
15361
|
}
|
|
15344
15362
|
if (showCost) {
|
|
15345
15363
|
lines.push(
|
|
15346
|
-
` cost estimate: ${_nullishCoalesce(_optionalChain([play, 'access',
|
|
15364
|
+
` cost estimate: ${_nullishCoalesce(_optionalChain([play, 'access', _606 => _606.observedCost, 'optionalAccess', _607 => _607.displayText]), () => ( formatPlayCostEstimate(play.costEstimate)))}`
|
|
15347
15365
|
);
|
|
15348
15366
|
}
|
|
15349
15367
|
lines.push(` run: deepline run ${reference}`);
|
|
@@ -15352,7 +15370,7 @@ async function handlePlayList(args) {
|
|
|
15352
15370
|
lines.push("List truncated \u2014 more plays are available.");
|
|
15353
15371
|
lines.push(`Next page: ${nextPage}`);
|
|
15354
15372
|
}
|
|
15355
|
-
|
|
15373
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
15356
15374
|
{
|
|
15357
15375
|
plays,
|
|
15358
15376
|
count: plays.length,
|
|
@@ -15369,8 +15387,8 @@ async function handlePlayList(args) {
|
|
|
15369
15387
|
return 0;
|
|
15370
15388
|
}
|
|
15371
15389
|
async function handlePlayPin(args, pinned) {
|
|
15372
|
-
const target = _optionalChain([args, 'access',
|
|
15373
|
-
const jsonOutput =
|
|
15390
|
+
const target = _optionalChain([args, 'access', _608 => _608.find, 'call', _609 => _609((arg) => !arg.startsWith("-")), 'optionalAccess', _610 => _610.trim, 'call', _611 => _611()]);
|
|
15391
|
+
const jsonOutput = _chunkVAOGM5VSjs.argsWantJson.call(void 0, args);
|
|
15374
15392
|
const dryRun = args.includes("--dry-run");
|
|
15375
15393
|
if (!target) {
|
|
15376
15394
|
console.error(
|
|
@@ -15388,11 +15406,11 @@ async function handlePlayPin(args, pinned) {
|
|
|
15388
15406
|
const name = parsedTarget.playName;
|
|
15389
15407
|
const plan = { name, pinned, dryRun };
|
|
15390
15408
|
if (dryRun) {
|
|
15391
|
-
|
|
15409
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, plan);
|
|
15392
15410
|
return 0;
|
|
15393
15411
|
}
|
|
15394
|
-
const result = await new (0,
|
|
15395
|
-
if (jsonOutput)
|
|
15412
|
+
const result = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().setPlayPinned(name, pinned);
|
|
15413
|
+
if (jsonOutput) _chunkVAOGM5VSjs.printCompactJson.call(void 0, result);
|
|
15396
15414
|
else console.log(`${result.pinned ? "Pinned" : "Unpinned"} ${result.name}.`);
|
|
15397
15415
|
return 0;
|
|
15398
15416
|
}
|
|
@@ -15440,7 +15458,7 @@ function printPlayDescription(play) {
|
|
|
15440
15458
|
console.log(` ${line}`);
|
|
15441
15459
|
}
|
|
15442
15460
|
}
|
|
15443
|
-
if (_optionalChain([play, 'access',
|
|
15461
|
+
if (_optionalChain([play, 'access', _612 => _612.toolCategories, 'optionalAccess', _613 => _613.length])) {
|
|
15444
15462
|
console.log(` Tool categories: ${play.toolCategories.join(", ")}`);
|
|
15445
15463
|
}
|
|
15446
15464
|
if (play.aliases.length > 0) {
|
|
@@ -15485,7 +15503,7 @@ function printPlayDescription(play) {
|
|
|
15485
15503
|
const runtimeLimit = formatPlayRuntimeLimit(play.runtimeLimit);
|
|
15486
15504
|
if (runtimeLimit) {
|
|
15487
15505
|
console.log(
|
|
15488
|
-
` Runtime limit: ${runtimeLimit} (${_nullishCoalesce(_optionalChain([play, 'access',
|
|
15506
|
+
` Runtime limit: ${runtimeLimit} (${_nullishCoalesce(_optionalChain([play, 'access', _614 => _614.runtimeLimit, 'optionalAccess', _615 => _615.source]), () => ( "live"))})`
|
|
15489
15507
|
);
|
|
15490
15508
|
}
|
|
15491
15509
|
printScheduledPlayCapacity(play.activeScheduledPlays);
|
|
@@ -15513,17 +15531,17 @@ function formatPlayGrepMatches(matches) {
|
|
|
15513
15531
|
return matches.map((match) => `${match.field}: ${match.terms.join(", ")}`).join("; ");
|
|
15514
15532
|
}
|
|
15515
15533
|
async function handlePlayGrep(args) {
|
|
15516
|
-
const query = _optionalChain([args, 'access',
|
|
15534
|
+
const query = _optionalChain([args, 'access', _616 => _616[0], 'optionalAccess', _617 => _617.trim, 'call', _618 => _618()]);
|
|
15517
15535
|
if (!query) {
|
|
15518
15536
|
console.error("Usage: deepline plays grep <query> [--json]");
|
|
15519
15537
|
return 1;
|
|
15520
15538
|
}
|
|
15521
|
-
const client = new (0,
|
|
15539
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
15522
15540
|
const results = (await client.listPlays({ grep: query })).map(
|
|
15523
15541
|
summarizePlayGrepResult
|
|
15524
15542
|
);
|
|
15525
|
-
if (
|
|
15526
|
-
|
|
15543
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
15544
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, {
|
|
15527
15545
|
plays: results,
|
|
15528
15546
|
count: results.length,
|
|
15529
15547
|
query,
|
|
@@ -15537,7 +15555,7 @@ async function handlePlayGrep(args) {
|
|
|
15537
15555
|
`
|
|
15538
15556
|
);
|
|
15539
15557
|
for (const result of results) {
|
|
15540
|
-
console.log(_optionalChain([result, 'access',
|
|
15558
|
+
console.log(_optionalChain([result, 'access', _619 => _619.displayName, 'optionalAccess', _620 => _620.trim, 'call', _621 => _621()]) || result.name);
|
|
15541
15559
|
const matches = formatPlayGrepMatches(result.matches);
|
|
15542
15560
|
if (matches) console.log(` Matched: ${matches}`);
|
|
15543
15561
|
console.log(` Describe: ${result.describe}`);
|
|
@@ -15546,7 +15564,7 @@ async function handlePlayGrep(args) {
|
|
|
15546
15564
|
return 0;
|
|
15547
15565
|
}
|
|
15548
15566
|
async function handlePlayDescribe(args) {
|
|
15549
|
-
const selection =
|
|
15567
|
+
const selection = _chunkVAOGM5VSjs.parseJsonFields.call(void 0, args, "describe");
|
|
15550
15568
|
args = selection.args;
|
|
15551
15569
|
const playName = args[0];
|
|
15552
15570
|
if (!playName) {
|
|
@@ -15580,8 +15598,8 @@ async function handlePlayDescribe(args) {
|
|
|
15580
15598
|
`deepline plays check ${playName}`,
|
|
15581
15599
|
...definedName ? [`deepline describe <workspace>/${definedName}`] : []
|
|
15582
15600
|
];
|
|
15583
|
-
if (
|
|
15584
|
-
|
|
15601
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
15602
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, {
|
|
15585
15603
|
ok: false,
|
|
15586
15604
|
error: { message },
|
|
15587
15605
|
next
|
|
@@ -15595,7 +15613,7 @@ async function handlePlayDescribe(args) {
|
|
|
15595
15613
|
}
|
|
15596
15614
|
return 2;
|
|
15597
15615
|
}
|
|
15598
|
-
const client = new (0,
|
|
15616
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
15599
15617
|
await assertCanonicalNamedPlayReference(client, playName, {
|
|
15600
15618
|
command: "describe"
|
|
15601
15619
|
});
|
|
@@ -15605,9 +15623,9 @@ async function handlePlayDescribe(args) {
|
|
|
15605
15623
|
compact: args.includes("--compact")
|
|
15606
15624
|
}
|
|
15607
15625
|
);
|
|
15608
|
-
if (
|
|
15609
|
-
if (selection.fields)
|
|
15610
|
-
else
|
|
15626
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
15627
|
+
if (selection.fields) _chunkVAOGM5VSjs.printJson.call(void 0, play, selection.fields);
|
|
15628
|
+
else _chunkVAOGM5VSjs.printCompactJson.call(void 0, play);
|
|
15611
15629
|
return 0;
|
|
15612
15630
|
}
|
|
15613
15631
|
printPlayDescription(play);
|
|
@@ -15628,7 +15646,7 @@ async function handlePlaySave(args) {
|
|
|
15628
15646
|
return 2;
|
|
15629
15647
|
}
|
|
15630
15648
|
const watchPlay = options.dryRun ? void 0 : options.watchPlay;
|
|
15631
|
-
const client = watchPlay ? new (0,
|
|
15649
|
+
const client = watchPlay ? new (0, _chunkUJYX4VLXjs.DeeplineClient)() : void 0;
|
|
15632
15650
|
let attempt;
|
|
15633
15651
|
if (watchPlay && client) {
|
|
15634
15652
|
try {
|
|
@@ -15652,7 +15670,7 @@ async function handlePlaySave(args) {
|
|
|
15652
15670
|
};
|
|
15653
15671
|
let graph;
|
|
15654
15672
|
try {
|
|
15655
|
-
graph = await
|
|
15673
|
+
graph = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
15656
15674
|
"cli.play_save_bundle_graph",
|
|
15657
15675
|
{ targetKind: "file" },
|
|
15658
15676
|
() => collectBundledPlayGraph(_path.resolve.call(void 0, options.target))
|
|
@@ -15681,7 +15699,7 @@ async function handlePlaySave(args) {
|
|
|
15681
15699
|
next: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, options.target)}`
|
|
15682
15700
|
};
|
|
15683
15701
|
if (options.jsonOutput) {
|
|
15684
|
-
|
|
15702
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result);
|
|
15685
15703
|
} else {
|
|
15686
15704
|
console.error(result.message);
|
|
15687
15705
|
console.error(` checked artifact: ${result.expectedArtifactHash}`);
|
|
@@ -15703,7 +15721,7 @@ async function handlePlaySave(args) {
|
|
|
15703
15721
|
};
|
|
15704
15722
|
if (options.dryRun) {
|
|
15705
15723
|
if (options.jsonOutput) {
|
|
15706
|
-
|
|
15724
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, dryRun);
|
|
15707
15725
|
} else {
|
|
15708
15726
|
console.log(`Dry run: ${playName}`);
|
|
15709
15727
|
console.log(` source: ${dryRun.sourceHash}`);
|
|
@@ -15712,14 +15730,14 @@ async function handlePlaySave(args) {
|
|
|
15712
15730
|
}
|
|
15713
15731
|
return 0;
|
|
15714
15732
|
}
|
|
15715
|
-
const saveClient = _nullishCoalesce(client, () => ( new (0,
|
|
15733
|
+
const saveClient = _nullishCoalesce(client, () => ( new (0, _chunkUJYX4VLXjs.DeeplineClient)()));
|
|
15716
15734
|
try {
|
|
15717
|
-
await
|
|
15735
|
+
await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
15718
15736
|
"cli.play_save_compile_manifests",
|
|
15719
15737
|
{ targetKind: "file", nodeCount: graph.nodes.size },
|
|
15720
15738
|
() => compileBundledPlayGraphManifests(saveClient, graph)
|
|
15721
15739
|
);
|
|
15722
|
-
const saved = await
|
|
15740
|
+
const saved = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
15723
15741
|
"cli.play_save_register_draft",
|
|
15724
15742
|
{ targetKind: "file", playName, artifactHash },
|
|
15725
15743
|
() => saveClient.registerPlayArtifact({
|
|
@@ -15749,7 +15767,7 @@ async function handlePlaySave(args) {
|
|
|
15749
15767
|
}
|
|
15750
15768
|
};
|
|
15751
15769
|
if (options.jsonOutput) {
|
|
15752
|
-
|
|
15770
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result);
|
|
15753
15771
|
} else {
|
|
15754
15772
|
console.log(
|
|
15755
15773
|
`\u2713 Saved ${playName} working draft as v${_nullishCoalesce(result.version, () => ( "?"))}`
|
|
@@ -15778,7 +15796,7 @@ async function handlePlayPublish(args) {
|
|
|
15778
15796
|
}
|
|
15779
15797
|
const { target: playName, useLatest } = options;
|
|
15780
15798
|
let revisionId = options.revisionId;
|
|
15781
|
-
const client = new (0,
|
|
15799
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
15782
15800
|
if (isFileTarget(playName)) {
|
|
15783
15801
|
if (revisionId || useLatest) {
|
|
15784
15802
|
console.error(
|
|
@@ -15788,7 +15806,7 @@ async function handlePlayPublish(args) {
|
|
|
15788
15806
|
}
|
|
15789
15807
|
let graph;
|
|
15790
15808
|
try {
|
|
15791
|
-
graph = await
|
|
15809
|
+
graph = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
15792
15810
|
"cli.play_publish_bundle_graph",
|
|
15793
15811
|
{ targetKind: "file" },
|
|
15794
15812
|
() => collectBundledPlayGraph(_path.resolve.call(void 0, playName))
|
|
@@ -15810,7 +15828,7 @@ async function handlePlayPublish(args) {
|
|
|
15810
15828
|
next: `deepline plays check ${_chunkAID3OYVJjs.shellQuote.call(void 0, playName)}`
|
|
15811
15829
|
};
|
|
15812
15830
|
if (options.jsonOutput) {
|
|
15813
|
-
|
|
15831
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result3);
|
|
15814
15832
|
} else {
|
|
15815
15833
|
console.error(result3.message);
|
|
15816
15834
|
console.error(` checked artifact: ${result3.expectedArtifactHash}`);
|
|
@@ -15833,7 +15851,7 @@ async function handlePlayPublish(args) {
|
|
|
15833
15851
|
};
|
|
15834
15852
|
if (options.dryRun) {
|
|
15835
15853
|
if (options.jsonOutput) {
|
|
15836
|
-
|
|
15854
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, dryRun);
|
|
15837
15855
|
} else {
|
|
15838
15856
|
console.log(`Dry run: ${rootPlayName}`);
|
|
15839
15857
|
console.log(` source: ${dryRun.sourceHash}`);
|
|
@@ -15852,12 +15870,12 @@ async function handlePlayPublish(args) {
|
|
|
15852
15870
|
}
|
|
15853
15871
|
}
|
|
15854
15872
|
try {
|
|
15855
|
-
await
|
|
15873
|
+
await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
15856
15874
|
"cli.play_publish_compile_manifests",
|
|
15857
15875
|
{ targetKind: "file", nodeCount: graph.nodes.size },
|
|
15858
15876
|
() => compileBundledPlayGraphManifests(client, graph)
|
|
15859
15877
|
);
|
|
15860
|
-
await
|
|
15878
|
+
await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
15861
15879
|
"cli.play_publish_imports",
|
|
15862
15880
|
{ targetKind: "file", nodeCount: graph.nodes.size },
|
|
15863
15881
|
() => publishImportedPlayDependencies(client, graph)
|
|
@@ -15866,7 +15884,7 @@ async function handlePlayPublish(args) {
|
|
|
15866
15884
|
console.error(error instanceof Error ? error.message : String(error));
|
|
15867
15885
|
return 1;
|
|
15868
15886
|
}
|
|
15869
|
-
const published = await
|
|
15887
|
+
const published = await _chunkH6IA6XREjs.traceCliSpan.call(void 0,
|
|
15870
15888
|
"cli.play_publish_register_root",
|
|
15871
15889
|
{
|
|
15872
15890
|
targetKind: "file",
|
|
@@ -15891,17 +15909,17 @@ async function handlePlayPublish(args) {
|
|
|
15891
15909
|
artifactHash,
|
|
15892
15910
|
liveVersion: _nullishCoalesce(published.version, () => ( null)),
|
|
15893
15911
|
revisionId: _nullishCoalesce(published.revisionId, () => ( null)),
|
|
15894
|
-
previousLiveVersion: _nullishCoalesce(_optionalChain([previousLive, 'optionalAccess',
|
|
15895
|
-
previousArtifactHash: _nullishCoalesce(_optionalChain([previousLive, 'optionalAccess',
|
|
15912
|
+
previousLiveVersion: _nullishCoalesce(_optionalChain([previousLive, 'optionalAccess', _622 => _622.version]), () => ( null)),
|
|
15913
|
+
previousArtifactHash: _nullishCoalesce(_optionalChain([previousLive, 'optionalAccess', _623 => _623.artifactHash]), () => ( null)),
|
|
15896
15914
|
sourceBytes: {
|
|
15897
|
-
before: _optionalChain([previousLive, 'optionalAccess',
|
|
15915
|
+
before: _optionalChain([previousLive, 'optionalAccess', _624 => _624.sourceCode]) ? Buffer.byteLength(previousLive.sourceCode, "utf8") : null,
|
|
15898
15916
|
after: Buffer.byteLength(graph.root.sourceCode, "utf8")
|
|
15899
15917
|
},
|
|
15900
15918
|
triggerMetadata: _nullishCoalesce(published.triggerMetadata, () => ( null)),
|
|
15901
15919
|
triggerBindings: _nullishCoalesce(published.triggerBindings, () => ( []))
|
|
15902
15920
|
};
|
|
15903
15921
|
if (options.jsonOutput) {
|
|
15904
|
-
|
|
15922
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result2);
|
|
15905
15923
|
} else {
|
|
15906
15924
|
printPublishReceipt({
|
|
15907
15925
|
name: rootPlayName,
|
|
@@ -15932,14 +15950,14 @@ async function handlePlayPublish(args) {
|
|
|
15932
15950
|
revisionId: _nullishCoalesce(revisionId, () => ( null)),
|
|
15933
15951
|
latest: useLatest
|
|
15934
15952
|
};
|
|
15935
|
-
|
|
15953
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result2);
|
|
15936
15954
|
return 0;
|
|
15937
15955
|
}
|
|
15938
15956
|
const resolvedName = parseReferencedPlayTarget(playName).playName;
|
|
15939
15957
|
if (useLatest) {
|
|
15940
15958
|
const versions = await client.listPlayVersions(resolvedName);
|
|
15941
15959
|
const latest = versions[0];
|
|
15942
|
-
if (!_optionalChain([latest, 'optionalAccess',
|
|
15960
|
+
if (!_optionalChain([latest, 'optionalAccess', _625 => _625._id])) {
|
|
15943
15961
|
console.error(`No saved revisions found for ${resolvedName}.`);
|
|
15944
15962
|
return 1;
|
|
15945
15963
|
}
|
|
@@ -15956,7 +15974,7 @@ async function handlePlayPublish(args) {
|
|
|
15956
15974
|
revisionId ? { revisionId } : {}
|
|
15957
15975
|
);
|
|
15958
15976
|
if (options.jsonOutput) {
|
|
15959
|
-
|
|
15977
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result);
|
|
15960
15978
|
} else {
|
|
15961
15979
|
printPublishReceipt({
|
|
15962
15980
|
name: result.name,
|
|
@@ -15996,7 +16014,7 @@ async function handlePlayDelete(args) {
|
|
|
15996
16014
|
);
|
|
15997
16015
|
return 2;
|
|
15998
16016
|
}
|
|
15999
|
-
const client = new (0,
|
|
16017
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
16000
16018
|
let detail;
|
|
16001
16019
|
try {
|
|
16002
16020
|
detail = await client.getPlay(parseReferencedPlayTarget(playName).playName);
|
|
@@ -16020,8 +16038,8 @@ async function handlePlayDelete(args) {
|
|
|
16020
16038
|
name: resolvedName,
|
|
16021
16039
|
plannedMutation: "move saved org-owned play to Trash and stop triggers"
|
|
16022
16040
|
};
|
|
16023
|
-
if (
|
|
16024
|
-
|
|
16041
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
16042
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result2);
|
|
16025
16043
|
} else {
|
|
16026
16044
|
process.stdout.write(
|
|
16027
16045
|
`Dry run: would move ${result2.name} to Trash and stop its active triggers.
|
|
@@ -16031,8 +16049,8 @@ async function handlePlayDelete(args) {
|
|
|
16031
16049
|
return 0;
|
|
16032
16050
|
}
|
|
16033
16051
|
const result = await client.deletePlay(resolvedName);
|
|
16034
|
-
if (
|
|
16035
|
-
|
|
16052
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
16053
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result);
|
|
16036
16054
|
return result.archived || result.alreadyArchived ? 0 : 4;
|
|
16037
16055
|
}
|
|
16038
16056
|
if (result.alreadyArchived) {
|
|
@@ -16071,13 +16089,13 @@ async function handlePlayRestore(args) {
|
|
|
16071
16089
|
);
|
|
16072
16090
|
return 2;
|
|
16073
16091
|
}
|
|
16074
|
-
const client = new (0,
|
|
16092
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
16075
16093
|
try {
|
|
16076
16094
|
const result = await client.restorePlay(
|
|
16077
16095
|
parseReferencedPlayTarget(playName).playName
|
|
16078
16096
|
);
|
|
16079
|
-
if (
|
|
16080
|
-
|
|
16097
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
16098
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, result);
|
|
16081
16099
|
return result.restored || result.alreadyActive ? 0 : 4;
|
|
16082
16100
|
}
|
|
16083
16101
|
if (result.alreadyActive) {
|
|
@@ -16204,21 +16222,21 @@ Common commands:
|
|
|
16204
16222
|
resume: `deepline plays resume-submission ${_chunkAID3OYVJjs.shellQuote.call(void 0, path)} --json`
|
|
16205
16223
|
}
|
|
16206
16224
|
};
|
|
16207
|
-
|
|
16225
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0, result2, {
|
|
16208
16226
|
json: options.json,
|
|
16209
16227
|
text: `Submission ${saved.workflowId}: admission is unknown. ${result2.next.inspect}
|
|
16210
16228
|
`
|
|
16211
16229
|
});
|
|
16212
16230
|
return;
|
|
16213
16231
|
}
|
|
16214
|
-
const client = new (0,
|
|
16232
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
16215
16233
|
if (new URL(saved.baseUrl).origin !== new URL(client.baseUrl).origin) {
|
|
16216
16234
|
throw new Error(
|
|
16217
16235
|
"The submission belongs to a different API origin. Select its original host before recovery."
|
|
16218
16236
|
);
|
|
16219
16237
|
}
|
|
16220
16238
|
const result = await client.startPlayRun(saved.request);
|
|
16221
|
-
|
|
16239
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
16222
16240
|
{ ...result },
|
|
16223
16241
|
{
|
|
16224
16242
|
json: options.json,
|
|
@@ -16254,7 +16272,7 @@ Examples:
|
|
|
16254
16272
|
).action(async (target, options) => {
|
|
16255
16273
|
process.exitCode = await handlePlayCheck([
|
|
16256
16274
|
target,
|
|
16257
|
-
...
|
|
16275
|
+
..._chunkVAOGM5VSjs.jsonFieldArgs.call(void 0, options.json),
|
|
16258
16276
|
...options.full ? ["--full"] : []
|
|
16259
16277
|
]);
|
|
16260
16278
|
});
|
|
@@ -16301,10 +16319,10 @@ Notes:
|
|
|
16301
16319
|
with a changed input is refused with a 409 conflict. Use one stable key per
|
|
16302
16320
|
exact intent. Without a key, each invocation starts a new run.
|
|
16303
16321
|
--max-concurrent-external-calls controls the per-run provider-tool/deepline.fetch
|
|
16304
|
-
resident-work ceiling. Default: ${
|
|
16322
|
+
resident-work ceiling. Default: ${_chunkXL3CEPZAjs.DEFAULT_MAX_CONCURRENT_EXTERNAL_CALLS}; accepted range: 1-${_chunkXL3CEPZAjs.MAX_CONFIGURABLE_CONCURRENT_EXTERNAL_CALLS}.
|
|
16305
16323
|
Provider pacing and sandbox memory limits still apply.
|
|
16306
16324
|
--max-concurrent-rows sets the run-wide default and ceiling for live map row
|
|
16307
|
-
resolvers. Accepted range: 1-${
|
|
16325
|
+
resolvers. Accepted range: 1-${_chunkXL3CEPZAjs.MAX_CONFIGURABLE_CONCURRENT_ROWS}. The runtime
|
|
16308
16326
|
may lower it when source-row size exceeds the active-row memory budget.
|
|
16309
16327
|
--max-credits replaces the play's billing.maxCreditsPerRun for this run.
|
|
16310
16328
|
Tool calls that would exceed it are denied.
|
|
@@ -16429,10 +16447,10 @@ Examples:
|
|
|
16429
16447
|
).hideHelp()
|
|
16430
16448
|
).option(
|
|
16431
16449
|
"--max-concurrent-external-calls <count>",
|
|
16432
|
-
`Concurrent provider-tool and deepline.fetch executions (${
|
|
16450
|
+
`Concurrent provider-tool and deepline.fetch executions (${_chunkXL3CEPZAjs.DEFAULT_MAX_CONCURRENT_EXTERNAL_CALLS} default, max ${_chunkXL3CEPZAjs.MAX_CONFIGURABLE_CONCURRENT_EXTERNAL_CALLS})`
|
|
16433
16451
|
).option(
|
|
16434
16452
|
"--max-concurrent-rows <count>",
|
|
16435
|
-
`Run-wide dataset map row resolver ceiling (max ${
|
|
16453
|
+
`Run-wide dataset map row resolver ceiling (max ${_chunkXL3CEPZAjs.MAX_CONFIGURABLE_CONCURRENT_ROWS})`
|
|
16436
16454
|
).option("--max-credits <credits>", "Deepline-credit cap for this run").option("--open", "Open the run page in a browser after the run starts").option(
|
|
16437
16455
|
"--debug-map-latency",
|
|
16438
16456
|
"Internal diagnostics: emit one aggregate latency profile per dataset map"
|
|
@@ -16483,7 +16501,7 @@ JSON field selection:
|
|
|
16483
16501
|
}
|
|
16484
16502
|
}
|
|
16485
16503
|
async function runPlayFromRun(target, options, command) {
|
|
16486
|
-
const runId = _optionalChain([options, 'access',
|
|
16504
|
+
const runId = _optionalChain([options, 'access', _626 => _626.fromRun, 'optionalAccess', _627 => _627.trim, 'call', _628 => _628()]);
|
|
16487
16505
|
if (!runId || runId.startsWith("--")) {
|
|
16488
16506
|
console.error("--from-run requires a run id.");
|
|
16489
16507
|
return 1;
|
|
@@ -16527,14 +16545,14 @@ JSON field selection:
|
|
|
16527
16545
|
passthroughArgs.shift();
|
|
16528
16546
|
}
|
|
16529
16547
|
const exitCode = await handlePlayRun(
|
|
16530
|
-
|
|
16548
|
+
_chunkXL3CEPZAjs.resolvePlayRunCliOptions.call(void 0,
|
|
16531
16549
|
_nullishCoalesce(effectiveTarget, () => ( void 0)),
|
|
16532
16550
|
options,
|
|
16533
16551
|
passthroughArgs,
|
|
16534
|
-
|
|
16552
|
+
_chunkH6IA6XREjs.resolveCliMaintenancePolicy.call(void 0, command.optsWithGlobals())
|
|
16535
16553
|
)
|
|
16536
16554
|
);
|
|
16537
|
-
|
|
16555
|
+
_chunkH6IA6XREjs.recordCliTrace.call(void 0, {
|
|
16538
16556
|
phase: "cli.play_command_exit",
|
|
16539
16557
|
exitCode
|
|
16540
16558
|
});
|
|
@@ -16583,9 +16601,9 @@ Examples:
|
|
|
16583
16601
|
const limit = Number(options.historyLimit);
|
|
16584
16602
|
if (!Number.isInteger(limit) || limit < 1 || limit > 30)
|
|
16585
16603
|
throw new Error("--history-limit must be an integer from 1 to 30.");
|
|
16586
|
-
const client = new (0,
|
|
16604
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
16587
16605
|
if (options.binding) {
|
|
16588
|
-
|
|
16606
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0,
|
|
16589
16607
|
await client.getPlayTriggerHistory(options.binding, { limit })
|
|
16590
16608
|
);
|
|
16591
16609
|
return;
|
|
@@ -16593,7 +16611,7 @@ Examples:
|
|
|
16593
16611
|
const result = await client.listPlayTriggerInventory({
|
|
16594
16612
|
cursor: options.cursor
|
|
16595
16613
|
});
|
|
16596
|
-
|
|
16614
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, {
|
|
16597
16615
|
...result,
|
|
16598
16616
|
next: result.isDone ? null : `deepline plays triggers --cursor ${JSON.stringify(result.continueCursor)}`
|
|
16599
16617
|
});
|
|
@@ -16652,7 +16670,7 @@ Examples:
|
|
|
16652
16670
|
if (options.groupBy !== "kind" && options.groupBy !== "trigger_source") {
|
|
16653
16671
|
throw new Error("--group-by must be kind or trigger_source.");
|
|
16654
16672
|
}
|
|
16655
|
-
const result = await new (0,
|
|
16673
|
+
const result = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().getPlaysActivity({
|
|
16656
16674
|
timeZone: options.timeZone,
|
|
16657
16675
|
days,
|
|
16658
16676
|
...options.endDate ? { endDate: options.endDate } : {},
|
|
@@ -16666,7 +16684,7 @@ Examples:
|
|
|
16666
16684
|
`${bucket.key} ${groups} failed_play_runs=${bucket.failedPlayRuns} ${coverage}`
|
|
16667
16685
|
);
|
|
16668
16686
|
}
|
|
16669
|
-
|
|
16687
|
+
_chunkVAOGM5VSjs.printCommandEnvelope.call(void 0,
|
|
16670
16688
|
{ ...result },
|
|
16671
16689
|
{
|
|
16672
16690
|
json: Boolean(options.json),
|
|
@@ -16695,7 +16713,7 @@ Examples:
|
|
|
16695
16713
|
false
|
|
16696
16714
|
);
|
|
16697
16715
|
});
|
|
16698
|
-
|
|
16716
|
+
_chunkN6DMKVKOjs.registerDeprecatedSearchCommand.call(void 0,
|
|
16699
16717
|
play,
|
|
16700
16718
|
(options) => options.all ? ["prebuilts", "custom"] : ["prebuilts"]
|
|
16701
16719
|
);
|
|
@@ -16736,9 +16754,9 @@ Examples:
|
|
|
16736
16754
|
"--json [fields]",
|
|
16737
16755
|
"JSON output; optionally select comma-separated dotted paths"
|
|
16738
16756
|
);
|
|
16739
|
-
|
|
16757
|
+
_chunkTNUM4DFAjs.addDescribeOptions.call(void 0, describeCommand, { json: false }).action(
|
|
16740
16758
|
async (target, options) => {
|
|
16741
|
-
const ownView = () => handlePlayDescribe(
|
|
16759
|
+
const ownView = () => handlePlayDescribe(_chunkVAOGM5VSjs.describeArgs.call(void 0, target, options));
|
|
16742
16760
|
const [flagText] = [options.json].filter(
|
|
16743
16761
|
(value) => typeof value === "string"
|
|
16744
16762
|
);
|
|
@@ -16749,7 +16767,7 @@ Examples:
|
|
|
16749
16767
|
process.exitCode = await ownView();
|
|
16750
16768
|
return;
|
|
16751
16769
|
}
|
|
16752
|
-
const { describeAnything } = await Promise.resolve().then(() => _interopRequireWildcard(require("./describe-
|
|
16770
|
+
const { describeAnything } = await Promise.resolve().then(() => _interopRequireWildcard(require("./describe-LWZCGAXU.js")));
|
|
16753
16771
|
process.exitCode = await describeAnything(
|
|
16754
16772
|
name,
|
|
16755
16773
|
{
|
|
@@ -16872,7 +16890,7 @@ Examples:
|
|
|
16872
16890
|
deepline plays deployments <deployment-id>
|
|
16873
16891
|
`
|
|
16874
16892
|
).option("--limit <n>", "Max rows (default 50)").option("--json", "Emit JSON output").action(
|
|
16875
|
-
async (id, options) => id ?
|
|
16893
|
+
async (id, options) => id ? _chunkJ3TAEPFAjs.handleDeploymentGet.call(void 0, id, options) : _chunkJ3TAEPFAjs.handleDeploymentsList.call(void 0, options)
|
|
16876
16894
|
);
|
|
16877
16895
|
addPublishHelp(
|
|
16878
16896
|
play.command("publish <target>").description(
|
|
@@ -17007,14 +17025,14 @@ Examples:
|
|
|
17007
17025
|
const limit = Number(options.limit);
|
|
17008
17026
|
if (!Number.isSafeInteger(limit) || limit < 1 || limit > 1e3)
|
|
17009
17027
|
throw new Error("--limit must be an integer from 1 to 1000.");
|
|
17010
|
-
const result = await new (0,
|
|
17028
|
+
const result = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().runs.rowHistory({
|
|
17011
17029
|
playName: options.play,
|
|
17012
17030
|
runId,
|
|
17013
17031
|
tableNamespace: options.dataset,
|
|
17014
17032
|
limit,
|
|
17015
17033
|
cursor: options.cursor
|
|
17016
17034
|
});
|
|
17017
|
-
|
|
17035
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, {
|
|
17018
17036
|
...result,
|
|
17019
17037
|
...result.nextCursor ? {
|
|
17020
17038
|
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`
|
|
@@ -17092,7 +17110,7 @@ Examples:
|
|
|
17092
17110
|
new (0, _commander.Option)("--log-failed", "Attach terminal-failure logs").hideHelp()
|
|
17093
17111
|
).action(async (runId, options) => {
|
|
17094
17112
|
if (TOOL_EXECUTION_ID.test(runId)) {
|
|
17095
|
-
const { getToolExecutionReceipt } = await Promise.resolve().then(() => _interopRequireWildcard(require("./tools-
|
|
17113
|
+
const { getToolExecutionReceipt } = await Promise.resolve().then(() => _interopRequireWildcard(require("./tools-XLVDZTWQ.js")));
|
|
17096
17114
|
process.exitCode = await getToolExecutionReceipt(runId, {
|
|
17097
17115
|
receiptJson: options.json !== void 0
|
|
17098
17116
|
});
|
|
@@ -17100,7 +17118,7 @@ Examples:
|
|
|
17100
17118
|
}
|
|
17101
17119
|
process.exitCode = await handleRunGet([
|
|
17102
17120
|
runId,
|
|
17103
|
-
...
|
|
17121
|
+
..._chunkVAOGM5VSjs.jsonFieldArgs.call(void 0, options.json),
|
|
17104
17122
|
...options.web ? ["--web"] : [],
|
|
17105
17123
|
...options.webUrl ? ["--web-url"] : [],
|
|
17106
17124
|
...options.full ? ["--full"] : [],
|
|
@@ -17422,7 +17440,7 @@ Examples:
|
|
|
17422
17440
|
...options.allowEmpty ? ["--allow-empty"] : [],
|
|
17423
17441
|
...options.wait ? ["--wait"] : [],
|
|
17424
17442
|
...options.timeoutMs ? ["--timeout-ms", options.timeoutMs] : [],
|
|
17425
|
-
...
|
|
17443
|
+
..._chunkVAOGM5VSjs.jsonFieldArgs.call(void 0, options.json)
|
|
17426
17444
|
]);
|
|
17427
17445
|
});
|
|
17428
17446
|
const share = play.command("share").description(
|
|
@@ -17563,8 +17581,8 @@ function absolutePublicPlayUrl(path) {
|
|
|
17563
17581
|
}
|
|
17564
17582
|
function shareUrlFields(status) {
|
|
17565
17583
|
return {
|
|
17566
|
-
publicUrl: absolutePublicPlayUrl(_optionalChain([status, 'access',
|
|
17567
|
-
canonicalUrl: absolutePublicPlayUrl(_optionalChain([status, 'access',
|
|
17584
|
+
publicUrl: absolutePublicPlayUrl(_optionalChain([status, 'access', _629 => _629.share, 'optionalAccess', _630 => _630.publicPath])),
|
|
17585
|
+
canonicalUrl: absolutePublicPlayUrl(_optionalChain([status, 'access', _631 => _631.share, 'optionalAccess', _632 => _632.canonicalPath]))
|
|
17568
17586
|
};
|
|
17569
17587
|
}
|
|
17570
17588
|
function shareStatusForOutput(status) {
|
|
@@ -17588,10 +17606,10 @@ async function handlePlayShareStatus(args) {
|
|
|
17588
17606
|
return 2;
|
|
17589
17607
|
}
|
|
17590
17608
|
const name = parseReferencedPlayTarget(target).playName;
|
|
17591
|
-
const status = await new (0,
|
|
17609
|
+
const status = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().getSharePage(name);
|
|
17592
17610
|
const outputStatus = shareStatusForOutput(status);
|
|
17593
|
-
if (
|
|
17594
|
-
|
|
17611
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
17612
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, outputStatus);
|
|
17595
17613
|
return 0;
|
|
17596
17614
|
}
|
|
17597
17615
|
if (!outputStatus.share) {
|
|
@@ -17630,7 +17648,7 @@ async function handlePlaySharePublish(args) {
|
|
|
17630
17648
|
return 2;
|
|
17631
17649
|
}
|
|
17632
17650
|
const name = parseReferencedPlayTarget(target).playName;
|
|
17633
|
-
const client = new (0,
|
|
17651
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
17634
17652
|
let revisionId = shareFlagValue(args, "--revision-id");
|
|
17635
17653
|
let resolvedVersion;
|
|
17636
17654
|
if (!revisionId) {
|
|
@@ -17661,8 +17679,8 @@ async function handlePlaySharePublish(args) {
|
|
|
17661
17679
|
);
|
|
17662
17680
|
if (!hasCompleted) {
|
|
17663
17681
|
const message = `No completed run for ${name}. Publish a play only after it has run successfully. (Override with --no-run-check.)`;
|
|
17664
|
-
if (
|
|
17665
|
-
|
|
17682
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
17683
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, {
|
|
17666
17684
|
ok: false,
|
|
17667
17685
|
code: "NO_SUCCESSFUL_RUN",
|
|
17668
17686
|
message,
|
|
@@ -17686,8 +17704,8 @@ async function handlePlaySharePublish(args) {
|
|
|
17686
17704
|
};
|
|
17687
17705
|
if (args.includes("--dry-run")) {
|
|
17688
17706
|
const plan = { dryRun: true, name, version: resolvedVersion, ...request };
|
|
17689
|
-
if (
|
|
17690
|
-
|
|
17707
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
17708
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, plan);
|
|
17691
17709
|
} else {
|
|
17692
17710
|
console.log(
|
|
17693
17711
|
`Would publish ${name}${resolvedVersion ? ` v${resolvedVersion}` : ""} (revision ${revisionId}).`
|
|
@@ -17697,13 +17715,13 @@ async function handlePlaySharePublish(args) {
|
|
|
17697
17715
|
}
|
|
17698
17716
|
const status = await client.publishSharePage(name, request);
|
|
17699
17717
|
const outputStatus = shareStatusForOutput(status);
|
|
17700
|
-
if (
|
|
17701
|
-
|
|
17718
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
17719
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, outputStatus);
|
|
17702
17720
|
return 0;
|
|
17703
17721
|
}
|
|
17704
17722
|
const urls = shareUrlFields(outputStatus);
|
|
17705
17723
|
console.log(
|
|
17706
|
-
`Published ${name}${outputStatus.share ? ` v${outputStatus.share.publishedVersion}` : ""}: ${_nullishCoalesce(_nullishCoalesce(urls.publicUrl, () => ( _optionalChain([outputStatus, 'access',
|
|
17724
|
+
`Published ${name}${outputStatus.share ? ` v${outputStatus.share.publishedVersion}` : ""}: ${_nullishCoalesce(_nullishCoalesce(urls.publicUrl, () => ( _optionalChain([outputStatus, 'access', _633 => _633.share, 'optionalAccess', _634 => _634.publicPath]))), () => ( ""))}`
|
|
17707
17725
|
);
|
|
17708
17726
|
if (urls.canonicalUrl && urls.canonicalUrl !== urls.publicUrl) {
|
|
17709
17727
|
console.log(`Version URL: ${urls.canonicalUrl}`);
|
|
@@ -17729,9 +17747,9 @@ async function handlePlayShareUpdate(args) {
|
|
|
17729
17747
|
...args.includes("--show-latency") ? { showAverageLatency: true } : args.includes("--hide-latency") ? { showAverageLatency: false } : {},
|
|
17730
17748
|
...seoIndexing ? { seoIndexing } : {}
|
|
17731
17749
|
};
|
|
17732
|
-
const status = await new (0,
|
|
17733
|
-
if (
|
|
17734
|
-
|
|
17750
|
+
const status = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().updateSharePage(name, request);
|
|
17751
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
17752
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, status);
|
|
17735
17753
|
return 0;
|
|
17736
17754
|
}
|
|
17737
17755
|
console.log(`Updated ${name} share settings.`);
|
|
@@ -17746,13 +17764,13 @@ async function handlePlayShareRegenerate(args) {
|
|
|
17746
17764
|
return 2;
|
|
17747
17765
|
}
|
|
17748
17766
|
const name = parseReferencedPlayTarget(target).playName;
|
|
17749
|
-
const client = new (0,
|
|
17767
|
+
const client = new (0, _chunkUJYX4VLXjs.DeeplineClient)();
|
|
17750
17768
|
let revisionId = shareFlagValue(args, "--revision-id");
|
|
17751
17769
|
const versionFlag = shareFlagValue(args, "--version");
|
|
17752
17770
|
if (!revisionId && versionFlag) {
|
|
17753
17771
|
const versions = await client.listPlayVersions(name);
|
|
17754
17772
|
const chosen = versions.find((r) => r.version === Number(versionFlag));
|
|
17755
|
-
if (!_optionalChain([chosen, 'optionalAccess',
|
|
17773
|
+
if (!_optionalChain([chosen, 'optionalAccess', _635 => _635._id])) {
|
|
17756
17774
|
console.error(`Version ${versionFlag} not found for ${name}.`);
|
|
17757
17775
|
return 4;
|
|
17758
17776
|
}
|
|
@@ -17763,12 +17781,12 @@ async function handlePlayShareRegenerate(args) {
|
|
|
17763
17781
|
revisionId ? { revisionId } : {}
|
|
17764
17782
|
);
|
|
17765
17783
|
const outputStatus = shareStatusForOutput(status);
|
|
17766
|
-
if (
|
|
17767
|
-
|
|
17784
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
17785
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, outputStatus);
|
|
17768
17786
|
return 0;
|
|
17769
17787
|
}
|
|
17770
17788
|
const urls = shareUrlFields(outputStatus);
|
|
17771
|
-
const regeneratedPublishedRevision = !revisionId || _optionalChain([outputStatus, 'access',
|
|
17789
|
+
const regeneratedPublishedRevision = !revisionId || _optionalChain([outputStatus, 'access', _636 => _636.share, 'optionalAccess', _637 => _637.publishedRevisionId]) === revisionId;
|
|
17772
17790
|
console.log(
|
|
17773
17791
|
`Regenerated public copy for ${name}${regeneratedPublishedRevision && urls.publicUrl ? `: ${urls.publicUrl}` : "."}`
|
|
17774
17792
|
);
|
|
@@ -17789,9 +17807,9 @@ async function handlePlayShareUnpublish(args) {
|
|
|
17789
17807
|
return 2;
|
|
17790
17808
|
}
|
|
17791
17809
|
const name = parseReferencedPlayTarget(target).playName;
|
|
17792
|
-
const status = await new (0,
|
|
17793
|
-
if (
|
|
17794
|
-
|
|
17810
|
+
const status = await new (0, _chunkUJYX4VLXjs.DeeplineClient)().unpublishSharePage(name);
|
|
17811
|
+
if (_chunkVAOGM5VSjs.argsWantJson.call(void 0, args)) {
|
|
17812
|
+
_chunkVAOGM5VSjs.printCompactJson.call(void 0, status);
|
|
17795
17813
|
return 0;
|
|
17796
17814
|
}
|
|
17797
17815
|
console.log(`Unpublished ${name}; the public page has been removed.`);
|
|
@@ -17869,4 +17887,4 @@ async function handlePlayShareUnpublish(args) {
|
|
|
17869
17887
|
|
|
17870
17888
|
|
|
17871
17889
|
|
|
17872
|
-
exports.PREBUILT_PLAY_TAG_KEYS = PREBUILT_PLAY_TAG_KEYS; exports.assertDatasetHasExportableRows = assertDatasetHasExportableRows; exports.buildPlayCompletionTextLines = buildPlayCompletionTextLines; exports.buildRunActivityTextLines = buildRunActivityTextLines; exports.buildRunLaunch = buildRunLaunch; exports.buildRunLogsText = buildRunLogsText; exports.buildRunPackageTextLines = buildRunPackageTextLines; exports.buildStopAllDryRunTextLines = buildStopAllDryRunTextLines; exports.checkPlayFileExports = checkPlayFileExports; exports.clampJsonPreviewText = clampJsonPreviewText; exports.compactPlayStatus = compactPlayStatus; exports.csvColumnLines = csvColumnLines; exports.describeSleepUntil = describeSleepUntil; exports.exportPlayStatusRows = exportPlayStatusRows; exports.formatPlaySandboxRuntimeWarning = formatPlaySandboxRuntimeWarning; exports.formatStepLabelFromNodeId = formatStepLabelFromNodeId; exports.getFinalStatusFromLiveEvent = getFinalStatusFromLiveEvent; exports.getProgressLinesFromLiveEvent = getProgressLinesFromLiveEvent; exports.getRunningHeartbeatLine = getRunningHeartbeatLine; exports.getStepTransitionLineFromLiveEvent = getStepTransitionLineFromLiveEvent; exports.handlePlayCheck = handlePlayCheck; exports.handlePlayCost = handlePlayCost; exports.handlePlayDelete = handlePlayDelete; exports.handlePlayDescribe = handlePlayDescribe; exports.handlePlayGet = handlePlayGet; exports.handlePlayGrep = handlePlayGrep; exports.handlePlayList = handlePlayList; exports.handlePlayPin = handlePlayPin; exports.handlePlayPublish = handlePlayPublish; exports.handlePlayRestore = handlePlayRestore; exports.handlePlayRun = handlePlayRun; exports.handlePlaySave = handlePlaySave; exports.handlePlaySharePublish = handlePlaySharePublish; exports.handlePlayShareRegenerate = handlePlayShareRegenerate; exports.handlePlayShareStatus = handlePlayShareStatus; exports.handlePlayShareUnpublish = handlePlayShareUnpublish; exports.handlePlayShareUpdate = handlePlayShareUpdate; exports.handlePlayVersions = handlePlayVersions; exports.handleRunEventSearch = handleRunEventSearch; exports.handleRunExport = handleRunExport; exports.handleRunGet = handleRunGet; exports.handleRunLifecycleStatus = handleRunLifecycleStatus; exports.handleRunLogs = handleRunLogs; exports.handleRunStop = handleRunStop; exports.handleRunStopAll = handleRunStopAll; exports.handleRunTail = handleRunTail; exports.handleRunsList = handleRunsList; exports.handleRunsRerun = handleRunsRerun; exports.liveMaxCreditsPerRun = liveMaxCreditsPerRun; exports.loadPlayBundler = loadPlayBundler; exports.parsePlayPublishOptions = parsePlayPublishOptions; exports.parsePlayRunHeaderFlag =
|
|
17890
|
+
exports.PREBUILT_PLAY_TAG_KEYS = PREBUILT_PLAY_TAG_KEYS; exports.assertDatasetHasExportableRows = assertDatasetHasExportableRows; exports.buildPlayCompletionTextLines = buildPlayCompletionTextLines; exports.buildRunActivityTextLines = buildRunActivityTextLines; exports.buildRunLaunch = buildRunLaunch; exports.buildRunLogsText = buildRunLogsText; exports.buildRunPackageTextLines = buildRunPackageTextLines; exports.buildStopAllDryRunTextLines = buildStopAllDryRunTextLines; exports.checkPlayFileExports = checkPlayFileExports; exports.clampJsonPreviewText = clampJsonPreviewText; exports.compactPlayStatus = compactPlayStatus; exports.csvColumnLines = csvColumnLines; exports.describeSleepUntil = describeSleepUntil; exports.exportPlayStatusRows = exportPlayStatusRows; exports.formatPlaySandboxRuntimeWarning = formatPlaySandboxRuntimeWarning; exports.formatStepLabelFromNodeId = formatStepLabelFromNodeId; exports.getFinalStatusFromLiveEvent = getFinalStatusFromLiveEvent; exports.getProgressLinesFromLiveEvent = getProgressLinesFromLiveEvent; exports.getRunningHeartbeatLine = getRunningHeartbeatLine; exports.getStepTransitionLineFromLiveEvent = getStepTransitionLineFromLiveEvent; exports.handlePlayCheck = handlePlayCheck; exports.handlePlayCost = handlePlayCost; exports.handlePlayDelete = handlePlayDelete; exports.handlePlayDescribe = handlePlayDescribe; exports.handlePlayGet = handlePlayGet; exports.handlePlayGrep = handlePlayGrep; exports.handlePlayList = handlePlayList; exports.handlePlayPin = handlePlayPin; exports.handlePlayPublish = handlePlayPublish; exports.handlePlayRestore = handlePlayRestore; exports.handlePlayRun = handlePlayRun; exports.handlePlaySave = handlePlaySave; exports.handlePlaySharePublish = handlePlaySharePublish; exports.handlePlayShareRegenerate = handlePlayShareRegenerate; exports.handlePlayShareStatus = handlePlayShareStatus; exports.handlePlayShareUnpublish = handlePlayShareUnpublish; exports.handlePlayShareUpdate = handlePlayShareUpdate; exports.handlePlayVersions = handlePlayVersions; exports.handleRunEventSearch = handleRunEventSearch; exports.handleRunExport = handleRunExport; exports.handleRunGet = handleRunGet; exports.handleRunLifecycleStatus = handleRunLifecycleStatus; exports.handleRunLogs = handleRunLogs; exports.handleRunStop = handleRunStop; exports.handleRunStopAll = handleRunStopAll; exports.handleRunTail = handleRunTail; exports.handleRunsList = handleRunsList; exports.handleRunsRerun = handleRunsRerun; exports.liveMaxCreditsPerRun = liveMaxCreditsPerRun; exports.loadPlayBundler = loadPlayBundler; exports.parsePlayPublishOptions = parsePlayPublishOptions; exports.parsePlayRunHeaderFlag = _chunkXL3CEPZAjs.parsePlayRunHeaderFlag; exports.parsePlayRunOptions = _chunkXL3CEPZAjs.parsePlayRunOptions; exports.preflightLocalFileInputs = preflightLocalFileInputs; exports.registerPlayCommands = registerPlayCommands; exports.renderRunOverviewText = renderRunOverviewText; exports.resolveDatasetByName = resolveDatasetByName; exports.resolvePlayRunOutputStatus = resolvePlayRunOutputStatus; exports.resolvePlayRunUrl = resolvePlayRunUrl; exports.resolveRunStopState = resolveRunStopState; exports.selectRunLogTailPage = selectRunLogTailPage; exports.shouldPrintPlayProgressLine = shouldPrintPlayProgressLine; exports.startAndWaitForPlayCompletion = startAndWaitForPlayCompletion; exports.startAndWaitForPlayCompletionByStream = startAndWaitForPlayCompletionByStream; exports.takeFromRunRerunArgs = takeFromRunRerunArgs; exports.truncateErrorForDisplay = truncateErrorForDisplay; exports.waitForPlayCompletionByWatch = waitForPlayCompletionByWatch; exports.withTerminalPlayIdentity = withTerminalPlayIdentity; exports.writeInlinePlay = writeInlinePlay; exports.writePlayRunIdFile = writePlayRunIdFile; exports.writePlayRunReceipt = writePlayRunReceipt;
|