deepline 0.3.376 → 0.3.378
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/plays/run-request.ts +3 -0
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/sdk/src/types.ts +5 -0
- package/dist/cli/auth-GC4ZJ6HO.js +39 -0
- package/dist/cli/{auth-MLCDUTJY.mjs → auth-Z4TP4SLF.mjs} +10 -6
- package/dist/cli/{billing-IONI4V7P.js → billing-2LO7C4OI.js} +74 -74
- package/dist/cli/{billing-OUGNDBL4.mjs → billing-JR4QD4UG.mjs} +5 -5
- package/dist/cli/{chunk-V7ZREPSD.mjs → chunk-2TEN5IOR.mjs} +4 -4
- package/dist/cli/{chunk-L6OSOKS6.mjs → chunk-3H2Q377V.mjs} +27 -10
- package/dist/cli/{chunk-GMRWUGXB.mjs → chunk-3OPJYNS2.mjs} +3 -3
- package/dist/cli/{chunk-KHZ6WEVF.js → chunk-4DAUDGO2.js} +26 -26
- package/dist/cli/{chunk-H7SLESX6.mjs → chunk-4YJHPJKQ.mjs} +2 -2
- package/dist/cli/{chunk-34KUUN3Z.js → chunk-A7VUVXW6.js} +65 -54
- package/dist/cli/{chunk-ETUV6RRK.js → chunk-AIRU4XTZ.js} +25 -25
- package/dist/cli/{chunk-ZXFGA2VK.js → chunk-BUHZUAEB.js} +8 -8
- package/dist/cli/{chunk-SPZNLE2D.mjs → chunk-C47TYIAO.mjs} +2 -2
- package/dist/cli/{chunk-UABI2T3Z.mjs → chunk-DNORWBSX.mjs} +2 -2
- package/dist/cli/{chunk-VL5ERG22.mjs → chunk-EEXP6W4X.mjs} +2 -2
- package/dist/cli/{chunk-VNBAOWN3.mjs → chunk-F2RPSYZC.mjs} +6 -6
- package/dist/cli/{chunk-Y5W5IIA4.js → chunk-F7MGUP72.js} +57 -57
- package/dist/cli/{chunk-6EYTKUDI.js → chunk-FH3WJOCD.js} +2 -2
- package/dist/cli/{chunk-7LX2G2PU.mjs → chunk-FJ3JEYFJ.mjs} +1 -1
- package/dist/cli/{chunk-FWF24ULX.mjs → chunk-HVDBGPDP.mjs} +5 -4
- package/dist/cli/{chunk-4WINCNNH.js → chunk-HXENYWVS.js} +5 -4
- package/dist/cli/{chunk-QSH5CHRI.js → chunk-ISVKLCGQ.js} +6 -6
- package/dist/cli/{chunk-5HJHTZI6.mjs → chunk-JORLGBPA.mjs} +1 -1
- package/dist/cli/{chunk-MHRDXS7J.mjs → chunk-KTZFOS57.mjs} +1 -1
- package/dist/cli/{chunk-7ZZSGV4A.js → chunk-LHBPC7PZ.js} +1 -1
- package/dist/cli/{chunk-HDB4GAWY.mjs → chunk-M5HYHFIV.mjs} +1 -1
- package/dist/cli/{chunk-47X6MQ7J.js → chunk-NGYNHAAC.js} +60 -60
- package/dist/cli/{chunk-LA46MMTL.js → chunk-PAIMOGCM.js} +1 -0
- package/dist/cli/{chunk-CBVIJSHF.mjs → chunk-Q6EOHNRH.mjs} +1 -0
- package/dist/cli/{chunk-5HDB7XXT.js → chunk-UCDAF3TI.js} +271 -254
- package/dist/cli/{chunk-YXQ7SRL3.mjs → chunk-V4TN5MXK.mjs} +15 -4
- package/dist/cli/{chunk-UE2UHYT3.mjs → chunk-VB6KECLU.mjs} +57 -6
- package/dist/cli/{chunk-4V2Q3JO6.js → chunk-WHEDPNPN.js} +15 -15
- package/dist/cli/{chunk-Y4MXBE3V.js → chunk-YSX6SSGW.js} +8 -8
- package/dist/cli/{chunk-A6ZTYKYF.js → chunk-ZMVJSS6N.js} +63 -12
- package/dist/cli/{chunk-N6KIEYZV.js → chunk-ZNGZPKXT.js} +4 -4
- package/dist/cli/command-docs.js +2 -2
- package/dist/cli/command-docs.mjs +1 -1
- package/dist/cli/{csv-NITSP7QJ.mjs → csv-EQV4HK57.mjs} +3 -3
- package/dist/cli/{csv-LPC7BGZ2.js → csv-KEA6YLCU.js} +12 -12
- package/dist/cli/{db-WGD54UKM.js → db-BSD7XVVZ.js} +30 -30
- package/dist/cli/{db-JVDYEXNC.mjs → db-CXWVEYF5.mjs} +5 -5
- package/dist/cli/{describe-SVMLA6SN.mjs → describe-5PIG7QJH.mjs} +12 -10
- package/dist/cli/{describe-GA7LSJRY.js → describe-FG5JQWSB.js} +31 -29
- package/dist/cli/{executions-P47HEI4N.js → executions-HLJQEBSX.js} +7 -7
- package/dist/cli/{executions-CXBJDGMU.mjs → executions-IPUW4YTD.mjs} +5 -5
- package/dist/cli/{feedback-GWKWE5CU.js → feedback-6QQVVCSY.js} +7 -7
- package/dist/cli/{feedback-34OSXUQ2.mjs → feedback-P2IEMRL7.mjs} +3 -3
- package/dist/cli/git-24TVX47T.js +23 -0
- package/dist/cli/{git-YAROF6D3.mjs → git-JD6UFEWE.mjs} +4 -4
- package/dist/cli/index.js +108 -103
- package/dist/cli/index.mjs +58 -53
- package/dist/cli/{legacy-noops-MDZQL3QH.js → legacy-noops-JZAEUIHY.js} +7 -7
- package/dist/cli/{legacy-noops-2G55OKIU.mjs → legacy-noops-R6FG44MY.mjs} +4 -4
- package/dist/cli/{monitors-KUGKMABN.mjs → monitors-7YTG6MUN.mjs} +5 -5
- package/dist/cli/{monitors-X7QYWFSP.js → monitors-AEDYTXDI.js} +86 -86
- package/dist/cli/{org-6XL3IBT2.js → org-CXXZEKOE.js} +65 -65
- package/dist/cli/{org-CNBBAN4W.mjs → org-HFFNL6B2.mjs} +5 -5
- package/dist/cli/{play-33ZMPAR5.mjs → play-2LBL27HQ.mjs} +9 -9
- package/dist/cli/play-BTDMU7WD.js +155 -0
- package/dist/cli/{providers-5POAURDT.js → providers-FYPDMYJD.js} +8 -8
- package/dist/cli/{providers-3OSQNFPE.mjs → providers-TSQ4IKGL.mjs} +5 -5
- package/dist/cli/{quickstart-LQGPDJTS.js → quickstart-OLB32KQD.js} +5 -5
- package/dist/cli/{quickstart-QICTOOW6.mjs → quickstart-X4EK2VUO.mjs} +3 -3
- package/dist/cli/{search-HBIX4SF4.mjs → search-DC3MH3SK.mjs} +6 -6
- package/dist/cli/search-MHDPSHQG.js +26 -0
- package/dist/cli/{secrets-QKPBNQ3E.js → secrets-ND2ZJBTH.js} +14 -14
- package/dist/cli/{secrets-6MRGZPHT.mjs → secrets-YS5G7TKA.mjs} +5 -5
- package/dist/cli/{sessions-NODY2OW4.mjs → sessions-FJYWJT4E.mjs} +4 -4
- package/dist/cli/{sessions-NP7BLZD2.js → sessions-ZAWZ23R4.js} +5 -5
- package/dist/cli/{settings-JCEIOTNL.mjs → settings-2PBXGFTK.mjs} +8 -8
- package/dist/cli/{settings-42QHXUB2.js → settings-VGSUOAPQ.js} +75 -75
- package/dist/cli/{setup-3QR4RGMG.mjs → setup-5EGLDCAF.mjs} +6 -6
- package/dist/cli/{setup-5XXWP54Y.js → setup-SBBMRM7G.js} +41 -41
- package/dist/cli/{skills-U4OMXLNS.mjs → skills-HGC3BDBU.mjs} +4 -4
- package/dist/cli/skills-OSEKG6FD.js +28 -0
- package/dist/cli/tools-57UDLV2I.js +40 -0
- package/dist/cli/{tools-45OROEZQ.mjs → tools-UTLVTTWW.mjs} +8 -8
- package/dist/cli/update-5YD7PJFE.js +28 -0
- package/dist/cli/{update-2XCRMJ4R.mjs → update-IFOQMPAX.mjs} +6 -6
- package/dist/cli/{workflow-7X3GCOPY.mjs → workflow-JYUD2UHZ.mjs} +6 -6
- package/dist/cli/{workflow-47P4LQNC.js → workflow-PAM64TA4.js} +16 -16
- package/dist/{client-Cn-txrXv.d.mts → client-0avPvYBP.d.mts} +5 -0
- package/dist/{client-fPoIN-3V.d.ts → client-DEKvymBI.d.ts} +5 -0
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +7 -7
- package/dist/index.mjs +4 -4
- package/dist/install-integrity.json +80 -80
- package/dist/plays/run-request.d.mts +1 -1
- package/dist/plays/run-request.d.ts +1 -1
- package/dist/plays/run-request.js +2 -2
- package/dist/plays/run-request.mjs +1 -1
- package/dist/release.d.mts +1 -1
- package/dist/release.d.ts +1 -1
- package/dist/release.js +2 -2
- package/dist/release.mjs +1 -1
- package/package.json +1 -1
- package/dist/cli/auth-BTFXJQLT.js +0 -35
- package/dist/cli/git-MIPISCON.js +0 -23
- package/dist/cli/play-3CM3P2DS.js +0 -155
- package/dist/cli/search-A2YLJ4I5.js +0 -26
- package/dist/cli/skills-4JJEAA66.js +0 -28
- package/dist/cli/tools-FDCFSA7W.js +0 -40
- package/dist/cli/update-VYL4TXIE.js +0 -28
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkISVKLCGQjs = require('./chunk-ISVKLCGQ.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
@@ -25,7 +25,7 @@ var _chunkQSH5CHRIjs = require('./chunk-QSH5CHRI.js');
|
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
var
|
|
28
|
+
var _chunkZNGZPKXTjs = require('./chunk-ZNGZPKXT.js');
|
|
29
29
|
|
|
30
30
|
// src/cli/commands/auth.ts
|
|
31
31
|
|
|
@@ -52,7 +52,7 @@ function statusBannerLine(value) {
|
|
|
52
52
|
return `Service notice: ${banner.message}`;
|
|
53
53
|
}
|
|
54
54
|
function envFilePath(baseUrl) {
|
|
55
|
-
return
|
|
55
|
+
return _chunkZNGZPKXTjs.hostEnvFilePath.call(void 0, baseUrl);
|
|
56
56
|
}
|
|
57
57
|
function normalizeAuthScope(value) {
|
|
58
58
|
if (!value || value === "global") return "global";
|
|
@@ -65,7 +65,7 @@ function parseAuthScope(args) {
|
|
|
65
65
|
}
|
|
66
66
|
function pendingClaimPath(baseUrl, scope) {
|
|
67
67
|
if (scope === "folder") {
|
|
68
|
-
const target =
|
|
68
|
+
const target = _chunkZNGZPKXTjs.resolveProjectPinTarget.call(void 0, );
|
|
69
69
|
if (!target.ok) {
|
|
70
70
|
throw new Error(
|
|
71
71
|
`Cowork project folder is ambiguous. Candidate folders: ${target.candidates.join(
|
|
@@ -75,10 +75,10 @@ function pendingClaimPath(baseUrl, scope) {
|
|
|
75
75
|
}
|
|
76
76
|
return _path.join.call(void 0, target.dir, ".deepline", "setup", "pending-auth.json");
|
|
77
77
|
}
|
|
78
|
-
return `${
|
|
78
|
+
return `${_chunkZNGZPKXTjs.hostConfigDirPath.call(void 0, baseUrl)}/pending-auth.json`;
|
|
79
79
|
}
|
|
80
80
|
function legacyPendingClaimTokenPath(baseUrl) {
|
|
81
|
-
return `${
|
|
81
|
+
return `${_chunkZNGZPKXTjs.hostConfigDirPath.call(void 0, baseUrl)}/pending-claim-token`;
|
|
82
82
|
}
|
|
83
83
|
function savePendingClaim(baseUrl, claim) {
|
|
84
84
|
const filePath = pendingClaimPath(baseUrl, claim.scope);
|
|
@@ -180,21 +180,21 @@ function parseRegisterWaitMode(args) {
|
|
|
180
180
|
function shouldWaitForRegisterClaim(mode) {
|
|
181
181
|
if (mode === "yes") return true;
|
|
182
182
|
if (mode === "no") return false;
|
|
183
|
-
return
|
|
183
|
+
return _chunkZNGZPKXTjs.detectAgentRuntime.call(void 0, ) !== "claude_cowork";
|
|
184
184
|
}
|
|
185
185
|
function saveEnvValues(values, baseUrl, scope) {
|
|
186
186
|
const filtered = {
|
|
187
|
-
...values[
|
|
188
|
-
...values[
|
|
189
|
-
...values[
|
|
190
|
-
...Object.prototype.hasOwnProperty.call(values,
|
|
187
|
+
...values[_chunkZNGZPKXTjs.HOST_URL_ENV] ? { [_chunkZNGZPKXTjs.HOST_URL_ENV]: values[_chunkZNGZPKXTjs.HOST_URL_ENV] } : {},
|
|
188
|
+
...values[_chunkZNGZPKXTjs.API_KEY_ENV] ? { [_chunkZNGZPKXTjs.API_KEY_ENV]: values[_chunkZNGZPKXTjs.API_KEY_ENV] } : {},
|
|
189
|
+
...values[_chunkZNGZPKXTjs.ACTIVE_ORG_ID_ENV] ? { [_chunkZNGZPKXTjs.ACTIVE_ORG_ID_ENV]: values[_chunkZNGZPKXTjs.ACTIVE_ORG_ID_ENV] } : {},
|
|
190
|
+
...Object.prototype.hasOwnProperty.call(values, _chunkZNGZPKXTjs.ACTIVE_ORG_NAME_ENV) ? { [_chunkZNGZPKXTjs.ACTIVE_ORG_NAME_ENV]: values[_chunkZNGZPKXTjs.ACTIVE_ORG_NAME_ENV] } : {},
|
|
191
191
|
// An explicit empty list must reach the store: it clears a stale line.
|
|
192
|
-
...Object.prototype.hasOwnProperty.call(values,
|
|
192
|
+
...Object.prototype.hasOwnProperty.call(values, _chunkZNGZPKXTjs.FEATURES_ENV) ? { [_chunkZNGZPKXTjs.FEATURES_ENV]: values[_chunkZNGZPKXTjs.FEATURES_ENV] } : {}
|
|
193
193
|
};
|
|
194
194
|
if (scope === "folder") {
|
|
195
|
-
|
|
195
|
+
_chunkZNGZPKXTjs.saveProjectDeeplineEnvValues.call(void 0, filtered);
|
|
196
196
|
} else {
|
|
197
|
-
|
|
197
|
+
_chunkZNGZPKXTjs.saveHostEnvValues.call(void 0, baseUrl, filtered);
|
|
198
198
|
}
|
|
199
199
|
}
|
|
200
200
|
function activeOrgEnvValues(data) {
|
|
@@ -202,21 +202,21 @@ function activeOrgEnvValues(data) {
|
|
|
202
202
|
if (!orgId) return {};
|
|
203
203
|
const orgName = typeof data.org_name === "string" ? data.org_name.trim() : "";
|
|
204
204
|
return {
|
|
205
|
-
[
|
|
206
|
-
[
|
|
207
|
-
...
|
|
205
|
+
[_chunkZNGZPKXTjs.ACTIVE_ORG_ID_ENV]: orgId,
|
|
206
|
+
[_chunkZNGZPKXTjs.ACTIVE_ORG_NAME_ENV]: orgName,
|
|
207
|
+
..._chunkZNGZPKXTjs.featureEnvValues.call(void 0, data)
|
|
208
208
|
};
|
|
209
209
|
}
|
|
210
210
|
async function httpJson(method, url, apiKey, body, timeoutMs = AUTH_HTTP_TIMEOUT_MS) {
|
|
211
211
|
const headers = {
|
|
212
212
|
"Content-Type": "application/json",
|
|
213
|
-
"User-Agent": `deepline-ts-sdk/${
|
|
213
|
+
"User-Agent": `deepline-ts-sdk/${_chunkZNGZPKXTjs.SDK_VERSION}`,
|
|
214
214
|
"X-Deepline-Client-Family": "sdk",
|
|
215
215
|
"X-Deepline-CLI-Family": "sdk",
|
|
216
|
-
"X-Deepline-Agent-Runtime":
|
|
217
|
-
"X-Deepline-CLI-Version":
|
|
218
|
-
"X-Deepline-SDK-Version":
|
|
219
|
-
"X-Deepline-API-Contract":
|
|
216
|
+
"X-Deepline-Agent-Runtime": _chunkZNGZPKXTjs.detectAgentRuntime.call(void 0, ),
|
|
217
|
+
"X-Deepline-CLI-Version": _chunkZNGZPKXTjs.SDK_VERSION,
|
|
218
|
+
"X-Deepline-SDK-Version": _chunkZNGZPKXTjs.SDK_VERSION,
|
|
219
|
+
"X-Deepline-API-Contract": _chunkZNGZPKXTjs.SDK_API_CONTRACT
|
|
220
220
|
};
|
|
221
221
|
if (apiKey) headers["Authorization"] = `Bearer ${apiKey}`;
|
|
222
222
|
const bypassToken = _optionalChain([process, 'access', _7 => _7.env, 'access', _8 => _8.VERCEL_PROTECTION_BYPASS_TOKEN, 'optionalAccess', _9 => _9.trim, 'call', _10 => _10()]);
|
|
@@ -253,8 +253,16 @@ async function httpJson(method, url, apiKey, body, timeoutMs = AUTH_HTTP_TIMEOUT
|
|
|
253
253
|
}
|
|
254
254
|
throw lastError instanceof Error ? lastError : new Error(String(lastError));
|
|
255
255
|
}
|
|
256
|
+
async function readStatusBanner(baseUrl) {
|
|
257
|
+
const response = await httpJson(
|
|
258
|
+
"GET",
|
|
259
|
+
`${baseUrl}/api/v2/status-banner`,
|
|
260
|
+
null
|
|
261
|
+
).catch(() => null);
|
|
262
|
+
return _optionalChain([response, 'optionalAccess', _11 => _11.status]) === 200 ? _nullishCoalesce(response.data.banner, () => ( null)) : null;
|
|
263
|
+
}
|
|
256
264
|
async function reportSetupCompleted(input) {
|
|
257
|
-
const apiKey = input.authScope === "folder" ?
|
|
265
|
+
const apiKey = input.authScope === "folder" ? _chunkZNGZPKXTjs.resolveProjectApiKeyForBaseUrl.call(void 0, input.baseUrl) : _chunkZNGZPKXTjs.resolveGlobalApiKeyForBaseUrl.call(void 0, input.baseUrl);
|
|
258
266
|
if (!apiKey) return;
|
|
259
267
|
try {
|
|
260
268
|
await httpJson(
|
|
@@ -351,7 +359,7 @@ async function printClaimSuccessBanner(baseUrl, apiKey, statusData) {
|
|
|
351
359
|
}
|
|
352
360
|
}
|
|
353
361
|
async function handleRegister(args) {
|
|
354
|
-
const baseUrl =
|
|
362
|
+
const baseUrl = _chunkZNGZPKXTjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
355
363
|
let orgName = "";
|
|
356
364
|
let orgId = "";
|
|
357
365
|
let agentName = "";
|
|
@@ -406,19 +414,19 @@ async function handleRegister(args) {
|
|
|
406
414
|
});
|
|
407
415
|
saveEnvValues(
|
|
408
416
|
{
|
|
409
|
-
[
|
|
417
|
+
[_chunkZNGZPKXTjs.HOST_URL_ENV]: baseUrl
|
|
410
418
|
},
|
|
411
419
|
baseUrl,
|
|
412
420
|
authScope
|
|
413
421
|
);
|
|
414
422
|
}
|
|
415
423
|
if (claimUrl) {
|
|
416
|
-
const shouldOpen = waitMode !== "no" &&
|
|
424
|
+
const shouldOpen = waitMode !== "no" && _chunkZNGZPKXTjs.detectAgentRuntime.call(void 0, ) !== "claude_cowork";
|
|
417
425
|
console.log(
|
|
418
426
|
shouldOpen ? " Opening approval page in your browser." : " Open this approval page in your browser:"
|
|
419
427
|
);
|
|
420
428
|
console.log(` ${claimUrl}`);
|
|
421
|
-
if (shouldOpen)
|
|
429
|
+
if (shouldOpen) _chunkISVKLCGQjs.openInBrowser.call(void 0, claimUrl);
|
|
422
430
|
}
|
|
423
431
|
if (data.cli_message) {
|
|
424
432
|
console.log(String(data.cli_message));
|
|
@@ -461,8 +469,8 @@ async function handleRegister(args) {
|
|
|
461
469
|
if (apiKey) {
|
|
462
470
|
saveEnvValues(
|
|
463
471
|
{
|
|
464
|
-
[
|
|
465
|
-
[
|
|
472
|
+
[_chunkZNGZPKXTjs.HOST_URL_ENV]: baseUrl,
|
|
473
|
+
[_chunkZNGZPKXTjs.API_KEY_ENV]: apiKey,
|
|
466
474
|
...activeOrgEnvValues(statusData)
|
|
467
475
|
},
|
|
468
476
|
baseUrl,
|
|
@@ -484,7 +492,7 @@ async function handleRegister(args) {
|
|
|
484
492
|
}
|
|
485
493
|
}
|
|
486
494
|
async function handleWait(args) {
|
|
487
|
-
const baseUrl =
|
|
495
|
+
const baseUrl = _chunkZNGZPKXTjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
488
496
|
let timeoutSeconds = 300;
|
|
489
497
|
let requestedScope;
|
|
490
498
|
if (args.includes("--auth-scope")) {
|
|
@@ -506,9 +514,9 @@ async function handleWait(args) {
|
|
|
506
514
|
const resumed = resolvePendingAuthClaimForResume(baseUrl, requestedScope);
|
|
507
515
|
const pendingClaim = resumed.claim;
|
|
508
516
|
const authScope = resumed.scope;
|
|
509
|
-
const claimToken = _nullishCoalesce(_optionalChain([pendingClaim, 'optionalAccess',
|
|
517
|
+
const claimToken = _nullishCoalesce(_optionalChain([pendingClaim, 'optionalAccess', _12 => _12.claimToken]), () => ( ""));
|
|
510
518
|
if (!pendingClaim) {
|
|
511
|
-
const scopedApiKey = authScope === "folder" ?
|
|
519
|
+
const scopedApiKey = authScope === "folder" ? _chunkZNGZPKXTjs.resolveProjectApiKeyForBaseUrl.call(void 0, baseUrl) : _chunkZNGZPKXTjs.resolveGlobalApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
512
520
|
if (scopedApiKey) {
|
|
513
521
|
console.log("Already connected.");
|
|
514
522
|
return EXIT_OK;
|
|
@@ -551,8 +559,8 @@ async function handleWait(args) {
|
|
|
551
559
|
if (apiKey) {
|
|
552
560
|
saveEnvValues(
|
|
553
561
|
{
|
|
554
|
-
[
|
|
555
|
-
[
|
|
562
|
+
[_chunkZNGZPKXTjs.HOST_URL_ENV]: baseUrl,
|
|
563
|
+
[_chunkZNGZPKXTjs.API_KEY_ENV]: apiKey,
|
|
556
564
|
...activeOrgEnvValues(data)
|
|
557
565
|
},
|
|
558
566
|
baseUrl,
|
|
@@ -576,8 +584,8 @@ async function handleWait(args) {
|
|
|
576
584
|
return EXIT_AUTH;
|
|
577
585
|
}
|
|
578
586
|
async function authStatusLine(timeoutMs = 3e3) {
|
|
579
|
-
const baseUrl =
|
|
580
|
-
const apiKey =
|
|
587
|
+
const baseUrl = _chunkZNGZPKXTjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
588
|
+
const apiKey = _chunkZNGZPKXTjs.resolveApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
581
589
|
if (!apiKey) return `Auth: not connected (${baseUrl})`;
|
|
582
590
|
try {
|
|
583
591
|
const { status, data } = await httpJson(
|
|
@@ -600,9 +608,9 @@ async function authStatusLine(timeoutMs = 3e3) {
|
|
|
600
608
|
}
|
|
601
609
|
}
|
|
602
610
|
async function handleStatus(args) {
|
|
603
|
-
const baseUrl =
|
|
611
|
+
const baseUrl = _chunkZNGZPKXTjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
604
612
|
const reveal = args.includes("--reveal");
|
|
605
|
-
const jsonOutput =
|
|
613
|
+
const jsonOutput = _chunkISVKLCGQjs.argsWantJson.call(void 0, args);
|
|
606
614
|
const hasExplicitAuthScope = args.includes("--auth-scope");
|
|
607
615
|
let authScope = null;
|
|
608
616
|
if (hasExplicitAuthScope) {
|
|
@@ -615,6 +623,7 @@ async function handleStatus(args) {
|
|
|
615
623
|
}
|
|
616
624
|
let hostStatusPayload = null;
|
|
617
625
|
const hostLines = [];
|
|
626
|
+
const statusBanner = readStatusBanner(baseUrl);
|
|
618
627
|
try {
|
|
619
628
|
const { status: hStatus, data: hData } = await httpJson(
|
|
620
629
|
"GET",
|
|
@@ -626,12 +635,12 @@ async function handleStatus(args) {
|
|
|
626
635
|
host: baseUrl,
|
|
627
636
|
hostStatus: hData.status || "ok",
|
|
628
637
|
hostVersion: hData.version || "(unknown)",
|
|
629
|
-
status_banner:
|
|
638
|
+
status_banner: await statusBanner
|
|
630
639
|
};
|
|
631
640
|
hostLines.push(`Host: ${baseUrl}`);
|
|
632
641
|
hostLines.push(`Host status: ${hData.status || "ok"}`);
|
|
633
642
|
hostLines.push(`Host version: ${hData.version || "(unknown)"}`);
|
|
634
|
-
const bannerLine = statusBannerLine(
|
|
643
|
+
const bannerLine = statusBannerLine(hostStatusPayload.status_banner);
|
|
635
644
|
if (bannerLine) hostLines.push(bannerLine);
|
|
636
645
|
}
|
|
637
646
|
} catch (e10) {
|
|
@@ -642,14 +651,14 @@ async function handleStatus(args) {
|
|
|
642
651
|
};
|
|
643
652
|
hostLines.push(`Host: ${baseUrl} (unreachable)`);
|
|
644
653
|
}
|
|
645
|
-
const apiKey = authScope === "folder" ?
|
|
654
|
+
const apiKey = authScope === "folder" ? _chunkZNGZPKXTjs.resolveProjectApiKeyForBaseUrl.call(void 0, baseUrl) : authScope === "global" ? _chunkZNGZPKXTjs.resolveGlobalApiKeyForBaseUrl.call(void 0, baseUrl) : _chunkZNGZPKXTjs.resolveApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
646
655
|
if (!apiKey) {
|
|
647
656
|
const { claim: pendingClaim } = resolvePendingAuthClaimForResume(
|
|
648
657
|
baseUrl,
|
|
649
658
|
_nullishCoalesce(authScope, () => ( void 0))
|
|
650
659
|
);
|
|
651
660
|
if (pendingClaim) {
|
|
652
|
-
|
|
661
|
+
_chunkISVKLCGQjs.printCommandEnvelope.call(void 0,
|
|
653
662
|
{
|
|
654
663
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
655
664
|
status: "pending",
|
|
@@ -670,7 +679,7 @@ async function handleStatus(args) {
|
|
|
670
679
|
);
|
|
671
680
|
return EXIT_OK;
|
|
672
681
|
}
|
|
673
|
-
|
|
682
|
+
_chunkISVKLCGQjs.printCommandEnvelope.call(void 0,
|
|
674
683
|
{
|
|
675
684
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
676
685
|
status: "not connected",
|
|
@@ -703,7 +712,7 @@ async function handleStatus(args) {
|
|
|
703
712
|
}
|
|
704
713
|
);
|
|
705
714
|
if (status === 401 || status === 403) {
|
|
706
|
-
|
|
715
|
+
_chunkISVKLCGQjs.printCommandEnvelope.call(void 0,
|
|
707
716
|
{
|
|
708
717
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
709
718
|
status: "unauthorized",
|
|
@@ -730,7 +739,7 @@ async function handleStatus(args) {
|
|
|
730
739
|
console.error(`Auth status error (status ${status}).`);
|
|
731
740
|
return EXIT_SERVER;
|
|
732
741
|
}
|
|
733
|
-
const resolvedAuthScope = _nullishCoalesce(authScope, () => ( (
|
|
742
|
+
const resolvedAuthScope = _nullishCoalesce(authScope, () => ( (_chunkZNGZPKXTjs.getResolvedProjectAuthSource.call(void 0, baseUrl, apiKey) ? "folder" : "global")));
|
|
734
743
|
clearSatisfiedPendingClaim(
|
|
735
744
|
baseUrl,
|
|
736
745
|
resolvedAuthScope,
|
|
@@ -758,28 +767,28 @@ async function handleStatus(args) {
|
|
|
758
767
|
if (apiKeyResp) {
|
|
759
768
|
saveEnvValues(
|
|
760
769
|
{
|
|
761
|
-
[
|
|
762
|
-
[
|
|
770
|
+
[_chunkZNGZPKXTjs.HOST_URL_ENV]: baseUrl,
|
|
771
|
+
[_chunkZNGZPKXTjs.API_KEY_ENV]: apiKeyResp,
|
|
763
772
|
...activeOrgEnvValues(data)
|
|
764
773
|
},
|
|
765
774
|
baseUrl,
|
|
766
775
|
resolvedAuthScope
|
|
767
776
|
);
|
|
768
777
|
if (resolvedAuthScope === "folder") {
|
|
769
|
-
const target =
|
|
778
|
+
const target = _chunkZNGZPKXTjs.resolveProjectPinTarget.call(void 0, );
|
|
770
779
|
savedApiKeyPath = target.ok ? _path.join.call(void 0, target.dir, ".env.deepline") : null;
|
|
771
780
|
} else {
|
|
772
781
|
savedApiKeyPath = envFilePath(baseUrl);
|
|
773
782
|
}
|
|
774
783
|
}
|
|
775
|
-
} else if (resolvedAuthScope === "folder" ||
|
|
776
|
-
saveEnvValues(
|
|
784
|
+
} else if (resolvedAuthScope === "folder" || _chunkZNGZPKXTjs.storedHostApiKey.call(void 0, baseUrl) === apiKey) {
|
|
785
|
+
saveEnvValues(_chunkZNGZPKXTjs.featureEnvValues.call(void 0, data), baseUrl, resolvedAuthScope);
|
|
777
786
|
}
|
|
778
|
-
|
|
787
|
+
_chunkISVKLCGQjs.printCommandEnvelope.call(void 0,
|
|
779
788
|
{
|
|
780
789
|
...payload,
|
|
781
|
-
...
|
|
782
|
-
command_context:
|
|
790
|
+
..._chunkZNGZPKXTjs.detectAgentRuntime.call(void 0, ) !== "unknown" ? {
|
|
791
|
+
command_context: _chunkZNGZPKXTjs.resolveCliCommandContext.call(void 0,
|
|
783
792
|
{ baseUrl, apiKey },
|
|
784
793
|
resolvedAuthScope
|
|
785
794
|
)
|
|
@@ -936,4 +945,6 @@ Examples:
|
|
|
936
945
|
|
|
937
946
|
|
|
938
947
|
|
|
939
|
-
|
|
948
|
+
|
|
949
|
+
|
|
950
|
+
exports.EXIT_WORKSPACE_MISMATCH = EXIT_WORKSPACE_MISMATCH; exports.statusBannerLine = statusBannerLine; exports.resolvePendingAuthClaimForResume = resolvePendingAuthClaimForResume; exports.readPendingAuthClaim = readPendingAuthClaim; exports.clearPendingClaim = clearPendingClaim; exports.clearSatisfiedPendingClaim = clearSatisfiedPendingClaim; exports.httpJson = httpJson; exports.readStatusBanner = readStatusBanner; exports.reportSetupCompleted = reportSetupCompleted; exports.handleRegister = handleRegister; exports.handleWait = handleWait; exports.authStatusLine = authStatusLine; exports.handleStatus = handleStatus; exports.registerAuthCommands = registerAuthCommands;
|
|
@@ -13,7 +13,7 @@ var _chunkS6R3OX7Bjs = require('./chunk-S6R3OX7B.js');
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunkPAIMOGCMjs = require('./chunk-PAIMOGCM.js');
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
@@ -21,7 +21,7 @@ var _chunkLA46MMTLjs = require('./chunk-LA46MMTL.js');
|
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
|
|
24
|
-
var
|
|
24
|
+
var _chunkZNGZPKXTjs = require('./chunk-ZNGZPKXT.js');
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
|
|
@@ -137,7 +137,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
137
137
|
if (error instanceof _chunk7P5AA3SNjs.DeeplineError && (_optionalChain([error, 'access', _ => _.code, 'optionalAccess', _2 => _2.startsWith, 'call', _3 => _3("NETWORK_")]) || // Older API readers return PostgreSQL errors as HTTP 400, including
|
|
138
138
|
// lost connections and explicitly unknown transaction resolution.
|
|
139
139
|
/^08[A-Z0-9]{3}$/.test(_nullishCoalesce(error.code, () => ( ""))) || ["57P01", "57P02", "57P03"].includes(_nullishCoalesce(error.code, () => ( ""))) || error.statusCode === 408 || (_nullishCoalesce(error.statusCode, () => ( 0))) >= 500)) {
|
|
140
|
-
throw new (0,
|
|
140
|
+
throw new (0, _chunkZNGZPKXTjs.CustomerDbQueryOutcomeUnknownError)(
|
|
141
141
|
error,
|
|
142
142
|
plan.request.body.operation_key
|
|
143
143
|
);
|
|
@@ -145,7 +145,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
145
145
|
throw error;
|
|
146
146
|
}
|
|
147
147
|
if (!result || typeof result !== "object" || Array.isArray(result) || typeof result.command !== "string" || !Array.isArray(result.columns) || !Array.isArray(result.rows) || typeof result.truncated !== "boolean" || result.row_count !== null && (!Number.isSafeInteger(result.row_count) || result.row_count < 0) || !Number.isSafeInteger(result.row_count_returned) || result.row_count_returned < 0) {
|
|
148
|
-
throw new (0,
|
|
148
|
+
throw new (0, _chunkZNGZPKXTjs.CustomerDbQueryOutcomeUnknownError)(
|
|
149
149
|
new (0, _chunk7P5AA3SNjs.DeeplineError)(
|
|
150
150
|
"The SQL response did not contain a valid result.",
|
|
151
151
|
200,
|
|
@@ -156,7 +156,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
156
156
|
}
|
|
157
157
|
const operation = result.operation;
|
|
158
158
|
if (input.operationKey !== void 0 && (!operation || operation.operation_key !== input.operationKey || !Number.isSafeInteger(operation.completed_at_ms) || operation.completed_at_ms < 0 || !["executed", "operation_recovery"].includes(operation.source))) {
|
|
159
|
-
throw new (0,
|
|
159
|
+
throw new (0, _chunkZNGZPKXTjs.CustomerDbQueryOutcomeUnknownError)(
|
|
160
160
|
new (0, _chunk7P5AA3SNjs.DeeplineError)(
|
|
161
161
|
"The server did not confirm the original atomic SQL operation.",
|
|
162
162
|
200,
|
|
@@ -2340,7 +2340,7 @@ var TERMINAL_STATUS_BY_EVENT_TYPE = {
|
|
|
2340
2340
|
|
|
2341
2341
|
// ../play-runtime/run-snapshot-stream.ts
|
|
2342
2342
|
function isTerminalPlayRunLiveStatus(status) {
|
|
2343
|
-
return
|
|
2343
|
+
return _chunkPAIMOGCMjs.isTerminalPlayRunLifecycleStatus.call(void 0, status);
|
|
2344
2344
|
}
|
|
2345
2345
|
function makeRunStreamEvent(input) {
|
|
2346
2346
|
return {
|
|
@@ -2910,8 +2910,8 @@ function runtimeSelectionHeaders(runtime) {
|
|
|
2910
2910
|
}
|
|
2911
2911
|
const receivers = _optionalChain([process, 'access', _104 => _104.env, 'access', _105 => _105.DEEPLINE_RUNTIME_RETAINED_PIPELINE_RECEIVERS, 'optionalAccess', _106 => _106.trim, 'call', _107 => _107()]);
|
|
2912
2912
|
return {
|
|
2913
|
-
[
|
|
2914
|
-
...receivers ? { [
|
|
2913
|
+
[_chunkZNGZPKXTjs.RUNTIME_ENVIRONMENT_TOKEN_HEADER]: token,
|
|
2914
|
+
...receivers ? { [_chunkZNGZPKXTjs.RETAINED_PIPELINE_RECEIVERS_HEADER]: receivers } : {}
|
|
2915
2915
|
};
|
|
2916
2916
|
}
|
|
2917
2917
|
function isolatedCiRuntimeEventReadHeaders() {
|
|
@@ -2927,7 +2927,7 @@ function isolatedCiRuntimeEventReadHeaders() {
|
|
|
2927
2927
|
"RUNTIME_EVENT_INTERNAL_TOKEN_REQUIRED"
|
|
2928
2928
|
);
|
|
2929
2929
|
}
|
|
2930
|
-
return { [
|
|
2930
|
+
return { [_chunkZNGZPKXTjs.COORDINATOR_INTERNAL_TOKEN_HEADER]: token };
|
|
2931
2931
|
}
|
|
2932
2932
|
function normalizeTestPolicyOverrides(value, source) {
|
|
2933
2933
|
if (value && typeof value === "object" && !Array.isArray(value)) {
|
|
@@ -3075,10 +3075,10 @@ function preferPrebuiltPlayDescriptions(plays) {
|
|
|
3075
3075
|
).map(({ play }) => play);
|
|
3076
3076
|
}
|
|
3077
3077
|
function normalizePlayStatus(raw) {
|
|
3078
|
-
const runPackage =
|
|
3078
|
+
const runPackage = _chunkPAIMOGCMjs.isPlayRunPackage.call(void 0, raw) ? raw : _chunkPAIMOGCMjs.isPlayRunPackage.call(void 0, raw.package) ? raw.package : null;
|
|
3079
3079
|
const packageRun = _optionalChain([runPackage, 'optionalAccess', _137 => _137.run]);
|
|
3080
3080
|
const rawStatus = typeof raw.status === "string" ? raw.status : typeof _optionalChain([packageRun, 'optionalAccess', _138 => _138.status]) === "string" ? packageRun.status : null;
|
|
3081
|
-
const status =
|
|
3081
|
+
const status = _chunkPAIMOGCMjs.decodePlayRunPublicStatus.call(void 0, rawStatus);
|
|
3082
3082
|
if (!status) {
|
|
3083
3083
|
throw new Error(
|
|
3084
3084
|
`Invalid play run lifecycle status in API response: ${JSON.stringify(rawStatus)}.`
|
|
@@ -3112,7 +3112,7 @@ function playLiveRunStatus(event) {
|
|
|
3112
3112
|
return null;
|
|
3113
3113
|
}
|
|
3114
3114
|
const payload = getPlayLiveEventPayload(event);
|
|
3115
|
-
return _nullishCoalesce(
|
|
3115
|
+
return _nullishCoalesce(_chunkPAIMOGCMjs.decodePlayRunPublicStatus.call(void 0, payload.status), () => ( (_chunkPAIMOGCMjs.isPlayRunPackage.call(void 0, payload) ? _chunkPAIMOGCMjs.decodePlayRunPublicStatus.call(void 0, payload.run.status) : null)));
|
|
3116
3116
|
}
|
|
3117
3117
|
function appendPlayLiveLogLines(state, payload) {
|
|
3118
3118
|
const lines = readStringArray(payload.lines);
|
|
@@ -3144,7 +3144,7 @@ function updatePlayLiveStatusState(state, event) {
|
|
|
3144
3144
|
if (event.type !== "play.run.snapshot" && event.type !== "play.run.status" && event.type !== "play.run.final_status") {
|
|
3145
3145
|
return null;
|
|
3146
3146
|
}
|
|
3147
|
-
const runId = typeof payload.runId === "string" && payload.runId ? payload.runId :
|
|
3147
|
+
const runId = typeof payload.runId === "string" && payload.runId ? payload.runId : _chunkPAIMOGCMjs.isPlayRunPackage.call(void 0, payload) ? payload.run.id : state.runId;
|
|
3148
3148
|
const status = _nullishCoalesce(playLiveRunStatus(event), () => ( state.status));
|
|
3149
3149
|
const progressPayload = isRecord2(payload.progress) ? payload.progress : {};
|
|
3150
3150
|
if (event.type === "play.run.final_status" && state.logs.length === 0 && state.lastLogSeq === 0) {
|
|
@@ -3157,7 +3157,7 @@ function updatePlayLiveStatusState(state, event) {
|
|
|
3157
3157
|
}
|
|
3158
3158
|
if ("result" in payload) {
|
|
3159
3159
|
state.result = payload.result;
|
|
3160
|
-
} else if (
|
|
3160
|
+
} else if (_chunkPAIMOGCMjs.isPlayRunPackage.call(void 0, payload)) {
|
|
3161
3161
|
state.result = payload;
|
|
3162
3162
|
}
|
|
3163
3163
|
if (typeof payload.error === "string" && payload.error.trim()) {
|
|
@@ -3170,7 +3170,7 @@ function updatePlayLiveStatusState(state, event) {
|
|
|
3170
3170
|
...payload,
|
|
3171
3171
|
runId,
|
|
3172
3172
|
status,
|
|
3173
|
-
...
|
|
3173
|
+
..._chunkPAIMOGCMjs.isPlayRunPackage.call(void 0, payload) ? { package: payload, outputs: payload.outputs } : {},
|
|
3174
3174
|
progress: {
|
|
3175
3175
|
...progressRecord,
|
|
3176
3176
|
status: typeof progressRecord.status === "string" ? progressRecord.status : status,
|
|
@@ -3217,8 +3217,8 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
3217
3217
|
* @throws {@link ConfigError} if no API key can be resolved from any source.
|
|
3218
3218
|
*/
|
|
3219
3219
|
constructor(options) {
|
|
3220
|
-
this.config =
|
|
3221
|
-
this.http = new (0,
|
|
3220
|
+
this.config = _chunkZNGZPKXTjs.resolveConfig.call(void 0, options);
|
|
3221
|
+
this.http = new (0, _chunkZNGZPKXTjs.HttpClient)(this.config);
|
|
3222
3222
|
this.toolCalls = new ToolCalls(
|
|
3223
3223
|
this.http,
|
|
3224
3224
|
this.config.timeout,
|
|
@@ -3736,7 +3736,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
3736
3736
|
*/
|
|
3737
3737
|
async startPlayRun(request) {
|
|
3738
3738
|
const resolved = resolveStartPlayRunRequest(request);
|
|
3739
|
-
return
|
|
3739
|
+
return _chunkPAIMOGCMjs.startPlayRun.call(void 0,
|
|
3740
3740
|
this.http,
|
|
3741
3741
|
resolved.request,
|
|
3742
3742
|
runtimeSelectionHeaders(resolved.runtime)
|
|
@@ -3757,9 +3757,9 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
3757
3757
|
*/
|
|
3758
3758
|
async *startPlayRunStream(request, options) {
|
|
3759
3759
|
const resolved = resolveStartPlayRunRequest(request);
|
|
3760
|
-
const body =
|
|
3760
|
+
const body = _chunkPAIMOGCMjs.buildPlayRunStartBody.call(void 0, resolved.request);
|
|
3761
3761
|
for await (const event of this.http.streamSse(
|
|
3762
|
-
|
|
3762
|
+
_chunkPAIMOGCMjs.PLAY_RUN_START_STREAM_PATH,
|
|
3763
3763
|
{
|
|
3764
3764
|
method: "POST",
|
|
3765
3765
|
body,
|
|
@@ -4028,7 +4028,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
4028
4028
|
* ```
|
|
4029
4029
|
*/
|
|
4030
4030
|
async stagePlayFiles(files) {
|
|
4031
|
-
return
|
|
4031
|
+
return _chunkPAIMOGCMjs.stagePlayFiles.call(void 0, this.http, files);
|
|
4032
4032
|
}
|
|
4033
4033
|
/**
|
|
4034
4034
|
* Mint short-lived presigned upload targets for staged play files.
|
|
@@ -4038,7 +4038,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
4038
4038
|
* already holds, or a presigned PUT URL the caller uploads the body to.
|
|
4039
4039
|
*/
|
|
4040
4040
|
async mintStagedPlayFileUploads(files) {
|
|
4041
|
-
return
|
|
4041
|
+
return _chunkPAIMOGCMjs.mintStagedPlayFileUploads.call(void 0, this.http, files);
|
|
4042
4042
|
}
|
|
4043
4043
|
/**
|
|
4044
4044
|
* Resolve staged play files by content hash without uploading bytes.
|
|
@@ -4135,7 +4135,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
4135
4135
|
onRetry: _nullishCoalesce(_optionalChain([options, 'optionalAccess', _226 => _226.onRetry]), () => ( _optionalChain([options, 'optionalAccess', _227 => _227.onReconnect])))
|
|
4136
4136
|
})) {
|
|
4137
4137
|
_optionalChain([options, 'optionalAccess', _228 => _228.onEvent, 'optionalCall', _229 => _229(event)]);
|
|
4138
|
-
if (
|
|
4138
|
+
if (_chunkPAIMOGCMjs.isTerminalPlayRunLifecycleStatus.call(void 0, playLiveRunStatus(event))) {
|
|
4139
4139
|
terminalObserved = true;
|
|
4140
4140
|
}
|
|
4141
4141
|
}
|
|
@@ -4143,7 +4143,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
4143
4143
|
throw new (0, _chunk7P5AA3SNjs.DeeplineError)("Run watch aborted.", void 0, "ABORTED");
|
|
4144
4144
|
}
|
|
4145
4145
|
const refreshed = await this.getRunStatus(runId);
|
|
4146
|
-
if (terminalObserved ||
|
|
4146
|
+
if (terminalObserved || _chunkPAIMOGCMjs.isTerminalPlayRunLifecycleStatus.call(void 0, refreshed.status)) {
|
|
4147
4147
|
return refreshed;
|
|
4148
4148
|
}
|
|
4149
4149
|
throw new (0, _chunk7P5AA3SNjs.DeeplineError)(
|
|
@@ -5589,7 +5589,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
5589
5589
|
if (event.type !== "play.run.status" || status.status !== previousStatus) {
|
|
5590
5590
|
_optionalChain([options, 'optionalAccess', _327 => _327.onProgress, 'optionalCall', _328 => _328(status)]);
|
|
5591
5591
|
}
|
|
5592
|
-
if (
|
|
5592
|
+
if (_chunkPAIMOGCMjs.isTerminalPlayRunLifecycleStatus.call(void 0, status.status)) {
|
|
5593
5593
|
terminalObserved = status;
|
|
5594
5594
|
}
|
|
5595
5595
|
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkAIRU4XTZjs = require('./chunk-AIRU4XTZ.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkISVKLCGQjs = require('./chunk-ISVKLCGQ.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkZNGZPKXTjs = require('./chunk-ZNGZPKXT.js');
|
|
12
12
|
|
|
13
13
|
// src/cli/commands/search.ts
|
|
14
14
|
var _commander = require('commander');
|
|
@@ -18,7 +18,7 @@ var _fs = require('fs');
|
|
|
18
18
|
var _path = require('path');
|
|
19
19
|
var SEARCH_REF_TTL_MS = 15 * 6e4;
|
|
20
20
|
function lastSearchPath() {
|
|
21
|
-
return _path.join.call(void 0,
|
|
21
|
+
return _path.join.call(void 0, _chunkZNGZPKXTjs.sdkCliStateDirPath.call(void 0, _chunkZNGZPKXTjs.resolveConfig.call(void 0, ).baseUrl), "last-search.json");
|
|
22
22
|
}
|
|
23
23
|
function rememberSearchRef(searchRef) {
|
|
24
24
|
try {
|
|
@@ -259,7 +259,7 @@ function searchRow(item) {
|
|
|
259
259
|
}
|
|
260
260
|
function renderSearchResults(result) {
|
|
261
261
|
if (result.results.length === 0)
|
|
262
|
-
return
|
|
262
|
+
return _chunkISVKLCGQjs.renderCommandEnvelopeText.call(void 0, result);
|
|
263
263
|
const rows = result.results.map(searchRow);
|
|
264
264
|
const kinds = new Set(rows.map((row) => row.kind));
|
|
265
265
|
const onlyTools = kinds.size === 1 && kinds.has("tool");
|
|
@@ -283,7 +283,7 @@ function renderSearchResults(result) {
|
|
|
283
283
|
actions: _optionalChain([render, 'optionalAccess', _11 => _11.actions])
|
|
284
284
|
};
|
|
285
285
|
const followUps = _optionalChain([remaining, 'access', _12 => _12.sections, 'optionalAccess', _13 => _13.length]) || _optionalChain([remaining, 'access', _14 => _14.actions, 'optionalAccess', _15 => _15.length]) ? `
|
|
286
|
-
${
|
|
286
|
+
${_chunkISVKLCGQjs.renderCommandEnvelopeText.call(void 0, { render: remaining })}` : "";
|
|
287
287
|
const notes = rows.flatMap(
|
|
288
288
|
(row) => row.notes.map((note) => ` ${row.id}: ${note}`)
|
|
289
289
|
);
|
|
@@ -360,7 +360,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
|
|
|
360
360
|
console.error(USAGE);
|
|
361
361
|
return 1;
|
|
362
362
|
}
|
|
363
|
-
const { search_ref: searchRef, ...result } = await new (0,
|
|
363
|
+
const { search_ref: searchRef, ...result } = await new (0, _chunkAIRU4XTZjs.DeeplineClient)().search({
|
|
364
364
|
query,
|
|
365
365
|
types,
|
|
366
366
|
exclude,
|
|
@@ -374,7 +374,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
|
|
|
374
374
|
});
|
|
375
375
|
if (searchRef) rememberSearchRef(searchRef);
|
|
376
376
|
pointAtDescribe(result);
|
|
377
|
-
|
|
377
|
+
_chunkISVKLCGQjs.printCommandEnvelope.call(void 0, result, {
|
|
378
378
|
json: options.json === true,
|
|
379
379
|
text: renderSearchResults(result)
|
|
380
380
|
});
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-GAMFK2ZP.mjs";
|
|
4
4
|
import {
|
|
5
5
|
printCommandEnvelope
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-KTZFOS57.mjs";
|
|
7
7
|
import {
|
|
8
8
|
DEFAULT_SKILL_AGENTS,
|
|
9
9
|
KNOWN_SKILL_AGENTS,
|
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
sdkCliStateDirPath,
|
|
23
23
|
skillsAgentPathSegment,
|
|
24
24
|
writeSdkSkillsLocalVersion
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-M5HYHFIV.mjs";
|
|
26
26
|
import {
|
|
27
27
|
DeeplineError
|
|
28
28
|
} from "./chunk-NXGCO4JB.mjs";
|
|
@@ -2,10 +2,10 @@ import {
|
|
|
2
2
|
getAuthedHttpClient,
|
|
3
3
|
openInBrowser,
|
|
4
4
|
printCommandEnvelope
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-KTZFOS57.mjs";
|
|
6
6
|
import {
|
|
7
7
|
resolveBaseUrlOnly
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-M5HYHFIV.mjs";
|
|
9
9
|
|
|
10
10
|
// src/cli/commands/git.ts
|
|
11
11
|
function shellQuote(value) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getAuthedHttpClient,
|
|
3
3
|
printCommandEnvelope
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-KTZFOS57.mjs";
|
|
5
5
|
import {
|
|
6
6
|
agentSessionIdFromEnvironment
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-M5HYHFIV.mjs";
|
|
8
8
|
|
|
9
9
|
// src/cli/commands/sessions.ts
|
|
10
10
|
import {
|