deepline 0.3.353 → 0.3.355
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +3 -1
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-event-search.ts +54 -40
- package/dist/cli/{auth-FVIZVTCB.mjs → auth-3IQKHFUS.mjs} +4 -4
- package/dist/cli/auth-Q4OX2XOA.js +31 -0
- package/dist/cli/{billing-PYTYGWPG.mjs → billing-2O2HPRIQ.mjs} +4 -4
- package/dist/cli/{billing-NWL7KQPZ.js → billing-QACLO2L4.js} +73 -73
- package/dist/cli/{chunk-NFEQHNDQ.js → chunk-56UZ4LCT.js} +26 -26
- package/dist/cli/{chunk-ZDEO3EGW.mjs → chunk-5TFTY4H5.mjs} +1 -1
- package/dist/cli/{chunk-ZCCXX55K.js → chunk-63CWWQE6.js} +45 -45
- package/dist/cli/{chunk-D477W2OQ.mjs → chunk-64YA2SCL.mjs} +4 -4
- package/dist/cli/{chunk-IVGFLYQ6.mjs → chunk-6745OKK5.mjs} +1 -1
- package/dist/cli/{chunk-GFLHAA2O.mjs → chunk-B2C2PR6I.mjs} +1 -1
- package/dist/cli/{chunk-2UWRFDI4.js → chunk-CG5JEYRX.js} +60 -60
- package/dist/cli/{chunk-55XOA2VW.js → chunk-CKBJ2PQR.js} +8 -8
- package/dist/cli/{chunk-HU4SUDWU.js → chunk-CL6NZN6X.js} +224 -224
- package/dist/cli/{chunk-VALAAQQM.js → chunk-CQXFJZ57.js} +48 -48
- package/dist/cli/{chunk-CXMSK2VV.mjs → chunk-DYWM3EZG.mjs} +2 -2
- package/dist/cli/{chunk-BVHUTDCW.mjs → chunk-FC2SOWXT.mjs} +5 -5
- package/dist/cli/{chunk-Z6LVVOOJ.js → chunk-GGM6CX2R.js} +15 -15
- package/dist/cli/{chunk-DY253DRK.mjs → chunk-IQJBKSMD.mjs} +2 -2
- package/dist/cli/{chunk-R2T4HQ64.js → chunk-J2WSV37F.js} +6 -6
- package/dist/cli/{chunk-M4UPRX3M.js → chunk-J6I4RSDG.js} +8 -8
- package/dist/cli/{chunk-NPU4SMKT.js → chunk-PGBSGPQ3.js} +9 -9
- package/dist/cli/{chunk-XI5IMY45.js → chunk-QYKLKWQO.js} +2 -2
- package/dist/cli/{chunk-RRDCBCRI.mjs → chunk-R2O2BKDH.mjs} +1 -1
- package/dist/cli/{chunk-U3FUXTIB.mjs → chunk-SDZW7NSO.mjs} +1 -1
- package/dist/cli/{chunk-EDEO7NG4.js → chunk-TKWCYYIM.js} +1 -1
- package/dist/cli/{chunk-NZNUDZDW.mjs → chunk-UAPP5IVJ.mjs} +2 -2
- package/dist/cli/{chunk-LLI4RITH.mjs → chunk-USB6LFMD.mjs} +3 -3
- package/dist/cli/{chunk-CQQ5N4YO.mjs → chunk-VALEHQXO.mjs} +2 -2
- package/dist/cli/{chunk-JHPVZR6F.js → chunk-WMULUP2K.js} +4 -4
- package/dist/cli/{chunk-37F4EUJA.mjs → chunk-XXC7ST6U.mjs} +6 -6
- package/dist/cli/client-ISC4LLIX.js +20 -0
- package/dist/cli/{client-IH7I5D7T.mjs → client-QQMVHMOY.mjs} +3 -3
- package/dist/cli/{csv-TJIWKUCX.js → csv-DQBAUFB6.js} +12 -12
- package/dist/cli/{csv-G5WXNCLQ.mjs → csv-DWIYPLLH.mjs} +3 -3
- package/dist/cli/{db-EBHV2MGE.mjs → db-LFLTGHKA.mjs} +4 -4
- package/dist/cli/{db-3DCS2JXS.js → db-QET2DLHP.js} +29 -29
- package/dist/cli/{describe-QUOLGZKH.mjs → describe-LR5QXOKB.mjs} +8 -8
- package/dist/cli/{describe-5XKBPWD7.js → describe-Z2YFVBNO.js} +15 -15
- package/dist/cli/{executions-NYIOENKH.js → executions-5T2TL6CL.js} +6 -6
- package/dist/cli/{executions-EERWIJ5I.mjs → executions-ARKMIMHM.mjs} +4 -4
- package/dist/cli/{feedback-Z2I5MQYZ.js → feedback-4POM6CBJ.js} +7 -7
- package/dist/cli/{feedback-4RYJJCYL.mjs → feedback-YAEIOXMS.mjs} +3 -3
- package/dist/cli/{git-EMU7AKX3.mjs → git-OCMBR5FC.mjs} +4 -4
- package/dist/cli/git-RZCZI3ER.js +23 -0
- package/dist/cli/index.js +79 -79
- package/dist/cli/index.mjs +31 -31
- package/dist/cli/{legacy-noops-HHLNM523.mjs → legacy-noops-DCZUS7ES.mjs} +4 -4
- package/dist/cli/{legacy-noops-BEUYYRSU.js → legacy-noops-IKM26VQP.js} +7 -7
- package/dist/cli/{monitors-BVJSHUV4.mjs → monitors-FYDK5HOY.mjs} +4 -4
- package/dist/cli/{monitors-KQXLMPZ4.js → monitors-P5FGTRL3.js} +85 -85
- package/dist/cli/{org-HRYNVOUH.js → org-HAQEVMOO.js} +60 -60
- package/dist/cli/{org-KSROOKSJ.mjs → org-P3EKASXE.mjs} +4 -4
- package/dist/cli/{play-PGFW6PFE.mjs → play-VQPA3FJM.mjs} +7 -7
- package/dist/cli/play-YEQ4JQUW.js +153 -0
- package/dist/cli/{providers-EUKJK6ZE.mjs → providers-ATI5HUBZ.mjs} +4 -4
- package/dist/cli/{providers-BJM725CV.js → providers-M34KOQTE.js} +7 -7
- package/dist/cli/{quickstart-72JYHUJC.mjs → quickstart-7YP5G2PM.mjs} +3 -3
- package/dist/cli/{quickstart-FEERYTYY.js → quickstart-WBAHFDVT.js} +5 -5
- package/dist/cli/{search-LUAIOM56.mjs → search-5DI73SZD.mjs} +5 -5
- package/dist/cli/search-USWDT7PW.js +26 -0
- package/dist/cli/{secrets-J65QCH57.js → secrets-C4HJ7BTJ.js} +13 -13
- package/dist/cli/{secrets-YYFRYS2Z.mjs → secrets-F6TOYGUG.mjs} +4 -4
- package/dist/cli/{sessions-WBA67YYT.mjs → sessions-JG5Y4YHP.mjs} +4 -4
- package/dist/cli/{sessions-FWUUEK6V.js → sessions-P6ED3JWC.js} +5 -5
- package/dist/cli/{settings-I7AZ4JVI.js → settings-UVT6MUZH.js} +74 -74
- package/dist/cli/{settings-RUMTSUE5.mjs → settings-YERL4MKN.mjs} +7 -7
- package/dist/cli/{setup-BHRRNT5C.mjs → setup-C6NYXZX4.mjs} +6 -6
- package/dist/cli/{setup-R3IUFNDP.js → setup-LREJO56L.js} +41 -41
- package/dist/cli/{skills-EKD5O7GQ.mjs → skills-4HU5RV5M.mjs} +4 -4
- package/dist/cli/skills-74GBPOGS.js +28 -0
- package/dist/cli/tools-GUFCJGVW.js +40 -0
- package/dist/cli/{tools-L5OA2343.mjs → tools-SR46KMKA.mjs} +6 -6
- package/dist/cli/update-K47QQUCB.js +28 -0
- package/dist/cli/{update-UUHL6FER.mjs → update-XFV6ELFK.mjs} +6 -6
- package/dist/cli/{workflow-7NBSG5OT.js → workflow-E2BSA6OI.js} +15 -15
- package/dist/cli/{workflow-V24VHOQT.mjs → workflow-OHS4NXMP.mjs} +5 -5
- package/dist/index.js +6 -6
- package/dist/index.mjs +3 -3
- package/dist/install-integrity.json +74 -74
- 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-GJZ3S4QH.js +0 -31
- package/dist/cli/client-Z6BCEGFA.js +0 -20
- package/dist/cli/git-QYQ5ZFIG.js +0 -23
- package/dist/cli/play-CRHUA45Q.js +0 -153
- package/dist/cli/search-X25S2U54.js +0 -26
- package/dist/cli/skills-OOZ5SDVB.js +0 -28
- package/dist/cli/tools-MYH33NTL.js +0 -40
- package/dist/cli/update-EWNPE3NF.js +0 -28
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkJ2WSV37Fjs = require('./chunk-J2WSV37F.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
@@ -25,7 +25,7 @@ var _chunkR2T4HQ64js = require('./chunk-R2T4HQ64.js');
|
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
var
|
|
28
|
+
var _chunkWMULUP2Kjs = require('./chunk-WMULUP2K.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 _chunkWMULUP2Kjs.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 = _chunkWMULUP2Kjs.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 `${_chunkWMULUP2Kjs.hostConfigDirPath.call(void 0, baseUrl)}/pending-auth.json`;
|
|
79
79
|
}
|
|
80
80
|
function legacyPendingClaimTokenPath(baseUrl) {
|
|
81
|
-
return `${
|
|
81
|
+
return `${_chunkWMULUP2Kjs.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 _chunkWMULUP2Kjs.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[_chunkWMULUP2Kjs.HOST_URL_ENV] ? { [_chunkWMULUP2Kjs.HOST_URL_ENV]: values[_chunkWMULUP2Kjs.HOST_URL_ENV] } : {},
|
|
188
|
+
...values[_chunkWMULUP2Kjs.API_KEY_ENV] ? { [_chunkWMULUP2Kjs.API_KEY_ENV]: values[_chunkWMULUP2Kjs.API_KEY_ENV] } : {},
|
|
189
|
+
...values[_chunkWMULUP2Kjs.ACTIVE_ORG_ID_ENV] ? { [_chunkWMULUP2Kjs.ACTIVE_ORG_ID_ENV]: values[_chunkWMULUP2Kjs.ACTIVE_ORG_ID_ENV] } : {},
|
|
190
|
+
...Object.prototype.hasOwnProperty.call(values, _chunkWMULUP2Kjs.ACTIVE_ORG_NAME_ENV) ? { [_chunkWMULUP2Kjs.ACTIVE_ORG_NAME_ENV]: values[_chunkWMULUP2Kjs.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, _chunkWMULUP2Kjs.FEATURES_ENV) ? { [_chunkWMULUP2Kjs.FEATURES_ENV]: values[_chunkWMULUP2Kjs.FEATURES_ENV] } : {}
|
|
193
193
|
};
|
|
194
194
|
if (scope === "folder") {
|
|
195
|
-
|
|
195
|
+
_chunkWMULUP2Kjs.saveProjectDeeplineEnvValues.call(void 0, filtered);
|
|
196
196
|
} else {
|
|
197
|
-
|
|
197
|
+
_chunkWMULUP2Kjs.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
|
+
[_chunkWMULUP2Kjs.ACTIVE_ORG_ID_ENV]: orgId,
|
|
206
|
+
[_chunkWMULUP2Kjs.ACTIVE_ORG_NAME_ENV]: orgName,
|
|
207
|
+
..._chunkWMULUP2Kjs.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/${_chunkWMULUP2Kjs.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": _chunkWMULUP2Kjs.detectAgentRuntime.call(void 0, ),
|
|
217
|
+
"X-Deepline-CLI-Version": _chunkWMULUP2Kjs.SDK_VERSION,
|
|
218
|
+
"X-Deepline-SDK-Version": _chunkWMULUP2Kjs.SDK_VERSION,
|
|
219
|
+
"X-Deepline-API-Contract": _chunkWMULUP2Kjs.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()]);
|
|
@@ -254,7 +254,7 @@ async function httpJson(method, url, apiKey, body, timeoutMs = AUTH_HTTP_TIMEOUT
|
|
|
254
254
|
throw lastError instanceof Error ? lastError : new Error(String(lastError));
|
|
255
255
|
}
|
|
256
256
|
async function reportSetupCompleted(input) {
|
|
257
|
-
const apiKey = input.authScope === "folder" ?
|
|
257
|
+
const apiKey = input.authScope === "folder" ? _chunkWMULUP2Kjs.resolveProjectApiKeyForBaseUrl.call(void 0, input.baseUrl) : _chunkWMULUP2Kjs.resolveGlobalApiKeyForBaseUrl.call(void 0, input.baseUrl);
|
|
258
258
|
if (!apiKey) return;
|
|
259
259
|
try {
|
|
260
260
|
await httpJson(
|
|
@@ -351,7 +351,7 @@ async function printClaimSuccessBanner(baseUrl, apiKey, statusData) {
|
|
|
351
351
|
}
|
|
352
352
|
}
|
|
353
353
|
async function handleRegister(args) {
|
|
354
|
-
const baseUrl =
|
|
354
|
+
const baseUrl = _chunkWMULUP2Kjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
355
355
|
let orgName = "";
|
|
356
356
|
let orgId = "";
|
|
357
357
|
let agentName = "";
|
|
@@ -406,19 +406,19 @@ async function handleRegister(args) {
|
|
|
406
406
|
});
|
|
407
407
|
saveEnvValues(
|
|
408
408
|
{
|
|
409
|
-
[
|
|
409
|
+
[_chunkWMULUP2Kjs.HOST_URL_ENV]: baseUrl
|
|
410
410
|
},
|
|
411
411
|
baseUrl,
|
|
412
412
|
authScope
|
|
413
413
|
);
|
|
414
414
|
}
|
|
415
415
|
if (claimUrl) {
|
|
416
|
-
const shouldOpen = waitMode !== "no" &&
|
|
416
|
+
const shouldOpen = waitMode !== "no" && _chunkWMULUP2Kjs.detectAgentRuntime.call(void 0, ) !== "claude_cowork";
|
|
417
417
|
console.log(
|
|
418
418
|
shouldOpen ? " Opening approval page in your browser." : " Open this approval page in your browser:"
|
|
419
419
|
);
|
|
420
420
|
console.log(` ${claimUrl}`);
|
|
421
|
-
if (shouldOpen)
|
|
421
|
+
if (shouldOpen) _chunkJ2WSV37Fjs.openInBrowser.call(void 0, claimUrl);
|
|
422
422
|
}
|
|
423
423
|
if (data.cli_message) {
|
|
424
424
|
console.log(String(data.cli_message));
|
|
@@ -461,8 +461,8 @@ async function handleRegister(args) {
|
|
|
461
461
|
if (apiKey) {
|
|
462
462
|
saveEnvValues(
|
|
463
463
|
{
|
|
464
|
-
[
|
|
465
|
-
[
|
|
464
|
+
[_chunkWMULUP2Kjs.HOST_URL_ENV]: baseUrl,
|
|
465
|
+
[_chunkWMULUP2Kjs.API_KEY_ENV]: apiKey,
|
|
466
466
|
...activeOrgEnvValues(statusData)
|
|
467
467
|
},
|
|
468
468
|
baseUrl,
|
|
@@ -484,7 +484,7 @@ async function handleRegister(args) {
|
|
|
484
484
|
}
|
|
485
485
|
}
|
|
486
486
|
async function handleWait(args) {
|
|
487
|
-
const baseUrl =
|
|
487
|
+
const baseUrl = _chunkWMULUP2Kjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
488
488
|
let timeoutSeconds = 300;
|
|
489
489
|
let requestedScope;
|
|
490
490
|
if (args.includes("--auth-scope")) {
|
|
@@ -508,7 +508,7 @@ async function handleWait(args) {
|
|
|
508
508
|
const authScope = resumed.scope;
|
|
509
509
|
const claimToken = _nullishCoalesce(_optionalChain([pendingClaim, 'optionalAccess', _11 => _11.claimToken]), () => ( ""));
|
|
510
510
|
if (!pendingClaim) {
|
|
511
|
-
const scopedApiKey = authScope === "folder" ?
|
|
511
|
+
const scopedApiKey = authScope === "folder" ? _chunkWMULUP2Kjs.resolveProjectApiKeyForBaseUrl.call(void 0, baseUrl) : _chunkWMULUP2Kjs.resolveGlobalApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
512
512
|
if (scopedApiKey) {
|
|
513
513
|
console.log("Already connected.");
|
|
514
514
|
return EXIT_OK;
|
|
@@ -551,8 +551,8 @@ async function handleWait(args) {
|
|
|
551
551
|
if (apiKey) {
|
|
552
552
|
saveEnvValues(
|
|
553
553
|
{
|
|
554
|
-
[
|
|
555
|
-
[
|
|
554
|
+
[_chunkWMULUP2Kjs.HOST_URL_ENV]: baseUrl,
|
|
555
|
+
[_chunkWMULUP2Kjs.API_KEY_ENV]: apiKey,
|
|
556
556
|
...activeOrgEnvValues(data)
|
|
557
557
|
},
|
|
558
558
|
baseUrl,
|
|
@@ -576,9 +576,9 @@ async function handleWait(args) {
|
|
|
576
576
|
return EXIT_AUTH;
|
|
577
577
|
}
|
|
578
578
|
async function handleStatus(args) {
|
|
579
|
-
const baseUrl =
|
|
579
|
+
const baseUrl = _chunkWMULUP2Kjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
580
580
|
const reveal = args.includes("--reveal");
|
|
581
|
-
const jsonOutput =
|
|
581
|
+
const jsonOutput = _chunkJ2WSV37Fjs.argsWantJson.call(void 0, args);
|
|
582
582
|
const hasExplicitAuthScope = args.includes("--auth-scope");
|
|
583
583
|
let authScope = null;
|
|
584
584
|
if (hasExplicitAuthScope) {
|
|
@@ -618,14 +618,14 @@ async function handleStatus(args) {
|
|
|
618
618
|
};
|
|
619
619
|
hostLines.push(`Host: ${baseUrl} (unreachable)`);
|
|
620
620
|
}
|
|
621
|
-
const apiKey = authScope === "folder" ?
|
|
621
|
+
const apiKey = authScope === "folder" ? _chunkWMULUP2Kjs.resolveProjectApiKeyForBaseUrl.call(void 0, baseUrl) : authScope === "global" ? _chunkWMULUP2Kjs.resolveGlobalApiKeyForBaseUrl.call(void 0, baseUrl) : _chunkWMULUP2Kjs.resolveApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
622
622
|
if (!apiKey) {
|
|
623
623
|
const { claim: pendingClaim } = resolvePendingAuthClaimForResume(
|
|
624
624
|
baseUrl,
|
|
625
625
|
_nullishCoalesce(authScope, () => ( void 0))
|
|
626
626
|
);
|
|
627
627
|
if (pendingClaim) {
|
|
628
|
-
|
|
628
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0,
|
|
629
629
|
{
|
|
630
630
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
631
631
|
status: "pending",
|
|
@@ -646,7 +646,7 @@ async function handleStatus(args) {
|
|
|
646
646
|
);
|
|
647
647
|
return EXIT_OK;
|
|
648
648
|
}
|
|
649
|
-
|
|
649
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0,
|
|
650
650
|
{
|
|
651
651
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
652
652
|
status: "not connected",
|
|
@@ -679,7 +679,7 @@ async function handleStatus(args) {
|
|
|
679
679
|
}
|
|
680
680
|
);
|
|
681
681
|
if (status === 401 || status === 403) {
|
|
682
|
-
|
|
682
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0,
|
|
683
683
|
{
|
|
684
684
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
685
685
|
status: "unauthorized",
|
|
@@ -706,7 +706,7 @@ async function handleStatus(args) {
|
|
|
706
706
|
console.error(`Auth status error (status ${status}).`);
|
|
707
707
|
return EXIT_SERVER;
|
|
708
708
|
}
|
|
709
|
-
const resolvedAuthScope = _nullishCoalesce(authScope, () => ( (
|
|
709
|
+
const resolvedAuthScope = _nullishCoalesce(authScope, () => ( (_chunkWMULUP2Kjs.getResolvedProjectAuthSource.call(void 0, baseUrl, apiKey) ? "folder" : "global")));
|
|
710
710
|
clearSatisfiedPendingClaim(
|
|
711
711
|
baseUrl,
|
|
712
712
|
resolvedAuthScope,
|
|
@@ -734,28 +734,28 @@ async function handleStatus(args) {
|
|
|
734
734
|
if (apiKeyResp) {
|
|
735
735
|
saveEnvValues(
|
|
736
736
|
{
|
|
737
|
-
[
|
|
738
|
-
[
|
|
737
|
+
[_chunkWMULUP2Kjs.HOST_URL_ENV]: baseUrl,
|
|
738
|
+
[_chunkWMULUP2Kjs.API_KEY_ENV]: apiKeyResp,
|
|
739
739
|
...activeOrgEnvValues(data)
|
|
740
740
|
},
|
|
741
741
|
baseUrl,
|
|
742
742
|
resolvedAuthScope
|
|
743
743
|
);
|
|
744
744
|
if (resolvedAuthScope === "folder") {
|
|
745
|
-
const target =
|
|
745
|
+
const target = _chunkWMULUP2Kjs.resolveProjectPinTarget.call(void 0, );
|
|
746
746
|
savedApiKeyPath = target.ok ? _path.join.call(void 0, target.dir, ".env.deepline") : null;
|
|
747
747
|
} else {
|
|
748
748
|
savedApiKeyPath = envFilePath(baseUrl);
|
|
749
749
|
}
|
|
750
750
|
}
|
|
751
|
-
} else if (resolvedAuthScope === "folder" ||
|
|
752
|
-
saveEnvValues(
|
|
751
|
+
} else if (resolvedAuthScope === "folder" || _chunkWMULUP2Kjs.storedHostApiKey.call(void 0, baseUrl) === apiKey) {
|
|
752
|
+
saveEnvValues(_chunkWMULUP2Kjs.featureEnvValues.call(void 0, data), baseUrl, resolvedAuthScope);
|
|
753
753
|
}
|
|
754
|
-
|
|
754
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0,
|
|
755
755
|
{
|
|
756
756
|
...payload,
|
|
757
|
-
...
|
|
758
|
-
command_context:
|
|
757
|
+
..._chunkWMULUP2Kjs.detectAgentRuntime.call(void 0, ) !== "unknown" ? {
|
|
758
|
+
command_context: _chunkWMULUP2Kjs.resolveCliCommandContext.call(void 0,
|
|
759
759
|
{ baseUrl, apiKey },
|
|
760
760
|
resolvedAuthScope
|
|
761
761
|
)
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-GAMFK2ZP.mjs";
|
|
4
4
|
import {
|
|
5
5
|
printCommandEnvelope
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-5TFTY4H5.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-SDZW7NSO.mjs";
|
|
26
26
|
import {
|
|
27
27
|
DeeplineError
|
|
28
28
|
} from "./chunk-NXGCO4JB.mjs";
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
import {
|
|
12
12
|
recentSearchRef,
|
|
13
13
|
registerDeprecatedSearchCommand
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-USB6LFMD.mjs";
|
|
15
15
|
import {
|
|
16
16
|
extractSummaryFields,
|
|
17
17
|
projectRowOutput,
|
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
import {
|
|
24
24
|
DeeplineClient,
|
|
25
25
|
validateExecutionIdempotencyKey
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-6745OKK5.mjs";
|
|
27
27
|
import {
|
|
28
28
|
beginToolExecuteCommand,
|
|
29
29
|
getToolExecuteInvocationId,
|
|
@@ -37,11 +37,11 @@ import {
|
|
|
37
37
|
printJsonError,
|
|
38
38
|
renderCommandEnvelopeText,
|
|
39
39
|
shouldEmitJson
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-5TFTY4H5.mjs";
|
|
41
41
|
import {
|
|
42
42
|
resolveConfig,
|
|
43
43
|
sdkCliStateDirPath
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-SDZW7NSO.mjs";
|
|
45
45
|
import {
|
|
46
46
|
playToolListGetterMode
|
|
47
47
|
} from "./chunk-7E66A24V.mjs";
|
|
@@ -1030,7 +1030,7 @@ Examples:
|
|
|
1030
1030
|
process.exitCode = await narrowView();
|
|
1031
1031
|
return;
|
|
1032
1032
|
}
|
|
1033
|
-
const { describeAnything } = await import("./describe-
|
|
1033
|
+
const { describeAnything } = await import("./describe-LR5QXOKB.mjs");
|
|
1034
1034
|
process.exitCode = await describeAnything(
|
|
1035
1035
|
toolId,
|
|
1036
1036
|
{ ...options, kinds: ["tools", "monitors"], fetchedTool: metadata },
|
|
@@ -1,17 +1,17 @@
|
|
|
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
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkQYKLKWQOjs = require('./chunk-QYKLKWQO.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkCG5JEYRXjs = require('./chunk-CG5JEYRX.js');
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkJ2WSV37Fjs = require('./chunk-J2WSV37F.js');
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _chunkWMULUP2Kjs = require('./chunk-WMULUP2K.js');
|
|
15
15
|
|
|
16
16
|
// src/cli/commands/update.ts
|
|
17
17
|
var _child_process = require('child_process');
|
|
@@ -489,7 +489,7 @@ function normalizedNpmPrefix(value) {
|
|
|
489
489
|
}
|
|
490
490
|
function resolveNpmGlobalPrefix(env) {
|
|
491
491
|
try {
|
|
492
|
-
const plan =
|
|
492
|
+
const plan = _chunkCG5JEYRXjs.resolveShellSpawn.call(void 0, "npm", ["prefix", "-g"], process.platform, env);
|
|
493
493
|
const result = _child_process.spawnSync.call(void 0, plan.command, plan.args, {
|
|
494
494
|
encoding: "utf8",
|
|
495
495
|
env,
|
|
@@ -545,8 +545,8 @@ function resolveUpdatePlan(options = {}) {
|
|
|
545
545
|
const npmGlobalPrefix = options.npmGlobalPrefix !== void 0 ? options.npmGlobalPrefix : resolveNpmGlobalPrefix(env);
|
|
546
546
|
const hasVerifiedNpmOwnership = inferredInstallPrefix !== null && normalizedNpmPrefix(inferredInstallPrefix) === normalizedNpmPrefix(npmGlobalPrefix);
|
|
547
547
|
const installPrefix = options.requireVerifiedNpmOwnership ? hasVerifiedNpmOwnership ? inferredInstallPrefix : null : inferredInstallPrefix;
|
|
548
|
-
const npmVersion = options.npmVersion === void 0 ?
|
|
549
|
-
const npmGlobalInstallFlags =
|
|
548
|
+
const npmVersion = options.npmVersion === void 0 ? _chunkQYKLKWQOjs.readNpmVersion.call(void 0, env) : options.npmVersion;
|
|
549
|
+
const npmGlobalInstallFlags = _chunkQYKLKWQOjs.npmSupportsAllowScripts.call(void 0, npmVersion) ? [...NPM_SDK_INSTALL_COMMON_FLAGS, "--allow-scripts=esbuild"] : NPM_SDK_INSTALL_COMMON_FLAGS;
|
|
550
550
|
const args = installPrefix ? [
|
|
551
551
|
"install",
|
|
552
552
|
"-g",
|
|
@@ -556,7 +556,7 @@ function resolveUpdatePlan(options = {}) {
|
|
|
556
556
|
packageSpec
|
|
557
557
|
] : ["install", "-g", ...npmGlobalInstallFlags, packageSpec];
|
|
558
558
|
const fallbackRegistryUrl = options.npmFallbackRegistryUrl !== void 0 ? options.npmFallbackRegistryUrl : publicNpmFallbackRegistryUrl(
|
|
559
|
-
_optionalChain([env, 'access', _18 => _18.DEEPLINE_HOST_URL, 'optionalAccess', _19 => _19.trim, 'call', _20 => _20()]) ||
|
|
559
|
+
_optionalChain([env, 'access', _18 => _18.DEEPLINE_HOST_URL, 'optionalAccess', _19 => _19.trim, 'call', _20 => _20()]) || _chunkWMULUP2Kjs.autoDetectBaseUrl.call(void 0, )
|
|
560
560
|
);
|
|
561
561
|
return {
|
|
562
562
|
kind: "npm-global",
|
|
@@ -703,7 +703,7 @@ function sidecarInstallFailure(versionDir) {
|
|
|
703
703
|
function runCommand(command, args, env = process.env) {
|
|
704
704
|
return new Promise((resolveResult) => {
|
|
705
705
|
let output = "";
|
|
706
|
-
const plan =
|
|
706
|
+
const plan = _chunkCG5JEYRXjs.resolveShellSpawn.call(void 0, command, args, process.platform, env);
|
|
707
707
|
const child = _child_process.spawn.call(void 0, plan.command, plan.args, {
|
|
708
708
|
stdio: ["inherit", "pipe", "pipe"],
|
|
709
709
|
shell: plan.shell,
|
|
@@ -1079,14 +1079,14 @@ async function publishedVersionSupportsPin(version, fallbackRegistryUrl) {
|
|
|
1079
1079
|
throw _nullishCoalesce(lastError, () => ( new Error("No npm registry was available")));
|
|
1080
1080
|
}
|
|
1081
1081
|
async function runUpdateCommand(options, dependencies = {}) {
|
|
1082
|
-
const detectBaseUrl = _nullishCoalesce(dependencies.detectBaseUrl, () => (
|
|
1082
|
+
const detectBaseUrl = _nullishCoalesce(dependencies.detectBaseUrl, () => ( _chunkWMULUP2Kjs.autoDetectBaseUrl));
|
|
1083
1083
|
const resolvePlan = _nullishCoalesce(dependencies.resolvePlan, () => ( resolveUpdatePlan));
|
|
1084
1084
|
const runPlan = _nullishCoalesce(dependencies.runPlan, () => ( runUpdatePlan));
|
|
1085
1085
|
const syncSkills = _nullishCoalesce(dependencies.syncSkillsIfNeeded, () => ( (async () => {
|
|
1086
1086
|
const originalWrite = process.stdout.write.bind(process.stdout);
|
|
1087
1087
|
process.stdout.write = (() => true);
|
|
1088
1088
|
try {
|
|
1089
|
-
const exitCode = await
|
|
1089
|
+
const exitCode = await _chunkCG5JEYRXjs.runSkillsCommand.call(void 0, { json: true });
|
|
1090
1090
|
if (exitCode !== 0) {
|
|
1091
1091
|
throw new Error(
|
|
1092
1092
|
`Deepline skills update failed with exit ${exitCode}.`
|
|
@@ -1157,11 +1157,11 @@ async function runUpdateCommand(options, dependencies = {}) {
|
|
|
1157
1157
|
]
|
|
1158
1158
|
};
|
|
1159
1159
|
if (options.json && !options.executeWithJson) {
|
|
1160
|
-
|
|
1160
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0, { ...plan, render }, { json: true });
|
|
1161
1161
|
return 0;
|
|
1162
1162
|
}
|
|
1163
1163
|
if (options.printCommand) {
|
|
1164
|
-
|
|
1164
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0,
|
|
1165
1165
|
{
|
|
1166
1166
|
...plan,
|
|
1167
1167
|
render: {
|
|
@@ -1174,7 +1174,7 @@ async function runUpdateCommand(options, dependencies = {}) {
|
|
|
1174
1174
|
return 0;
|
|
1175
1175
|
}
|
|
1176
1176
|
if (plan.kind === "source" || plan.kind === "homebrew") {
|
|
1177
|
-
|
|
1177
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0, { ...plan, render }, { json: false });
|
|
1178
1178
|
return 0;
|
|
1179
1179
|
}
|
|
1180
1180
|
stderr.write(`Updating Deepline SDK/CLI with: ${plan.manualCommand}
|
|
@@ -1204,7 +1204,7 @@ To retry with full installer output, run: deepline skills --json
|
|
|
1204
1204
|
);
|
|
1205
1205
|
}
|
|
1206
1206
|
if (options.executeWithJson && options.json) {
|
|
1207
|
-
|
|
1207
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0,
|
|
1208
1208
|
{
|
|
1209
1209
|
ok: true,
|
|
1210
1210
|
pinnedVersion
|
|
@@ -2,10 +2,10 @@ import {
|
|
|
2
2
|
getAuthedHttpClient,
|
|
3
3
|
openInBrowser,
|
|
4
4
|
printCommandEnvelope
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-5TFTY4H5.mjs";
|
|
6
6
|
import {
|
|
7
7
|
resolveBaseUrlOnly
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-SDZW7NSO.mjs";
|
|
9
9
|
|
|
10
10
|
// src/cli/commands/git.ts
|
|
11
11
|
function shellQuote(value) {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkWMULUP2Kjs = require('./chunk-WMULUP2K.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
var _chunk7P5AA3SNjs = require('./chunk-7P5AA3SN.js');
|
|
@@ -225,8 +225,8 @@ var BROWSER_OPEN_COOLDOWN_MS = 3e4;
|
|
|
225
225
|
var SAME_URL_BROWSER_OPEN_COOLDOWN_MS = 5 * 6e4;
|
|
226
226
|
var defaultBrowserCommandRunner = childProcess;
|
|
227
227
|
function getAuthedHttpClient() {
|
|
228
|
-
const config =
|
|
229
|
-
return { config, http: new (0,
|
|
228
|
+
const config = _chunkWMULUP2Kjs.resolveConfig.call(void 0, );
|
|
229
|
+
return { config, http: new (0, _chunkWMULUP2Kjs.HttpClient)(config) };
|
|
230
230
|
}
|
|
231
231
|
function stableOsUserId() {
|
|
232
232
|
try {
|
|
@@ -566,7 +566,7 @@ function collectLocalEnvInfo() {
|
|
|
566
566
|
os: `${process.platform} ${process.arch}`,
|
|
567
567
|
node_version: process.version,
|
|
568
568
|
home_dir: homeDir,
|
|
569
|
-
agent_runtime:
|
|
569
|
+
agent_runtime: _chunkWMULUP2Kjs.detectAgentRuntime.call(void 0, )
|
|
570
570
|
};
|
|
571
571
|
const env = process.env;
|
|
572
572
|
const optional = {
|
|
@@ -813,9 +813,9 @@ function markdownTableFromRows(rows, preferredColumns = []) {
|
|
|
813
813
|
}
|
|
814
814
|
function withAgentCommandContext(value) {
|
|
815
815
|
const valueRecord = value !== null && typeof value === "object" && !Array.isArray(value) ? value : null;
|
|
816
|
-
return
|
|
816
|
+
return _chunkWMULUP2Kjs.detectAgentRuntime.call(void 0, ) !== "unknown" && valueRecord && !Object.prototype.hasOwnProperty.call(valueRecord, "command_context") ? {
|
|
817
817
|
...valueRecord,
|
|
818
|
-
command_context:
|
|
818
|
+
command_context: _chunkWMULUP2Kjs.resolveCliCommandContext.call(void 0, )
|
|
819
819
|
} : value;
|
|
820
820
|
}
|
|
821
821
|
function printJson(value, fields) {
|
|
@@ -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 _chunkPGBSGPQ3js = require('./chunk-PGBSGPQ3.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkJ2WSV37Fjs = require('./chunk-J2WSV37F.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkWMULUP2Kjs = require('./chunk-WMULUP2K.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, _chunkWMULUP2Kjs.sdkCliStateDirPath.call(void 0, _chunkWMULUP2Kjs.resolveConfig.call(void 0, ).baseUrl), "last-search.json");
|
|
22
22
|
}
|
|
23
23
|
function rememberSearchRef(searchRef) {
|
|
24
24
|
try {
|
|
@@ -145,7 +145,7 @@ function searchRow(item) {
|
|
|
145
145
|
}
|
|
146
146
|
function renderSearchResults(result) {
|
|
147
147
|
if (result.results.length === 0)
|
|
148
|
-
return
|
|
148
|
+
return _chunkJ2WSV37Fjs.renderCommandEnvelopeText.call(void 0, result);
|
|
149
149
|
const rows = result.results.map(searchRow);
|
|
150
150
|
const kinds = new Set(rows.map((row) => row.kind));
|
|
151
151
|
const onlyTools = kinds.size === 1 && kinds.has("tool");
|
|
@@ -169,7 +169,7 @@ function renderSearchResults(result) {
|
|
|
169
169
|
actions: _optionalChain([render, 'optionalAccess', _11 => _11.actions])
|
|
170
170
|
};
|
|
171
171
|
const followUps = _optionalChain([remaining, 'access', _12 => _12.sections, 'optionalAccess', _13 => _13.length]) || _optionalChain([remaining, 'access', _14 => _14.actions, 'optionalAccess', _15 => _15.length]) ? `
|
|
172
|
-
${
|
|
172
|
+
${_chunkJ2WSV37Fjs.renderCommandEnvelopeText.call(void 0, { render: remaining })}` : "";
|
|
173
173
|
const notes = rows.flatMap(
|
|
174
174
|
(row) => row.notes.map((note) => ` ${row.id}: ${note}`)
|
|
175
175
|
);
|
|
@@ -246,7 +246,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
|
|
|
246
246
|
console.error(USAGE);
|
|
247
247
|
return 1;
|
|
248
248
|
}
|
|
249
|
-
const { search_ref: searchRef, ...result } = await new (0,
|
|
249
|
+
const { search_ref: searchRef, ...result } = await new (0, _chunkPGBSGPQ3js.DeeplineClient)().search({
|
|
250
250
|
query,
|
|
251
251
|
types,
|
|
252
252
|
exclude,
|
|
@@ -260,7 +260,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
|
|
|
260
260
|
});
|
|
261
261
|
if (searchRef) rememberSearchRef(searchRef);
|
|
262
262
|
pointAtDescribe(result);
|
|
263
|
-
|
|
263
|
+
_chunkJ2WSV37Fjs.printCommandEnvelope.call(void 0, result, {
|
|
264
264
|
json: options.json === true,
|
|
265
265
|
text: renderSearchResults(result)
|
|
266
266
|
});
|
|
@@ -15,7 +15,7 @@ var _chunkLA46MMTLjs = require('./chunk-LA46MMTL.js');
|
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _chunkWMULUP2Kjs = require('./chunk-WMULUP2K.js');
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
@@ -167,7 +167,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
167
167
|
if (error instanceof _chunk7P5AA3SNjs.DeeplineError && (_optionalChain([error, 'access', _2 => _2.code, 'optionalAccess', _3 => _3.startsWith, 'call', _4 => _4("NETWORK_")]) || // Older API readers return PostgreSQL errors as HTTP 400, including
|
|
168
168
|
// lost connections and explicitly unknown transaction resolution.
|
|
169
169
|
/^08[A-Z0-9]{3}$/.test(_nullishCoalesce(error.code, () => ( ""))) || ["57P01", "57P02", "57P03"].includes(_nullishCoalesce(error.code, () => ( ""))) || error.statusCode === 408 || (_nullishCoalesce(error.statusCode, () => ( 0))) >= 500)) {
|
|
170
|
-
throw new (0,
|
|
170
|
+
throw new (0, _chunkWMULUP2Kjs.CustomerDbQueryOutcomeUnknownError)(
|
|
171
171
|
error,
|
|
172
172
|
plan.request.body.operation_key
|
|
173
173
|
);
|
|
@@ -175,7 +175,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
175
175
|
throw error;
|
|
176
176
|
}
|
|
177
177
|
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) {
|
|
178
|
-
throw new (0,
|
|
178
|
+
throw new (0, _chunkWMULUP2Kjs.CustomerDbQueryOutcomeUnknownError)(
|
|
179
179
|
new (0, _chunk7P5AA3SNjs.DeeplineError)(
|
|
180
180
|
"The SQL response did not contain a valid result.",
|
|
181
181
|
200,
|
|
@@ -186,7 +186,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
186
186
|
}
|
|
187
187
|
const operation = result.operation;
|
|
188
188
|
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))) {
|
|
189
|
-
throw new (0,
|
|
189
|
+
throw new (0, _chunkWMULUP2Kjs.CustomerDbQueryOutcomeUnknownError)(
|
|
190
190
|
new (0, _chunk7P5AA3SNjs.DeeplineError)(
|
|
191
191
|
"The server did not confirm the original atomic SQL operation.",
|
|
192
192
|
200,
|
|
@@ -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
|
+
[_chunkWMULUP2Kjs.RUNTIME_ENVIRONMENT_TOKEN_HEADER]: token,
|
|
2914
|
+
...receivers ? { [_chunkWMULUP2Kjs.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 { [_chunkWMULUP2Kjs.COORDINATOR_INTERNAL_TOKEN_HEADER]: token };
|
|
2931
2931
|
}
|
|
2932
2932
|
function normalizeTestPolicyOverrides(value, source) {
|
|
2933
2933
|
if (value && typeof value === "object" && !Array.isArray(value)) {
|
|
@@ -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 = _chunkWMULUP2Kjs.resolveConfig.call(void 0, options);
|
|
3221
|
+
this.http = new (0, _chunkWMULUP2Kjs.HttpClient)(this.config);
|
|
3222
3222
|
this.toolCalls = new ToolCalls(
|
|
3223
3223
|
this.http,
|
|
3224
3224
|
this.config.timeout,
|
|
@@ -1,6 +1,6 @@
|
|
|
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 _chunkCG5JEYRXjs = require('./chunk-CG5JEYRX.js');
|
|
4
4
|
|
|
5
5
|
// src/cli/npm-script-policy.ts
|
|
6
6
|
var _child_process = require('child_process');
|
|
@@ -13,7 +13,7 @@ function npmSupportsAllowScripts(version) {
|
|
|
13
13
|
}
|
|
14
14
|
function readNpmVersion(env) {
|
|
15
15
|
try {
|
|
16
|
-
const plan =
|
|
16
|
+
const plan = _chunkCG5JEYRXjs.resolveShellSpawn.call(void 0, "npm", ["--version"], process.platform, env);
|
|
17
17
|
const result = _child_process.spawnSync.call(void 0, plan.command, plan.args, {
|
|
18
18
|
encoding: "utf8",
|
|
19
19
|
env,
|