deepline 0.3.579 → 0.3.580
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/client-core.ts +13 -2
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/shared_libs/monitors/billing/public-pricing.ts +470 -15
- package/dist/bundling-sources/shared_libs/monitors/billing/tamradar.ts +12 -0
- package/dist/bundling-sources/shared_libs/monitors/billing/types.ts +59 -0
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-capability.ts +5 -3
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +139 -16
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/run-ledger-outbox-recovery.ts +39 -2
- package/dist/cli/{agents-D5RZEVXQ.js → agents-BF5VX5ZB.js} +31 -31
- package/dist/cli/{agents-FJTRTYCL.mjs → agents-JRFTZE7G.mjs} +4 -4
- package/dist/cli/auth-25MVD7TK.js +44 -0
- package/dist/cli/{auth-OMYIDVXZ.mjs → auth-XJXZ64R4.mjs} +5 -5
- package/dist/cli/{billing-XK3LBNYS.mjs → billing-TXJBGP2I.mjs} +67 -64
- package/dist/cli/{billing-EWFUDLQ7.js → billing-VGMTJI7W.js} +156 -153
- package/dist/cli/{chunk-TVAFWAOQ.js → chunk-2ZCFAUCV.js} +3 -3
- package/dist/cli/{chunk-HEZW2IDK.js → chunk-3OSNEWGR.js} +279 -276
- package/dist/cli/{chunk-TFNDOH4W.mjs → chunk-3P4QZIJ5.mjs} +1 -1
- package/dist/cli/{chunk-QA55PGJH.js → chunk-3S5KFHQH.js} +7 -7
- package/dist/cli/{chunk-6DMGKAWO.mjs → chunk-3ZBPXNSW.mjs} +2 -2
- package/dist/cli/{chunk-27ZYRIQC.mjs → chunk-5BPJW6X5.mjs} +5 -5
- package/dist/cli/{chunk-6MIEJJSO.js → chunk-6VSUP4WN.js} +4 -4
- package/dist/cli/{chunk-6GON36H3.mjs → chunk-7HOG3JZE.mjs} +17 -14
- package/dist/cli/{chunk-JFS4KHA3.mjs → chunk-7ORX33JX.mjs} +5 -5
- package/dist/cli/{chunk-NWZU6HL4.js → chunk-ANX3PYLT.js} +13 -13
- package/dist/cli/{chunk-FKXSIIR4.js → chunk-APJ7IPRT.js} +15 -15
- package/dist/cli/{chunk-44NTNNKC.js → chunk-AZTQJJH7.js} +6 -0
- package/dist/cli/{chunk-WQQQP3FH.mjs → chunk-BAXLPQTM.mjs} +4 -4
- package/dist/cli/{chunk-M4YWN5BT.mjs → chunk-BK4Z62CF.mjs} +4 -4
- package/dist/cli/{chunk-KQAEXBVQ.mjs → chunk-C6YXUGX2.mjs} +3 -3
- package/dist/cli/{chunk-PLWZ3NB7.js → chunk-COAAKSFX.js} +5 -5
- package/dist/cli/{chunk-LCPJR3IY.js → chunk-D6I7QWOZ.js} +2 -2
- package/dist/cli/{chunk-LQ45LCH7.js → chunk-DQEHBAHL.js} +9 -9
- package/dist/cli/{chunk-6EVVUVU3.mjs → chunk-EI7KTESB.mjs} +2 -2
- package/dist/cli/{chunk-F57NDSKT.mjs → chunk-FCJJPEKN.mjs} +5 -5
- package/dist/cli/{chunk-7JMCRYXU.js → chunk-GDBNH57Z.js} +10 -10
- package/dist/cli/{chunk-NONMY5CY.mjs → chunk-GE4ZEMMA.mjs} +2 -2
- package/dist/cli/{chunk-6NYHMXC7.mjs → chunk-GIZIWNL5.mjs} +1 -1
- package/dist/cli/{chunk-SZIWFQI2.mjs → chunk-H3B6QM6V.mjs} +3 -3
- package/dist/cli/{chunk-NKUXW4WB.js → chunk-HEZ24K5F.js} +2 -2
- package/dist/cli/{chunk-LV2LGW2Q.mjs → chunk-HLMF53HZ.mjs} +1 -1
- package/dist/cli/{chunk-S2OXA7QS.mjs → chunk-IERWFFDB.mjs} +7 -7
- package/dist/cli/{chunk-I2TSRLOI.mjs → chunk-IG3CXIJY.mjs} +1 -1
- package/dist/cli/{chunk-OSRATALX.mjs → chunk-IM322G7M.mjs} +1 -1
- package/dist/cli/{chunk-VFIIRK7S.mjs → chunk-KLBIHDZB.mjs} +2 -2
- package/dist/cli/{chunk-N6X2UKYQ.mjs → chunk-LC4ETCOA.mjs} +2 -2
- package/dist/cli/{chunk-G5CZDRY3.js → chunk-LHV3HPAY.js} +26 -26
- package/dist/cli/{chunk-NOMO5GPI.js → chunk-MBOPKQJF.js} +1 -1
- package/dist/cli/{chunk-BLEYV4BJ.js → chunk-MCYZO3RB.js} +21 -21
- package/dist/cli/{chunk-X6LPC3SU.mjs → chunk-MEDA3STC.mjs} +1 -1
- package/dist/cli/{chunk-PGRRMVQ5.js → chunk-MOZDEYQC.js} +2 -1
- package/dist/cli/{chunk-XQYBBCFI.mjs → chunk-MP6XUVAJ.mjs} +2 -2
- package/dist/cli/{chunk-OOGP737I.js → chunk-NNWEQDZR.js} +20 -20
- package/dist/cli/{chunk-HGUFTSB5.mjs → chunk-NV5IJ3NY.mjs} +6 -0
- package/dist/cli/{chunk-LYBZLA6F.mjs → chunk-O7AWGIDD.mjs} +2 -2
- package/dist/cli/{chunk-WWSGXX6U.js → chunk-PFNYLTCZ.js} +5 -5
- package/dist/cli/{chunk-BZ4M7OFO.mjs → chunk-QXQBTTRD.mjs} +1 -1
- package/dist/cli/{chunk-XTM6NOJ6.js → chunk-R77IVVEZ.js} +53 -53
- package/dist/cli/{chunk-Q4VKMF3B.js → chunk-S2YKIWCD.js} +17 -17
- package/dist/cli/{chunk-DTQBQSUU.mjs → chunk-SECFDB27.mjs} +1 -0
- package/dist/cli/{chunk-KIIOKQFY.mjs → chunk-SQBSK74D.mjs} +7 -3
- package/dist/cli/{chunk-AP7PIGL5.js → chunk-TSOXJZSW.js} +41 -41
- package/dist/cli/{chunk-YCWRKSLB.mjs → chunk-U4VCAECC.mjs} +2 -2
- package/dist/cli/{chunk-KWQHQG53.js → chunk-URZPR54R.js} +6 -6
- package/dist/cli/{chunk-ABH6PUDZ.js → chunk-V5NDHTBB.js} +23 -23
- package/dist/cli/{chunk-SUHCW7U5.mjs → chunk-VF3EGTHU.mjs} +3 -3
- package/dist/cli/{chunk-DH736ASH.js → chunk-VOQWPUIF.js} +20 -20
- package/dist/cli/{chunk-7HOYKXVY.js → chunk-WJUAVMQC.js} +217 -213
- package/dist/cli/{chunk-3Z4TVZE7.mjs → chunk-X5RXG6VS.mjs} +1 -1
- package/dist/cli/{chunk-UYCBG75H.js → chunk-XFVJ3JNA.js} +5 -5
- package/dist/cli/{chunk-LYJ2NSHD.js → chunk-XQUVLYOL.js} +13 -13
- package/dist/cli/{chunk-K2BU67UC.js → chunk-YY6EB252.js} +2 -2
- package/dist/cli/{chunk-Y2ND6PPW.js → chunk-Z6DERGHY.js} +48 -48
- package/dist/cli/{chunk-72TWLORR.js → chunk-ZADJC22U.js} +3 -3
- package/dist/cli/{chunk-7SZCJC4R.mjs → chunk-ZR7PDXIA.mjs} +2 -2
- package/dist/cli/command-docs.js +2 -2
- package/dist/cli/command-docs.mjs +1 -1
- package/dist/cli/concurrent-runs-help-DEN63DUM.js +22 -0
- package/dist/cli/{concurrent-runs-help-IQBZBTD5.mjs → concurrent-runs-help-DSUQRWZQ.mjs} +6 -6
- package/dist/cli/{csv-T7TWLIGD.js → csv-HSHF6JYZ.js} +13 -13
- package/dist/cli/{csv-6BEOWTGM.mjs → csv-QNXJBT5T.mjs} +4 -4
- package/dist/cli/{db-FA5QGXZ7.mjs → db-RAWY3SWS.mjs} +6 -6
- package/dist/cli/{db-MFTUN3DF.js → db-VHYWVLLU.js} +27 -27
- package/dist/cli/{describe-TITEQNVE.mjs → describe-WZOVHWAM.mjs} +21 -21
- package/dist/cli/describe-YHZ2EGBQ.js +50 -0
- package/dist/cli/describe-core.d.mts +2 -2
- package/dist/cli/describe-core.d.ts +2 -2
- package/dist/cli/describe-core.js +4 -4
- package/dist/cli/describe-core.mjs +3 -3
- package/dist/cli/{executions-QW3L7G7J.js → executions-DQIFH4Z6.js} +8 -8
- package/dist/cli/{executions-DMYJJIRB.mjs → executions-QABOXV4K.mjs} +6 -6
- package/dist/cli/{feedback-6JZGE7OQ.js → feedback-6IER2W4G.js} +14 -14
- package/dist/cli/{feedback-WPSNSFRC.mjs → feedback-DW4O63DG.mjs} +6 -6
- package/dist/cli/{git-GO65XRM3.mjs → git-3NAPGZGR.mjs} +5 -5
- package/dist/cli/git-SQ2MAKAH.js +26 -0
- package/dist/cli/index.js +148 -148
- package/dist/cli/index.mjs +47 -47
- package/dist/cli/{integrations-T5JPSZXN.js → integrations-5LHIBBXB.js} +29 -29
- package/dist/cli/{integrations-EEBPETH2.mjs → integrations-TSRUTENK.mjs} +7 -7
- package/dist/cli/{legacy-noops-XDNZ46IR.mjs → legacy-noops-4N63A6H7.mjs} +6 -6
- package/dist/cli/{legacy-noops-B55OMNH7.js → legacy-noops-S22XGYGN.js} +9 -9
- package/dist/cli/{mcp-4QIUAAWS.mjs → mcp-4EJHRRFV.mjs} +4 -4
- package/dist/cli/{mcp-3YA333TQ.js → mcp-JERBGJYE.js} +24 -24
- package/dist/cli/{monitors-BVUPS4CE.mjs → monitors-7BTLBD6S.mjs} +16 -11
- package/dist/cli/{monitors-FOS7MWZO.js → monitors-FF35CGC4.js} +109 -104
- package/dist/cli/{org-CYM7HFLN.js → org-ADCDO7KU.js} +121 -121
- package/dist/cli/{org-TCMRRVFC.mjs → org-QYIIBKA2.mjs} +6 -6
- package/dist/cli/{outcomes-VDJVP5YC.js → outcomes-2LW4GK2L.js} +14 -14
- package/dist/cli/{outcomes-2JSWXWQ3.mjs → outcomes-C5DIBG4Q.mjs} +6 -6
- package/dist/cli/{play-CPP4EBYF.mjs → play-DTTDTISL.mjs} +20 -20
- package/dist/cli/{play-U3G73VIR.js → play-S5MZ2GRA.js} +349 -349
- package/dist/cli/{providers-RVMIX5ED.mjs → providers-AXOEFQ6Q.mjs} +6 -6
- package/dist/cli/{providers-2ZB67TK7.js → providers-N2IWEJBW.js} +9 -9
- package/dist/cli/{quickstart-L3YO3OWZ.mjs → quickstart-ADWSZBV6.mjs} +4 -4
- package/dist/cli/{quickstart-V3Y7XZ47.js → quickstart-UC5AJZWU.js} +6 -6
- package/dist/cli/{run-M2CADJ6E.js → run-6TDYUL7L.js} +48 -48
- package/dist/cli/{run-PQ3Z2GOF.mjs → run-R2FVH3K6.mjs} +26 -26
- package/dist/cli/{search-QVLGI7SZ.mjs → search-GRHUFSLY.mjs} +7 -7
- package/dist/cli/search-V7ANBX3J.js +32 -0
- package/dist/cli/{search-output-IUANVHWU.js → search-output-O7NY3VMD.js} +8 -8
- package/dist/cli/{search-output-PN3V7MSO.mjs → search-output-UPQNAFAF.mjs} +5 -5
- package/dist/cli/{secrets-AOW6F67J.js → secrets-72GJHFER.js} +15 -15
- package/dist/cli/{secrets-HK25G4K2.mjs → secrets-NKAEJLIQ.mjs} +6 -6
- package/dist/cli/sessions-EO6RTMUC.js +23 -0
- package/dist/cli/{sessions-YN2OIAGR.mjs → sessions-VIMF3UF5.mjs} +6 -6
- package/dist/cli/{settings-6EV2FPGF.js → settings-HFAW5HIF.js} +85 -85
- package/dist/cli/{settings-7UW5TWSM.mjs → settings-KCQHBFNZ.mjs} +12 -12
- package/dist/cli/{setup-ZQPD2R5K.js → setup-2MHWGEAD.js} +49 -49
- package/dist/cli/{setup-BG56SHKH.mjs → setup-2ZD5ZIUH.mjs} +9 -9
- package/dist/cli/skills-ID6KKDLH.js +37 -0
- package/dist/cli/{skills-MQV2TNUZ.mjs → skills-X2DZZG5P.mjs} +7 -7
- package/dist/cli/tools-7UY7GERW.js +57 -0
- package/dist/cli/{tools-RGI4OE5T.mjs → tools-KPTOWKD4.mjs} +19 -19
- package/dist/cli/{update-SQKGHQKF.mjs → update-6PMQCEUP.mjs} +9 -9
- package/dist/cli/update-T2RDLLSY.js +37 -0
- package/dist/cli/{views-BUKVHCRD.js → views-MNBHNO6C.js} +37 -24
- package/dist/cli/{views-734T2CXF.mjs → views-VRZ5CTFL.mjs} +21 -8
- package/dist/cli/{workflow-JNRRBMEK.mjs → workflow-7JUJWA5S.mjs} +7 -7
- package/dist/cli/{workflow-LPJC6RHP.js → workflow-SSMFO7YE.js} +17 -17
- package/dist/{client-CNYctEBh.d.mts → client-CmG8MT0x.d.mts} +1 -1
- package/dist/{client-C1AubrWJ.d.ts → client-QznpkWrk.d.ts} +1 -1
- package/dist/{client-core-D6zAE46g.d.ts → client-core-CXDqfeiB.d.ts} +5 -1
- package/dist/{client-core-Bb06TCx5.d.mts → client-core-CY0jNW0e.d.mts} +5 -1
- package/dist/index.d.mts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +9 -9
- package/dist/index.mjs +6 -6
- package/dist/install-integrity.json +126 -126
- package/dist/plays/play-description.d.mts +1 -1
- package/dist/plays/play-description.d.ts +1 -1
- package/dist/plays/run-request.d.mts +1 -1
- package/dist/plays/run-request.d.ts +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/dist/server.d.mts +2 -2
- package/dist/server.d.ts +2 -2
- package/dist/server.js +5 -5
- package/dist/server.mjs +3 -3
- package/package.json +1 -1
- package/dist/cli/auth-Q4O7MJU4.js +0 -44
- package/dist/cli/concurrent-runs-help-D6XH3FY5.js +0 -22
- package/dist/cli/describe-TYZ5YH3V.js +0 -50
- package/dist/cli/git-UGGRLGTQ.js +0 -26
- package/dist/cli/search-RHPPZZFG.js +0 -32
- package/dist/cli/sessions-AEGGTZ3K.js +0 -23
- package/dist/cli/skills-C6ZEZWBE.js +0 -37
- package/dist/cli/tools-PM3MC3RR.js +0 -57
- package/dist/cli/update-ZHUPF2HT.js +0 -37
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunk3S5KFHQHjs = require('./chunk-3S5KFHQH.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
@@ -13,7 +13,7 @@ var _chunkQA55PGJHjs = require('./chunk-QA55PGJH.js');
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunkMOZDEYQCjs = require('./chunk-MOZDEYQC.js');
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
var _chunkLFQJW4S2js = require('./chunk-LFQJW4S2.js');
|
|
@@ -31,13 +31,13 @@ var VIEWS = {
|
|
|
31
31
|
details: model,
|
|
32
32
|
lines: [
|
|
33
33
|
...unlisted,
|
|
34
|
-
...
|
|
34
|
+
..._chunk3S5KFHQHjs.formatModelDescription.call(void 0, model).trimEnd().split("\n")
|
|
35
35
|
]
|
|
36
36
|
};
|
|
37
37
|
},
|
|
38
38
|
byok: async (_value, tool) => ({
|
|
39
39
|
details: _nullishCoalesce(tool.byok, () => ( {})),
|
|
40
|
-
lines:
|
|
40
|
+
lines: _chunkMOZDEYQCjs.byokLines.call(void 0, _nullishCoalesce(tool.byok, () => ( {})))
|
|
41
41
|
})
|
|
42
42
|
};
|
|
43
43
|
var isFeatureView = (value) => typeof value === "string" && Object.hasOwn(VIEWS, value);
|
|
@@ -133,7 +133,7 @@ async function findNamed(reference, options, lookups) {
|
|
|
133
133
|
const record = await lookups.play(reference2);
|
|
134
134
|
if (!record) return null;
|
|
135
135
|
return {
|
|
136
|
-
described:
|
|
136
|
+
described: _chunkMOZDEYQCjs.describedPlay.call(void 0, record),
|
|
137
137
|
record: { ...record },
|
|
138
138
|
schemas: {
|
|
139
139
|
inputSchema: _nullishCoalesce(record.inputSchema, () => ( null)),
|
|
@@ -153,15 +153,15 @@ async function findNamed(reference, options, lookups) {
|
|
|
153
153
|
const features = toolFeatures(record);
|
|
154
154
|
return {
|
|
155
155
|
described: {
|
|
156
|
-
...
|
|
156
|
+
..._chunk3S5KFHQHjs.describedTool.call(void 0, record, name),
|
|
157
157
|
...features.length ? { features: features.map(({ view: _view, ...feature }) => feature) } : {}
|
|
158
158
|
},
|
|
159
|
-
record:
|
|
159
|
+
record: _chunk3S5KFHQHjs.toolMetadataJsonForDescribe.call(void 0,
|
|
160
160
|
record,
|
|
161
161
|
name,
|
|
162
162
|
lookups.seedStarterScript
|
|
163
163
|
),
|
|
164
|
-
schemas:
|
|
164
|
+
schemas: _chunk3S5KFHQHjs.publicToolSchemas.call(void 0, record),
|
|
165
165
|
feature: (featureName, value) => {
|
|
166
166
|
const feature = features.find(({ name: name2 }) => name2 === featureName);
|
|
167
167
|
return feature ? describeFeature(record, feature, value, {
|
|
@@ -208,7 +208,7 @@ async function describeName(name, options, lookups) {
|
|
|
208
208
|
const note = shadows ? `Showing your org play "${name}". It has the same name as a Deepline ${shadows.kind.replace("_", " ")}; see that one with: ${shadows.describeCommand}` : null;
|
|
209
209
|
const verbose = options.verbose === true;
|
|
210
210
|
const isPlay = described.kind === "prebuilt_play" || described.kind === "custom_play";
|
|
211
|
-
const dashboardUrl = isPlay ?
|
|
211
|
+
const dashboardUrl = isPlay ? _chunkMOZDEYQCjs.buildPlayDashboardUrl.call(void 0,
|
|
212
212
|
lookups.baseUrl,
|
|
213
213
|
described.id,
|
|
214
214
|
lookups.dashboardOrgId
|
|
@@ -276,7 +276,7 @@ async function describeName(name, options, lookups) {
|
|
|
276
276
|
},
|
|
277
277
|
lines: [
|
|
278
278
|
`${described.id} [${described.kind.replace("_", " ")}]`,
|
|
279
|
-
...
|
|
279
|
+
..._chunkMOZDEYQCjs.schemaLines.call(void 0, described, {
|
|
280
280
|
full: true,
|
|
281
281
|
secondary: true,
|
|
282
282
|
...fields.length ? { fields } : {}
|
|
@@ -285,17 +285,17 @@ async function describeName(name, options, lookups) {
|
|
|
285
285
|
} : {
|
|
286
286
|
envelope: {
|
|
287
287
|
...summary,
|
|
288
|
-
inputs: inputs.map(
|
|
289
|
-
outputs: outputs.map(
|
|
290
|
-
...described.rowInputs ? { rowInputs: described.rowInputs.map(
|
|
291
|
-
...described.rowOutputs ? { rowOutputs: described.rowOutputs.map(
|
|
292
|
-
runExamples:
|
|
288
|
+
inputs: inputs.map(_chunkMOZDEYQCjs.topLevelField),
|
|
289
|
+
outputs: outputs.map(_chunkMOZDEYQCjs.topLevelField),
|
|
290
|
+
...described.rowInputs ? { rowInputs: described.rowInputs.map(_chunkMOZDEYQCjs.topLevelField) } : {},
|
|
291
|
+
...described.rowOutputs ? { rowOutputs: described.rowOutputs.map(_chunkMOZDEYQCjs.topLevelField) } : {},
|
|
292
|
+
runExamples: _chunkMOZDEYQCjs.examples.call(void 0, described, { verbose }),
|
|
293
293
|
...dashboardUrl ? { dashboardUrl } : {},
|
|
294
294
|
...shadows ? { shadows, note } : {}
|
|
295
295
|
},
|
|
296
296
|
lines: [
|
|
297
297
|
...note ? [`Note: ${note}`, ""] : [],
|
|
298
|
-
...
|
|
298
|
+
..._chunkMOZDEYQCjs.describedLines.call(void 0, described, {
|
|
299
299
|
cli: shown && (!named || options.cliExample === true),
|
|
300
300
|
play: shown && (!named || options.playExample === true),
|
|
301
301
|
explain: named,
|
|
@@ -312,7 +312,7 @@ async function describeName(name, options, lookups) {
|
|
|
312
312
|
// its value stands, so callers of the older commands read what they did.
|
|
313
313
|
{ ...view.envelope, ...record }
|
|
314
314
|
) : {
|
|
315
|
-
...
|
|
315
|
+
..._chunkMOZDEYQCjs.describedJson.call(void 0, described, {
|
|
316
316
|
secondary: verbose || fields.length > 0,
|
|
317
317
|
verbose
|
|
318
318
|
}),
|
|
@@ -37,7 +37,7 @@ import {
|
|
|
37
37
|
RETAINED_PIPELINE_RECEIVERS_HEADER,
|
|
38
38
|
RUNTIME_ENVIRONMENT_TOKEN_HEADER,
|
|
39
39
|
SDK_API_MAJOR
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-IG3CXIJY.mjs";
|
|
41
41
|
import {
|
|
42
42
|
CustomerDbQueryOutcomeUnknownError
|
|
43
43
|
} from "./chunk-ASB47RXJ.mjs";
|
|
@@ -4079,10 +4079,13 @@ var DeeplineClient = class _DeeplineClient {
|
|
|
4079
4079
|
);
|
|
4080
4080
|
}
|
|
4081
4081
|
/** Who can open a view: its workspace, every org member, or anyone with its URL. */
|
|
4082
|
-
async setViewAccess(id, access) {
|
|
4082
|
+
async setViewAccess(id, access, options) {
|
|
4083
4083
|
return await this.http.post(
|
|
4084
4084
|
`/api/v2/views/${encodeURIComponent(id)}/access`,
|
|
4085
|
-
{
|
|
4085
|
+
{
|
|
4086
|
+
access,
|
|
4087
|
+
...options?.embedOrigins !== void 0 ? { embed_origins: options.embedOrigins } : {}
|
|
4088
|
+
}
|
|
4086
4089
|
);
|
|
4087
4090
|
}
|
|
4088
4091
|
/** The view's share links, newest first. Their tokens are never returned. */
|
|
@@ -7810,6 +7813,7 @@ export {
|
|
|
7810
7813
|
AD_ACCOUNT_DISCOVERY_PROVIDERS,
|
|
7811
7814
|
planAdAccountDiscovery,
|
|
7812
7815
|
PUBLIC_PLAN_SKUS,
|
|
7816
|
+
resolvePublicPlanSku,
|
|
7813
7817
|
iterateCursorPages,
|
|
7814
7818
|
requireBillingIdempotencyKey,
|
|
7815
7819
|
planCustomerDbQuery,
|
|
@@ -11,20 +11,20 @@
|
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _chunkZ6DERGHYjs = require('./chunk-Z6DERGHY.js');
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
var
|
|
17
|
+
var _chunkNNWEQDZRjs = require('./chunk-NNWEQDZR.js');
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
var
|
|
23
|
+
var _chunk2ZCFAUCVjs = require('./chunk-2ZCFAUCV.js');
|
|
24
24
|
|
|
25
25
|
|
|
26
26
|
|
|
27
|
-
var
|
|
27
|
+
var _chunk6VSUP4WNjs = require('./chunk-6VSUP4WN.js');
|
|
28
28
|
|
|
29
29
|
|
|
30
30
|
var _chunkRLX5ZFNXjs = require('./chunk-RLX5ZFNX.js');
|
|
@@ -145,7 +145,7 @@ function inferActiveSkillsScope(entrypoint = _nullishCoalesce(process.argv[1], (
|
|
|
145
145
|
return /[\\/]\.deepline[\\/]runtime[\\/]/.test(entrypoint) ? "local" : "global";
|
|
146
146
|
}
|
|
147
147
|
function resolveLocalRoot() {
|
|
148
|
-
const target =
|
|
148
|
+
const target = _chunk2ZCFAUCVjs.resolveProjectPinTarget.call(void 0, );
|
|
149
149
|
if (!target.ok) {
|
|
150
150
|
throw new Error(
|
|
151
151
|
`Cowork project folder is ambiguous. Candidate folders: ${target.candidates.join(
|
|
@@ -156,7 +156,7 @@ function resolveLocalRoot() {
|
|
|
156
156
|
return target.dir;
|
|
157
157
|
}
|
|
158
158
|
function detectSkillsAgents(input) {
|
|
159
|
-
const runtime = _nullishCoalesce(input.runtime, () => (
|
|
159
|
+
const runtime = _nullishCoalesce(input.runtime, () => ( _chunk6VSUP4WNjs.detectAgentRuntime.call(void 0, )));
|
|
160
160
|
const knownAgent = RUNTIME_TO_SKILLS_AGENT[runtime];
|
|
161
161
|
if (knownAgent) return [knownAgent];
|
|
162
162
|
const roots = [
|
|
@@ -171,11 +171,11 @@ function detectSkillsAgents(input) {
|
|
|
171
171
|
return detected.length > 0 ? detected : ["*"];
|
|
172
172
|
}
|
|
173
173
|
function skillsStatePathForScope(baseUrl, scope, root) {
|
|
174
|
-
return scope === "local" && root ? _path.join.call(void 0, root, ".deepline", "setup", "skills.json") : _path.join.call(void 0,
|
|
174
|
+
return scope === "local" && root ? _path.join.call(void 0, root, ".deepline", "setup", "skills.json") : _path.join.call(void 0, _chunk2ZCFAUCVjs.sdkCliStateDirPath.call(void 0, baseUrl), "skills-install.json");
|
|
175
175
|
}
|
|
176
176
|
function buildSkillsPlan(input) {
|
|
177
177
|
const scopeArgs = input.scope === "global" ? ["--global"] : [];
|
|
178
|
-
const legacyNames = [...
|
|
178
|
+
const legacyNames = [..._chunkZ6DERGHYjs.LEGACY_SKILL_NAMES_TO_REMOVE].sort(
|
|
179
179
|
(a, b) => a.localeCompare(b)
|
|
180
180
|
);
|
|
181
181
|
return {
|
|
@@ -189,7 +189,7 @@ function buildSkillsPlan(input) {
|
|
|
189
189
|
args: [
|
|
190
190
|
"exec",
|
|
191
191
|
"--yes",
|
|
192
|
-
`--package=${
|
|
192
|
+
`--package=${_chunkZ6DERGHYjs.SKILLS_NPX_PACKAGE}`,
|
|
193
193
|
"--",
|
|
194
194
|
"skills",
|
|
195
195
|
"remove",
|
|
@@ -205,11 +205,11 @@ function buildSkillsPlan(input) {
|
|
|
205
205
|
args: [
|
|
206
206
|
"exec",
|
|
207
207
|
"--yes",
|
|
208
|
-
`--package=${
|
|
208
|
+
`--package=${_chunkZ6DERGHYjs.SKILLS_NPX_PACKAGE}`,
|
|
209
209
|
"--",
|
|
210
210
|
"skills",
|
|
211
211
|
"add",
|
|
212
|
-
|
|
212
|
+
_chunkZ6DERGHYjs.skillsSourceUrl.call(void 0, input.baseUrl),
|
|
213
213
|
"--agent",
|
|
214
214
|
...input.agents,
|
|
215
215
|
...scopeArgs,
|
|
@@ -246,7 +246,7 @@ function readSkillsInstallState(path) {
|
|
|
246
246
|
}
|
|
247
247
|
function runProcess(command, args, cwd) {
|
|
248
248
|
return new Promise((resolve, reject) => {
|
|
249
|
-
const plan =
|
|
249
|
+
const plan = _chunkZ6DERGHYjs.resolveShellSpawn.call(void 0,
|
|
250
250
|
command,
|
|
251
251
|
args,
|
|
252
252
|
process.platform,
|
|
@@ -269,7 +269,7 @@ function runProcess(command, args, cwd) {
|
|
|
269
269
|
child.kill("SIGTERM");
|
|
270
270
|
reject(
|
|
271
271
|
new Error(
|
|
272
|
-
`${
|
|
272
|
+
`${_chunkZ6DERGHYjs.SKILLS_NPX_PACKAGE} timed out after ${SKILLS_PROCESS_TIMEOUT_MS}ms.`
|
|
273
273
|
)
|
|
274
274
|
);
|
|
275
275
|
}, SKILLS_PROCESS_TIMEOUT_MS);
|
|
@@ -280,7 +280,7 @@ function runProcess(command, args, cwd) {
|
|
|
280
280
|
child.once("close", (code) => {
|
|
281
281
|
clearTimeout(timeout);
|
|
282
282
|
if (code && stderr.trim()) {
|
|
283
|
-
process.stderr.write(`${
|
|
283
|
+
process.stderr.write(`${_chunkZ6DERGHYjs.SKILLS_NPX_PACKAGE} exited ${code}.
|
|
284
284
|
`);
|
|
285
285
|
}
|
|
286
286
|
resolve(_nullishCoalesce(code, () => ( 1)));
|
|
@@ -288,7 +288,7 @@ function runProcess(command, args, cwd) {
|
|
|
288
288
|
});
|
|
289
289
|
}
|
|
290
290
|
async function showSkills(options, name) {
|
|
291
|
-
const baseUrl =
|
|
291
|
+
const baseUrl = _chunk2ZCFAUCVjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
292
292
|
const url = name ? `${baseUrl}/.well-known/skills/${encodeURIComponent(name)}/SKILL.md` : `${baseUrl}/.well-known/skills/index.json`;
|
|
293
293
|
try {
|
|
294
294
|
const response = await fetch(url, {
|
|
@@ -301,7 +301,7 @@ async function showSkills(options, name) {
|
|
|
301
301
|
}
|
|
302
302
|
if (name) {
|
|
303
303
|
const markdown = await response.text();
|
|
304
|
-
|
|
304
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
305
305
|
{ ok: true, status: "completed", skill: { name, markdown } },
|
|
306
306
|
{ json: options.json, text: markdown }
|
|
307
307
|
);
|
|
@@ -311,7 +311,7 @@ async function showSkills(options, name) {
|
|
|
311
311
|
const skills = (_nullishCoalesce(index.skills, () => ( []))).filter(
|
|
312
312
|
(skill) => skill.install_surface === "v1" && skill.name
|
|
313
313
|
);
|
|
314
|
-
|
|
314
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
315
315
|
{
|
|
316
316
|
ok: true,
|
|
317
317
|
status: "completed",
|
|
@@ -328,7 +328,7 @@ Read one with: deepline skills show <name>
|
|
|
328
328
|
);
|
|
329
329
|
return 0;
|
|
330
330
|
} catch (error) {
|
|
331
|
-
|
|
331
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
332
332
|
{
|
|
333
333
|
ok: false,
|
|
334
334
|
status: "failed",
|
|
@@ -351,7 +351,7 @@ async function runSkillsCommand(options, dependencies = {}) {
|
|
|
351
351
|
scope = normalizeScope(options.scope);
|
|
352
352
|
root = scope === "local" ? resolveLocalRoot() : null;
|
|
353
353
|
} catch (error) {
|
|
354
|
-
|
|
354
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
355
355
|
{
|
|
356
356
|
ok: false,
|
|
357
357
|
status: "failed",
|
|
@@ -363,22 +363,22 @@ async function runSkillsCommand(options, dependencies = {}) {
|
|
|
363
363
|
);
|
|
364
364
|
return 2;
|
|
365
365
|
}
|
|
366
|
-
const baseUrl =
|
|
366
|
+
const baseUrl = _chunk2ZCFAUCVjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
367
367
|
const catalog = {
|
|
368
|
-
skillNames: [...
|
|
369
|
-
version:
|
|
368
|
+
skillNames: [..._chunkZ6DERGHYjs.DEFAULT_SDK_SKILL_NAMES],
|
|
369
|
+
version: _chunk6VSUP4WNjs.SDK_VERSION
|
|
370
370
|
};
|
|
371
371
|
const agents = options.agent ? [options.agent] : detectSkillsAgents({ scope, root });
|
|
372
372
|
const plan = buildSkillsPlan({ baseUrl, scope, root, agents, ...catalog });
|
|
373
373
|
if (options.dryRun) {
|
|
374
|
-
|
|
374
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
375
375
|
{ ok: true, status: "planned", dryRun: true, ...plan },
|
|
376
376
|
{ json: options.json }
|
|
377
377
|
);
|
|
378
378
|
return 0;
|
|
379
379
|
}
|
|
380
|
-
if (isSkillsPlanCurrent(plan, readSkillsInstallState(plan.statePath)) && !
|
|
381
|
-
|
|
380
|
+
if (isSkillsPlanCurrent(plan, readSkillsInstallState(plan.statePath)) && !_chunkZ6DERGHYjs.hasFailedAutomaticSkillsSync.call(void 0, baseUrl, agents)) {
|
|
381
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
382
382
|
{
|
|
383
383
|
ok: true,
|
|
384
384
|
status: "current",
|
|
@@ -410,10 +410,10 @@ async function runSkillsCommand(options, dependencies = {}) {
|
|
|
410
410
|
}
|
|
411
411
|
if (scope === "local" && root) {
|
|
412
412
|
const managedNames = [
|
|
413
|
-
.../* @__PURE__ */ new Set([...plan.skillNames, ...
|
|
413
|
+
.../* @__PURE__ */ new Set([...plan.skillNames, ..._chunkZ6DERGHYjs.LEGACY_SKILL_NAMES_TO_REMOVE])
|
|
414
414
|
];
|
|
415
415
|
const agentRoots = workspaceSkillRootsForAgents(plan.agents);
|
|
416
|
-
|
|
416
|
+
_chunk2ZCFAUCVjs.ensureProjectPrivatePathsIgnored.call(void 0, root, [
|
|
417
417
|
".deepline/",
|
|
418
418
|
...agentRoots.flatMap(
|
|
419
419
|
(agentRoot) => managedNames.map((name) => `${agentRoot}/skills/${name}/`)
|
|
@@ -422,7 +422,7 @@ async function runSkillsCommand(options, dependencies = {}) {
|
|
|
422
422
|
}
|
|
423
423
|
let lease;
|
|
424
424
|
try {
|
|
425
|
-
lease = scope === "global" ? await
|
|
425
|
+
lease = scope === "global" ? await _chunkZ6DERGHYjs.acquireSkillsInstallLease.call(void 0, baseUrl, agents, plan.version, {
|
|
426
426
|
waitMs: _nullishCoalesce(dependencies.installLeaseWaitMs, () => ( SKILLS_INSTALL_LEASE_WAIT_MS)),
|
|
427
427
|
onWait: () => process.stderr.write(
|
|
428
428
|
"Waiting for a background Deepline skills refresh to finish...\n"
|
|
@@ -430,8 +430,8 @@ async function runSkillsCommand(options, dependencies = {}) {
|
|
|
430
430
|
}) : { release: () => {
|
|
431
431
|
} };
|
|
432
432
|
} catch (error) {
|
|
433
|
-
if (!(error instanceof
|
|
434
|
-
|
|
433
|
+
if (!(error instanceof _chunkZ6DERGHYjs.SkillsStateUnavailableError)) throw error;
|
|
434
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
435
435
|
{
|
|
436
436
|
ok: false,
|
|
437
437
|
status: "failed",
|
|
@@ -447,7 +447,7 @@ async function runSkillsCommand(options, dependencies = {}) {
|
|
|
447
447
|
return 5;
|
|
448
448
|
}
|
|
449
449
|
if (!lease) {
|
|
450
|
-
|
|
450
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
451
451
|
{
|
|
452
452
|
ok: false,
|
|
453
453
|
status: "failed",
|
|
@@ -456,7 +456,7 @@ async function runSkillsCommand(options, dependencies = {}) {
|
|
|
456
456
|
scope,
|
|
457
457
|
agents,
|
|
458
458
|
message: "A background Deepline skills refresh is still running for these agents.",
|
|
459
|
-
next: `Retry in a moment: deepline skills install --scope ${scope}. If no refresh is running, remove ${
|
|
459
|
+
next: `Retry in a moment: deepline skills install --scope ${scope}. If no refresh is running, remove ${_chunkZ6DERGHYjs.skillsInstallLeasePath.call(void 0, baseUrl, agents)}`
|
|
460
460
|
},
|
|
461
461
|
{ json: options.json }
|
|
462
462
|
);
|
|
@@ -505,7 +505,7 @@ async function runSkillsInstallWithLease(input) {
|
|
|
505
505
|
}
|
|
506
506
|
}
|
|
507
507
|
} catch (error) {
|
|
508
|
-
|
|
508
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
509
509
|
{
|
|
510
510
|
ok: false,
|
|
511
511
|
status: "failed",
|
|
@@ -521,7 +521,7 @@ async function runSkillsInstallWithLease(input) {
|
|
|
521
521
|
return 5;
|
|
522
522
|
}
|
|
523
523
|
if (missing.length > 0) {
|
|
524
|
-
|
|
524
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
525
525
|
{
|
|
526
526
|
ok: false,
|
|
527
527
|
status: "failed",
|
|
@@ -561,7 +561,7 @@ async function runSkillsInstallWithLease(input) {
|
|
|
561
561
|
{
|
|
562
562
|
schemaVersion: 1,
|
|
563
563
|
installedAt: (/* @__PURE__ */ new Date()).toISOString(),
|
|
564
|
-
cliVersion:
|
|
564
|
+
cliVersion: _chunk6VSUP4WNjs.SDK_VERSION,
|
|
565
565
|
scope,
|
|
566
566
|
agents,
|
|
567
567
|
skillsVersion: plan.version,
|
|
@@ -574,9 +574,9 @@ async function runSkillsInstallWithLease(input) {
|
|
|
574
574
|
"utf8"
|
|
575
575
|
);
|
|
576
576
|
if (scope === "global") {
|
|
577
|
-
|
|
577
|
+
_chunkZ6DERGHYjs.clearFailedAutomaticSkillsSync.call(void 0, baseUrl, agents);
|
|
578
578
|
}
|
|
579
|
-
|
|
579
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
580
580
|
{
|
|
581
581
|
ok: true,
|
|
582
582
|
status: "complete",
|
|
@@ -625,7 +625,7 @@ Examples:
|
|
|
625
625
|
"after",
|
|
626
626
|
`
|
|
627
627
|
Notes:
|
|
628
|
-
This command reinstalls current Deepline-managed skills using ${
|
|
628
|
+
This command reinstalls current Deepline-managed skills using ${_chunkZ6DERGHYjs.SKILLS_NPX_PACKAGE},
|
|
629
629
|
then removes legacy Deepline skill names. Local scope writes into the resolved
|
|
630
630
|
persistent project.
|
|
631
631
|
|
|
@@ -637,13 +637,13 @@ Examples:
|
|
|
637
637
|
).action(async (options) => {
|
|
638
638
|
process.exitCode = await runSkillsCommand(options);
|
|
639
639
|
});
|
|
640
|
-
program.command(
|
|
640
|
+
program.command(_chunkZ6DERGHYjs.SKILLS_AUTO_SYNC_COMMAND, { hidden: true }).description("Refresh Deepline agent skills in the background.").option(
|
|
641
641
|
"--claim <token>",
|
|
642
642
|
"Owner token of the leases this child was started for."
|
|
643
643
|
).action(async (options) => {
|
|
644
644
|
const claim = _optionalChain([options, 'access', _9 => _9.claim, 'optionalAccess', _10 => _10.trim, 'call', _11 => _11()]);
|
|
645
645
|
if (!claim) {
|
|
646
|
-
|
|
646
|
+
_chunkNNWEQDZRjs.printCommandEnvelope.call(void 0,
|
|
647
647
|
{
|
|
648
648
|
ok: false,
|
|
649
649
|
status: "failed",
|
|
@@ -656,7 +656,7 @@ Examples:
|
|
|
656
656
|
process.exitCode = 2;
|
|
657
657
|
return;
|
|
658
658
|
}
|
|
659
|
-
await
|
|
659
|
+
await _chunkZ6DERGHYjs.syncSdkSkillsIfNeeded.call(void 0, _chunk2ZCFAUCVjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, ""), {
|
|
660
660
|
mode: "inline",
|
|
661
661
|
notices: "defer",
|
|
662
662
|
claim
|
|
@@ -3,14 +3,14 @@ import {
|
|
|
3
3
|
credentialSourceText,
|
|
4
4
|
fieldBlockLines,
|
|
5
5
|
schemaFields
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-SECFDB27.mjs";
|
|
7
7
|
import {
|
|
8
8
|
csvSafeJsonString,
|
|
9
9
|
csvStringFromRows,
|
|
10
10
|
formatCliFailureDiagnostic,
|
|
11
11
|
markJsonOutputHandled,
|
|
12
12
|
writeRawStderr
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-3ZBPXNSW.mjs";
|
|
14
14
|
|
|
15
15
|
// src/cli/describe-options.ts
|
|
16
16
|
function addDescribeOptions(command, options = {}) {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); 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 _chunkHEZ24K5Fjs = require('./chunk-HEZ24K5F.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkZ6DERGHYjs = require('./chunk-Z6DERGHY.js');
|
|
9
9
|
|
|
10
10
|
// src/cli/play-run-admission.ts
|
|
11
11
|
function usesInlinePlayAdmission(command, args) {
|
|
@@ -18,18 +18,18 @@ function usesCliPlayAdmission(command, args) {
|
|
|
18
18
|
}
|
|
19
19
|
async function checkPlayRunCompatibility(baseUrl, maintenancePolicy = "configured", signal) {
|
|
20
20
|
_optionalChain([signal, 'optionalAccess', _ => _.throwIfAborted, 'call', _2 => _2()]);
|
|
21
|
-
if (maintenancePolicy !== "off")
|
|
22
|
-
const compatibility = await
|
|
21
|
+
if (maintenancePolicy !== "off") _chunkZ6DERGHYjs.flushDeferredSkillsSyncNotices.call(void 0, baseUrl);
|
|
22
|
+
const compatibility = await _chunkHEZ24K5Fjs.traceCliSpan.call(void 0,
|
|
23
23
|
"cli.sdk_compatibility",
|
|
24
24
|
{ baseUrl, command: "plays run" },
|
|
25
|
-
() =>
|
|
25
|
+
() => _chunkZ6DERGHYjs.requireSdkCompatibility.call(void 0, baseUrl, {
|
|
26
26
|
command: "plays run",
|
|
27
27
|
persistCache: maintenancePolicy !== "off",
|
|
28
28
|
signal
|
|
29
29
|
})
|
|
30
30
|
);
|
|
31
31
|
_optionalChain([signal, 'optionalAccess', _3 => _3.throwIfAborted, 'call', _4 => _4()]);
|
|
32
|
-
|
|
32
|
+
_chunkZ6DERGHYjs.enforceSdkCompatibilityResponse.call(void 0, compatibility, {
|
|
33
33
|
quietAdvisory: true
|
|
34
34
|
});
|
|
35
35
|
}
|
|
@@ -4,22 +4,22 @@
|
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkVOQWPUIFjs = require('./chunk-VOQWPUIF.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _chunkZ6DERGHYjs = require('./chunk-Z6DERGHY.js');
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunkNNWEQDZRjs = require('./chunk-NNWEQDZR.js');
|
|
17
17
|
|
|
18
18
|
|
|
19
|
-
var
|
|
19
|
+
var _chunk2ZCFAUCVjs = require('./chunk-2ZCFAUCV.js');
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
var
|
|
22
|
+
var _chunk6VSUP4WNjs = require('./chunk-6VSUP4WN.js');
|
|
23
23
|
|
|
24
24
|
// src/cli/compatibility-catalog.ts
|
|
25
25
|
var readers = /* @__PURE__ */ new WeakMap();
|
|
@@ -46,7 +46,7 @@ function trustedAutoUpdateRegistryUrl(baseUrl) {
|
|
|
46
46
|
async function reportAutoUpdateEvent(input) {
|
|
47
47
|
let apiKey = "";
|
|
48
48
|
try {
|
|
49
|
-
apiKey =
|
|
49
|
+
apiKey = _chunk2ZCFAUCVjs.resolveApiKeyForBaseUrl.call(void 0, input.baseUrl);
|
|
50
50
|
} catch (e2) {
|
|
51
51
|
return;
|
|
52
52
|
}
|
|
@@ -62,15 +62,15 @@ async function reportAutoUpdateEvent(input) {
|
|
|
62
62
|
headers: {
|
|
63
63
|
Authorization: `Bearer ${apiKey}`,
|
|
64
64
|
"Content-Type": "application/json",
|
|
65
|
-
"User-Agent": `deepline-ts-sdk/${
|
|
65
|
+
"User-Agent": `deepline-ts-sdk/${_chunk6VSUP4WNjs.SDK_VERSION}`,
|
|
66
66
|
"X-Deepline-Client-Family": "sdk",
|
|
67
67
|
"X-Deepline-CLI-Family": "sdk",
|
|
68
|
-
"X-Deepline-CLI-Version":
|
|
69
|
-
"X-Deepline-SDK-Version":
|
|
68
|
+
"X-Deepline-CLI-Version": _chunk6VSUP4WNjs.SDK_VERSION,
|
|
69
|
+
"X-Deepline-SDK-Version": _chunk6VSUP4WNjs.SDK_VERSION
|
|
70
70
|
},
|
|
71
71
|
body: JSON.stringify({
|
|
72
72
|
event: input.event,
|
|
73
|
-
current_version: _optionalChain([input, 'access', _4 => _4.response, 'access', _5 => _5.current, 'optionalAccess', _6 => _6.trim, 'call', _7 => _7()]) ||
|
|
73
|
+
current_version: _optionalChain([input, 'access', _4 => _4.response, 'access', _5 => _5.current, 'optionalAccess', _6 => _6.trim, 'call', _7 => _7()]) || _chunk6VSUP4WNjs.SDK_VERSION,
|
|
74
74
|
target_version: input.response.latest,
|
|
75
75
|
reason: _optionalChain([input, 'access', _8 => _8.response, 'access', _9 => _9.auto_update, 'optionalAccess', _10 => _10.reason]),
|
|
76
76
|
command: _nullishCoalesce(input.response.command, () => ( null)),
|
|
@@ -89,19 +89,19 @@ function envTruthy(name) {
|
|
|
89
89
|
return value === "1" || value === "true" || value === "yes";
|
|
90
90
|
}
|
|
91
91
|
function shouldSkipSelfUpdate(policy) {
|
|
92
|
-
return policy === "off" || envTruthy("DEEPLINE_SKIP_SELF_UPDATE") || envTruthy("DEEPLINE_NO_AUTO_UPDATE") || envTruthy("DEEPLINE_SKIP_SDK_AUTO_UPDATE") || envTruthy("DEEPLINE_DISABLE_AUTO_UPDATE") || !
|
|
92
|
+
return policy === "off" || envTruthy("DEEPLINE_SKIP_SELF_UPDATE") || envTruthy("DEEPLINE_NO_AUTO_UPDATE") || envTruthy("DEEPLINE_SKIP_SDK_AUTO_UPDATE") || envTruthy("DEEPLINE_DISABLE_AUTO_UPDATE") || !_chunkVOQWPUIFjs.shouldRunCliAutoUpdate.call(void 0, ) || _chunkZ6DERGHYjs.isCiEnvironment.call(void 0, );
|
|
93
93
|
}
|
|
94
94
|
function isDowngradeAutoUpdateResponse(response) {
|
|
95
95
|
const target = _optionalChain([response, 'optionalAccess', _17 => _17.latest, 'optionalAccess', _18 => _18.trim, 'call', _19 => _19()]);
|
|
96
|
-
const current = _optionalChain([response, 'optionalAccess', _20 => _20.current, 'optionalAccess', _21 => _21.trim, 'call', _22 => _22()]) ||
|
|
96
|
+
const current = _optionalChain([response, 'optionalAccess', _20 => _20.current, 'optionalAccess', _21 => _21.trim, 'call', _22 => _22()]) || _chunk6VSUP4WNjs.SDK_VERSION;
|
|
97
97
|
if (!target) return false;
|
|
98
|
-
return
|
|
98
|
+
return _chunkVOQWPUIFjs.compareUpdateVersions.call(void 0, target, current) < 0;
|
|
99
99
|
}
|
|
100
100
|
function relaunchCurrentCommand(plan, runtime = {}) {
|
|
101
101
|
return new Promise((resolve) => {
|
|
102
102
|
const argv = _nullishCoalesce(runtime.argv, () => ( process.argv));
|
|
103
103
|
const platform = _nullishCoalesce(runtime.platform, () => ( process.platform));
|
|
104
|
-
const launch = plan.kind === "python-sidecar" ?
|
|
104
|
+
const launch = plan.kind === "python-sidecar" ? _chunkZ6DERGHYjs.resolveShellSpawn.call(void 0, plan.sidecarPath, argv.slice(2), platform) : {
|
|
105
105
|
command: _nullishCoalesce(runtime.execPath, () => ( process.execPath)),
|
|
106
106
|
args: argv.slice(1),
|
|
107
107
|
shell: false
|
|
@@ -148,7 +148,7 @@ async function maybeAutoUpdateAndRelaunch(response, baseUrl, policy = "configure
|
|
|
148
148
|
}
|
|
149
149
|
if (isDowngradeAutoUpdateResponse(response)) {
|
|
150
150
|
const target = response.latest;
|
|
151
|
-
const current = _optionalChain([response, 'access', _26 => _26.current, 'optionalAccess', _27 => _27.trim, 'call', _28 => _28()]) ||
|
|
151
|
+
const current = _optionalChain([response, 'access', _26 => _26.current, 'optionalAccess', _27 => _27.trim, 'call', _28 => _28()]) || _chunk6VSUP4WNjs.SDK_VERSION;
|
|
152
152
|
process.stderr.write(
|
|
153
153
|
`Deepline SDK/CLI auto-update refused: server advertised older ${target} than current ${current}. Continuing without mutating the CLI.
|
|
154
154
|
`
|
|
@@ -156,21 +156,21 @@ async function maybeAutoUpdateAndRelaunch(response, baseUrl, policy = "configure
|
|
|
156
156
|
return false;
|
|
157
157
|
}
|
|
158
158
|
const packageSpec = response.latest ? `deepline@${response.latest}` : void 0;
|
|
159
|
-
const plan =
|
|
159
|
+
const plan = _chunkVOQWPUIFjs.resolveUpdatePlan.call(void 0, {
|
|
160
160
|
packageSpec,
|
|
161
161
|
requireVerifiedNpmOwnership: true,
|
|
162
162
|
npmFallbackRegistryUrl: trustedAutoUpdateRegistryUrl(baseUrl)
|
|
163
163
|
});
|
|
164
|
-
if (!
|
|
164
|
+
if (!_chunkVOQWPUIFjs.canAutomaticallyApplyUpdatePlan.call(void 0, plan)) {
|
|
165
165
|
return false;
|
|
166
166
|
}
|
|
167
167
|
if (!autoUpdate.required && autoUpdate.reason !== "rollback_forced") {
|
|
168
168
|
deferredAutoUpdate = async () => {
|
|
169
169
|
await applyAutoUpdate(response, baseUrl, plan, "next_command");
|
|
170
170
|
};
|
|
171
|
-
if (
|
|
171
|
+
if (_chunkNNWEQDZRjs.isJsonOutputMode.call(void 0, )) {
|
|
172
172
|
const target = _optionalChain([response, 'access', _29 => _29.latest, 'optionalAccess', _30 => _30.trim, 'call', _31 => _31()]);
|
|
173
|
-
|
|
173
|
+
_chunkNNWEQDZRjs.addJsonNotice.call(void 0, {
|
|
174
174
|
code: "sdk_update_queued",
|
|
175
175
|
message: `Deepline SDK/CLI update${target ? ` to ${target}` : ""} is queued after this command; the next command will use it if installation succeeds.`
|
|
176
176
|
});
|
|
@@ -183,7 +183,7 @@ async function maybeAutoUpdateAndRelaunch(response, baseUrl, policy = "configure
|
|
|
183
183
|
return true;
|
|
184
184
|
}
|
|
185
185
|
async function applyAutoUpdate(response, baseUrl, plan, takesEffect) {
|
|
186
|
-
if (!
|
|
186
|
+
if (!_chunkVOQWPUIFjs.canAutomaticallyApplyUpdatePlan.call(void 0, plan)) return false;
|
|
187
187
|
const autoUpdate = response.auto_update;
|
|
188
188
|
const label = _optionalChain([autoUpdate, 'optionalAccess', _32 => _32.reason]) === "rollback_forced" ? "has a server rollback pending and needs the latest rollback-aware CLI" : _optionalChain([autoUpdate, 'optionalAccess', _33 => _33.reason]) === "deprecated" ? "is deprecated and will update automatically" : _optionalChain([autoUpdate, 'optionalAccess', _34 => _34.required]) ? "requires an update" : "has an update available and will update automatically";
|
|
189
189
|
process.stderr.write(
|
|
@@ -196,7 +196,7 @@ async function applyAutoUpdate(response, baseUrl, plan, takesEffect) {
|
|
|
196
196
|
event: "started",
|
|
197
197
|
installKind: plan.kind
|
|
198
198
|
});
|
|
199
|
-
const updateResult = await
|
|
199
|
+
const updateResult = await _chunkVOQWPUIFjs.runAutomaticUpdatePlan.call(void 0, plan);
|
|
200
200
|
if (updateResult.status === "skipped_previous_failure") {
|
|
201
201
|
void reportAutoUpdateEvent({
|
|
202
202
|
baseUrl,
|
|
@@ -234,7 +234,7 @@ async function applyAutoUpdate(response, baseUrl, plan, takesEffect) {
|
|
|
234
234
|
exitCode: 0
|
|
235
235
|
});
|
|
236
236
|
try {
|
|
237
|
-
await
|
|
237
|
+
await _chunkZ6DERGHYjs.syncSdkSkillsIfNeeded.call(void 0, baseUrl, {
|
|
238
238
|
mode: "detached",
|
|
239
239
|
update: _optionalChain([response, 'access', _36 => _36.skills, 'optionalAccess', _37 => _37.requires_cli_update]) ? void 0 : response.skills,
|
|
240
240
|
afterCliUpdate: {
|
|
@@ -261,7 +261,7 @@ var _crypto = require('crypto');
|
|
|
261
261
|
var TOOL_EXECUTE_PROGRESS_INTERVAL_MS = 15e3;
|
|
262
262
|
var activeToolExecuteCommand = null;
|
|
263
263
|
function progressLine(line) {
|
|
264
|
-
if (!
|
|
264
|
+
if (!_chunkNNWEQDZRjs.isJsonOutputMode.call(void 0, )) console.error(line);
|
|
265
265
|
}
|
|
266
266
|
function beginToolExecuteCommand() {
|
|
267
267
|
if (activeToolExecuteCommand) return activeToolExecuteCommand.invocationId;
|