deepline 0.3.552 → 0.3.554
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 +107 -12
- package/dist/bundling-sources/sdk/src/compat.ts +239 -87
- package/dist/bundling-sources/sdk/src/config.ts +113 -2
- package/dist/bundling-sources/sdk/src/errors.ts +2 -0
- package/dist/bundling-sources/sdk/src/http-core.ts +118 -8
- package/dist/bundling-sources/sdk/src/index.ts +2 -0
- package/dist/bundling-sources/sdk/src/integrations.ts +6 -4
- package/dist/bundling-sources/sdk/src/play.ts +3 -0
- package/dist/bundling-sources/sdk/src/plays/run-request.ts +1 -1
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/sdk/src/runs/watch-polling.ts +8 -1
- package/dist/bundling-sources/sdk/src/tool-calls.ts +2 -1
- package/dist/bundling-sources/sdk/src/tool-failure-hint.ts +104 -0
- package/dist/bundling-sources/sdk/src/types.ts +9 -1
- package/dist/bundling-sources/shared_libs/integration-contracts/billing-entitlements.ts +4 -2
- package/dist/bundling-sources/shared_libs/integration-contracts/billing-plan-skus.ts +25 -0
- package/dist/bundling-sources/shared_libs/monitors/action-actor.ts +2 -0
- package/dist/bundling-sources/shared_libs/monitors/billing/credit-recovery.ts +58 -4
- package/dist/bundling-sources/shared_libs/monitors/billing/policy-builders.ts +8 -0
- package/dist/bundling-sources/shared_libs/monitors/billing/pricing.ts +11 -0
- package/dist/bundling-sources/shared_libs/monitors/billing/types.ts +13 -0
- package/dist/bundling-sources/shared_libs/monitors/deactivation-reasons.ts +103 -5
- package/dist/bundling-sources/shared_libs/monitors/fleets/converge-admission.ts +133 -0
- package/dist/bundling-sources/shared_libs/monitors/fleets/fence-attention.ts +165 -0
- package/dist/bundling-sources/shared_libs/monitors/fleets/fence-release.ts +726 -0
- package/dist/bundling-sources/shared_libs/monitors/fleets/fence-walk.ts +274 -0
- package/dist/bundling-sources/shared_libs/monitors/fleets/issues.ts +1 -0
- package/dist/bundling-sources/shared_libs/monitors/fleets/limits.ts +28 -0
- package/dist/bundling-sources/shared_libs/monitors/fleets/provider-bulk-wait.ts +126 -0
- package/dist/bundling-sources/shared_libs/monitors/fleets/shared-payload.ts +189 -0
- package/dist/bundling-sources/shared_libs/monitors/http-error-response.ts +28 -0
- package/dist/bundling-sources/shared_libs/monitors/inbound-publish-key.ts +4 -0
- package/dist/bundling-sources/shared_libs/monitors/inventory-counter-errors.ts +25 -0
- package/dist/bundling-sources/shared_libs/monitors/org-monitor-limits.ts +65 -0
- package/dist/bundling-sources/shared_libs/monitors/package.json +9 -0
- package/dist/bundling-sources/shared_libs/monitors/provider-callback-verification.ts +152 -1
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-batch-operation.ts +6 -0
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-capability.ts +390 -10
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-errors.ts +34 -0
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-identity-claims.ts +66 -30
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-state.ts +30 -0
- package/dist/bundling-sources/shared_libs/monitors/provider-resource-failure.ts +26 -3
- package/dist/bundling-sources/shared_libs/monitors/signal-radars/inbound-dead-letter.ts +41 -13
- package/dist/bundling-sources/shared_libs/monitors/signal-radars/raw-receipt-causes.ts +219 -0
- package/dist/bundling-sources/shared_libs/monitors/snitcher-ip2company.ts +21 -10
- package/dist/bundling-sources/shared_libs/monitors/starter-templates.ts +13 -0
- package/dist/bundling-sources/shared_libs/monitors/tracking-provider-guidance.ts +6 -0
- package/dist/bundling-sources/shared_libs/monitors/tracking-provider-integrations.ts +13 -0
- package/dist/bundling-sources/shared_libs/observability/dlq.ts +1 -1
- package/dist/bundling-sources/shared_libs/observability/log-metadata.ts +5 -3
- package/dist/bundling-sources/shared_libs/observability/queue-health.ts +10 -1
- package/dist/bundling-sources/shared_libs/observability/queue-item-connectors.ts +1 -0
- package/dist/bundling-sources/shared_libs/observability/redaction.ts +24 -1
- package/dist/bundling-sources/shared_libs/observability/scheduled-jobs.json +168 -41
- package/dist/bundling-sources/shared_libs/observability/scheduled-work-manual.ts +1 -2
- package/dist/bundling-sources/shared_libs/play-data-plane/preview-r2-oidc.ts +188 -0
- package/dist/bundling-sources/shared_libs/play-data-plane/r2.ts +170 -16
- package/dist/bundling-sources/shared_libs/play-data-plane/runtime-sheet-storage-contract.ts +5 -0
- package/dist/bundling-sources/shared_libs/play-runtime/app-runtime-api.ts +68 -2
- package/dist/bundling-sources/shared_libs/play-runtime/context.ts +444 -39
- package/dist/bundling-sources/shared_libs/play-runtime/ctx-fetch-caller-deadline.ts +200 -0
- package/dist/bundling-sources/shared_libs/play-runtime/ctx-types.ts +6 -0
- package/dist/bundling-sources/shared_libs/play-runtime/deployment/runtime-topology.ts +21 -1
- package/dist/bundling-sources/shared_libs/play-runtime/durable-call-cache.ts +3 -2
- package/dist/bundling-sources/shared_libs/play-runtime/durable-summary-events.ts +70 -2
- package/dist/bundling-sources/shared_libs/play-runtime/durable-tool-identity.ts +3 -3
- package/dist/bundling-sources/shared_libs/play-runtime/execution-capabilities.ts +16 -0
- package/dist/bundling-sources/shared_libs/play-runtime/experiment-switches.ts +72 -0
- package/dist/bundling-sources/shared_libs/play-runtime/fixture-behavior.ts +1 -0
- package/dist/bundling-sources/shared_libs/play-runtime/governor/policy.ts +7 -1
- package/dist/bundling-sources/shared_libs/play-runtime/internal-bootstrap-token.ts +62 -0
- package/dist/bundling-sources/shared_libs/play-runtime/map-memory-limits.ts +74 -3
- package/dist/bundling-sources/shared_libs/play-runtime/output-size-limits.ts +31 -3
- package/dist/bundling-sources/shared_libs/play-runtime/play-http-request.ts +6 -0
- package/dist/bundling-sources/shared_libs/play-runtime/protocol.ts +8 -0
- package/dist/bundling-sources/shared_libs/play-runtime/query-result-dataset.ts +19 -0
- package/dist/bundling-sources/shared_libs/play-runtime/resource-governor.ts +39 -2
- package/dist/bundling-sources/shared_libs/play-runtime/run-failure.ts +9 -1
- package/dist/bundling-sources/shared_libs/play-runtime/run-identity.ts +33 -0
- package/dist/bundling-sources/shared_libs/play-runtime/run-ledger-projection-contract.ts +24 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runner-app/index.ts +254 -44
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-payload-transport.ts +87 -6
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/modal.ts +241 -10
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/early-sandbox-egress.ts +161 -14
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/early-sandbox.ts +16 -3
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-api-compression.ts +37 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-api-paths.ts +9 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-api.ts +259 -52
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-authority.ts +13 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-constants.ts +30 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-operation-contract.ts +62 -1
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-scheduler-topology.ts +36 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-sheet-row-transition.ts +36 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-speed-profile.ts +206 -2
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-pool.ts +42 -0
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-runtime-worker.ts +185 -64
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-worker-slot-ledger.ts +157 -0
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/early-sandbox-lane.ts +110 -2
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/early-sandbox-listener-hint.ts +323 -0
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/executor-attempt-standing.ts +72 -0
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/integration-operation-value-storage.ts +23 -4
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres-workspace-purge.ts +199 -0
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +632 -66
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/run-ledger-outbox-recovery.ts +517 -16
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-api-origin.ts +1 -1
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-receipt-value-storage.ts +9 -0
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-worker-wake.ts +599 -2
- package/dist/bundling-sources/shared_libs/play-runtime/secret-resolution-retry-policy.ts +26 -1
- package/dist/bundling-sources/shared_libs/play-runtime/startup-read-tool-ids.ts +60 -0
- package/dist/bundling-sources/shared_libs/play-runtime/test-runtime-seams.ts +51 -0
- package/dist/bundling-sources/shared_libs/play-runtime/tool-call-retry-facts.ts +2 -0
- package/dist/bundling-sources/shared_libs/play-runtime/tool-execute-retry-policy.ts +113 -3
- package/dist/bundling-sources/shared_libs/play-runtime/tool-http-errors.ts +5 -7
- package/dist/bundling-sources/shared_libs/play-runtime/work-receipt-storage-contract.ts +2 -0
- package/dist/bundling-sources/shared_libs/play-runtime/workflow-executor-auth.ts +3 -0
- package/dist/bundling-sources/shared_libs/plays/authoring-contract.ts +40 -5
- package/dist/bundling-sources/shared_libs/plays/deploy/api-client.ts +3 -0
- package/dist/bundling-sources/shared_libs/plays/deploy/control-plane-types.ts +16 -0
- package/dist/bundling-sources/shared_libs/plays/deploy/run-deployment.ts +10 -41
- package/dist/bundling-sources/shared_libs/plays/extension-bridge.ts +33 -0
- package/dist/bundling-sources/shared_libs/plays/row-identity.ts +18 -1
- package/dist/bundling-sources/shared_libs/plays/tool-execution-error.ts +108 -0
- package/dist/bundling-sources/shared_libs/plays/trigger-config-contract.ts +14 -0
- package/dist/bundling-sources/shared_libs/product-notifications/catalog.ts +171 -0
- package/dist/bundling-sources/shared_libs/product-notifications/events.ts +27 -1
- package/dist/bundling-sources/shared_libs/security/email-blacklist.ts +9 -24
- package/dist/bundling-sources/shared_libs/security/secret-redaction.ts +178 -5
- package/dist/bundling-sources/shared_libs/security/signup-email-dns-screen.ts +148 -0
- package/dist/bundling-sources/shared_libs/tool-execution-error.ts +108 -0
- package/dist/cli/{auth-KVSBJZOX.mjs → auth-HJUNW7T2.mjs} +8 -7
- package/dist/cli/auth-SP6SKZJZ.js +44 -0
- package/dist/cli/{billing-FQREA7UA.js → billing-4TSA5HEC.js} +297 -161
- package/dist/cli/{billing-54RHFEBI.mjs → billing-SJYRJAQ2.mjs} +197 -61
- package/dist/cli/{chunk-4MK42735.js → chunk-2HMN5H54.js} +215 -130
- package/dist/cli/{chunk-UBKA33KY.mjs → chunk-2MGZAI54.mjs} +17 -0
- package/dist/cli/{chunk-EOPEYCY7.mjs → chunk-2ORPFQUA.mjs} +18 -18
- package/dist/cli/{chunk-RQZQVFCJ.js → chunk-2OVHNHCF.js} +2 -2
- package/dist/cli/{chunk-QX7LFGJR.mjs → chunk-33WRQSQ2.mjs} +1874 -91
- package/dist/cli/{chunk-UPMRIVZB.js → chunk-3IKGZ4CG.js} +74 -13
- package/dist/cli/{chunk-EUPVF4SU.mjs → chunk-3Z4VFCXO.mjs} +8 -8
- package/dist/cli/{chunk-GKYAYLRI.js → chunk-4DOFGIEJ.js} +27 -31
- package/dist/cli/{chunk-4TALT2M3.mjs → chunk-52Q5KETX.mjs} +69 -3
- package/dist/cli/{chunk-RBEUVDZF.js → chunk-5CYZHOKI.js} +249 -107
- package/dist/cli/{chunk-LX35AXTN.mjs → chunk-5TYLSS4Q.mjs} +6 -6
- package/dist/cli/{chunk-IYSTRCLX.mjs → chunk-62AUAWQV.mjs} +4 -4
- package/dist/cli/{chunk-ZIAXDBXX.mjs → chunk-62HWJXST.mjs} +17 -21
- package/dist/cli/{chunk-QY3ZNU6Z.mjs → chunk-6EXOAT6T.mjs} +2 -2
- package/dist/cli/{chunk-EITMD3A5.js → chunk-6VLFQZK6.js} +8 -8
- package/dist/cli/{chunk-ADRC5I3R.js → chunk-7OWI736E.js} +30 -30
- package/dist/cli/{chunk-NURW5XH4.mjs → chunk-ASB47RXJ.mjs} +1 -1
- package/dist/cli/{chunk-PTVD2GVQ.mjs → chunk-B6HO2XWH.mjs} +13 -13
- package/dist/cli/{chunk-YJHE3O5M.mjs → chunk-BOZAP2EM.mjs} +141 -56
- package/dist/cli/chunk-BVXIGOBZ.js +32 -0
- package/dist/cli/{chunk-XDVT3GOM.js → chunk-CFJFUVX2.js} +18 -1
- package/dist/cli/{chunk-WE5HES3H.mjs → chunk-D6Z6POKE.mjs} +151 -43
- package/dist/cli/{chunk-AZQ264ID.mjs → chunk-DSKSFFK2.mjs} +1 -1
- package/dist/cli/{chunk-SHLFOPD6.js → chunk-DUBXUAAO.js} +5 -5
- package/dist/cli/{chunk-V436Z54K.js → chunk-E2G2DNAB.js} +3 -1
- package/dist/cli/{chunk-HO3XK3R7.js → chunk-E74KGKFZ.js} +8 -8
- package/dist/cli/{chunk-77AAAGVB.js → chunk-ECHKAC7M.js} +2 -2
- package/dist/cli/{chunk-KWSH5T7K.js → chunk-EN5NHCCQ.js} +21 -21
- package/dist/cli/{chunk-6RZOWL2V.mjs → chunk-F7CMRKSK.mjs} +1 -1
- package/dist/cli/{chunk-JWUAX6OP.js → chunk-FBAFX43W.js} +11 -11
- package/dist/cli/{chunk-AQWQ2BFX.mjs → chunk-FXQ3JKE3.mjs} +1 -1
- package/dist/cli/{chunk-QPKH23EC.mjs → chunk-GA2M3G3Y.mjs} +5 -5
- package/dist/cli/{chunk-G4O75EXF.js → chunk-GHT2NDL7.js} +18 -18
- package/dist/cli/{chunk-MF2GHZDO.js → chunk-GRZENGNE.js} +2 -2
- package/dist/cli/{chunk-4UUR4TCH.js → chunk-IVZKMJUK.js} +1875 -92
- package/dist/cli/{chunk-FTJLJCE5.mjs → chunk-KVBQY4ST.mjs} +3 -3
- package/dist/cli/{chunk-S5S355UY.mjs → chunk-KZHBDMGF.mjs} +12 -12
- package/dist/cli/{chunk-BBTKAASQ.js → chunk-LFQJW4S2.js} +42 -1
- package/dist/cli/{chunk-6ZORHRKB.mjs → chunk-LRZGS6RZ.mjs} +2 -0
- package/dist/cli/{chunk-2WFPHBR4.js → chunk-LY5MMXFF.js} +47 -29
- package/dist/cli/{chunk-BAIST2BR.js → chunk-M7STM3MZ.js} +36 -36
- package/dist/cli/{chunk-SL6MYJYM.js → chunk-MJTVX4QK.js} +35 -35
- package/dist/cli/{chunk-45PVGZST.js → chunk-OPTV7D2V.js} +508 -361
- package/dist/cli/{chunk-PFO3ISXA.js → chunk-OVEYWO4H.js} +174 -129
- package/dist/cli/{chunk-BGBJV26E.mjs → chunk-PC2FTUCP.mjs} +4 -4
- package/dist/cli/{chunk-WLN3SUIA.js → chunk-PQQMPUCZ.js} +3 -3
- package/dist/cli/{chunk-HYC4MKGK.mjs → chunk-Q7ACILL2.mjs} +5 -5
- package/dist/cli/{chunk-CBV7AKWM.js → chunk-R6DZ6NQ2.js} +5 -5
- package/dist/cli/{chunk-57VZVF5D.mjs → chunk-RBBTCYQB.mjs} +3 -3
- package/dist/cli/{chunk-F2LH7TGF.js → chunk-RTHMGSZX.js} +21 -21
- package/dist/cli/{chunk-YLTMXJFC.mjs → chunk-S6W6SJ6E.mjs} +158 -16
- package/dist/cli/chunk-STXDSVQZ.mjs +32 -0
- package/dist/cli/{chunk-WEHCBH5R.mjs → chunk-TGUQET3O.mjs} +67 -6
- package/dist/cli/{chunk-IHRKLXZN.js → chunk-TJ6HLN56.js} +5 -5
- package/dist/cli/{chunk-3FD5EQ62.js → chunk-TOO3YM5N.js} +6 -7
- package/dist/cli/{chunk-QILKGXYF.mjs → chunk-UBBYHB2B.mjs} +2 -2
- package/dist/cli/{chunk-6PRW5UBA.mjs → chunk-UC4BDZKI.mjs} +299 -69
- package/dist/cli/{chunk-634ZDA3F.js → chunk-UNNOZKRT.js} +1 -1
- package/dist/cli/{chunk-IDVVIXPJ.js → chunk-UOT7HPBH.js} +41 -41
- package/dist/cli/{chunk-6YCA5NKJ.js → chunk-UYCZFQYQ.js} +12 -12
- package/dist/cli/{chunk-7IKQKKNX.js → chunk-VIUUTEHY.js} +90 -24
- package/dist/cli/{chunk-Z5TSLLOW.mjs → chunk-VLO5NFH2.mjs} +63 -18
- package/dist/cli/{chunk-U7QRMBIY.mjs → chunk-VQ75KX7G.mjs} +5 -5
- package/dist/cli/{chunk-4NQF6KJ3.js → chunk-VV4XGZ24.js} +13 -13
- package/dist/cli/{chunk-FSIVF2SI.mjs → chunk-VZGLIK5U.mjs} +1 -1
- package/dist/cli/{chunk-S46HWQKO.js → chunk-W6CZDTIR.js} +69 -69
- package/dist/cli/{chunk-XVB7V4N7.js → chunk-WL7P32PI.js} +161 -53
- package/dist/cli/{chunk-DJ2JDK4O.mjs → chunk-XD3MFTHA.mjs} +1 -1
- package/dist/cli/{chunk-GGGAEVCX.mjs → chunk-XFZX6FNM.mjs} +40 -22
- package/dist/cli/{chunk-AWJPDPMA.mjs → chunk-XU6QNM4D.mjs} +1 -1
- package/dist/cli/{chunk-QAORXEY3.mjs → chunk-YCOGPOUX.mjs} +6 -7
- package/dist/cli/{chunk-VQALXEXO.js → chunk-YQKCH4R7.js} +348 -118
- package/dist/cli/{chunk-6O5HOODW.mjs → chunk-YY55NYAH.mjs} +207 -60
- package/dist/cli/{chunk-JL2OTMSG.mjs → chunk-Z3A2S3QM.mjs} +41 -0
- package/dist/cli/command-docs.js +3 -3
- package/dist/cli/command-docs.mjs +2 -2
- package/dist/cli/{concurrent-runs-help-Q4KPAUJX.mjs → concurrent-runs-help-O3Q5IPLF.mjs} +9 -8
- package/dist/cli/concurrent-runs-help-ZFRZWX5V.js +22 -0
- package/dist/cli/{csv-F5VAGX4K.js → csv-4ZQ2RATI.js} +16 -15
- package/dist/cli/{csv-2PTVDNO6.mjs → csv-Y3BFPEM6.mjs} +7 -6
- package/dist/cli/{db-IEDXAUF7.mjs → db-3JYY4JNN.mjs} +17 -17
- package/dist/cli/{db-Z3OIUFMM.js → db-VEIFS4M7.js} +45 -45
- package/dist/cli/describe-EVJ4MFVU.mjs +50 -0
- package/dist/cli/describe-FG625QPF.js +50 -0
- package/dist/cli/describe-core.d.mts +3 -3
- package/dist/cli/describe-core.d.ts +3 -3
- package/dist/cli/describe-core.js +7 -7
- package/dist/cli/describe-core.mjs +6 -6
- package/dist/cli/{executions-H6H5655J.js → executions-HPZXOOVX.js} +12 -12
- package/dist/cli/{executions-R3LP74QN.mjs → executions-PCXZKEHM.mjs} +10 -10
- package/dist/cli/{feedback-WL3MRVT5.mjs → feedback-Y6VKZNY6.mjs} +9 -8
- package/dist/cli/{feedback-VFOUR66B.js → feedback-ZKFHFVL6.js} +17 -16
- package/dist/cli/git-RUBMALLH.js +26 -0
- package/dist/cli/{git-YX2J4GCI.mjs → git-UMPR2QYC.mjs} +8 -7
- package/dist/cli/index.js +170 -158
- package/dist/cli/index.mjs +60 -48
- package/dist/cli/{integrations-E2JZYKHS.js → integrations-3GQCTRTF.js} +23 -27
- package/dist/cli/{integrations-5ZK5KLVP.mjs → integrations-V3TM6XAB.mjs} +15 -19
- package/dist/cli/{legacy-noops-SMN3GSXY.mjs → legacy-noops-JZBUD7ZE.mjs} +9 -8
- package/dist/cli/{legacy-noops-3VW4IJTH.js → legacy-noops-VYCO7NGW.js} +12 -11
- package/dist/cli/{mcp-UQV2K4EW.js → mcp-4OIWTCE6.js} +121 -48
- package/dist/cli/{mcp-V6MGCYAG.mjs → mcp-PH4KZ76P.mjs} +100 -27
- package/dist/cli/{monitors-R3BBDCRC.js → monitors-E2A6VPBY.js} +221 -186
- package/dist/cli/{monitors-GGKS5W6M.mjs → monitors-SSMGIDGX.mjs} +58 -23
- package/dist/cli/org-SFDKSK5D.mjs +2289 -0
- package/dist/cli/org-WUDZGWBT.js +2289 -0
- package/dist/cli/outcomes-QT7LQBPK.mjs +2865 -0
- package/dist/cli/outcomes-Y7SZTLSL.js +2865 -0
- package/dist/cli/{play-MDWPR4XG.mjs → play-EK7KSFPL.mjs} +376 -106
- package/dist/cli/{play-2MVO27VO.js → play-GDNHCRRR.js} +1150 -880
- package/dist/cli/{providers-AKDYFZJZ.mjs → providers-FVZLRXAU.mjs} +10 -10
- package/dist/cli/{providers-2AACRUZH.js → providers-ZKOSECLV.js} +13 -13
- package/dist/cli/{quickstart-H6IV3PV3.js → quickstart-KSDKIXYD.js} +9 -8
- package/dist/cli/{quickstart-QDGRJFZY.mjs → quickstart-UJZ6PIQV.mjs} +7 -6
- package/dist/cli/{run-RTSQNGRD.mjs → run-E7MZ7P35.mjs} +35 -33
- package/dist/cli/{run-2634REDK.js → run-PD2BBG6S.js} +55 -53
- package/dist/cli/run-identity-LMLFMACS.js +31 -0
- package/dist/cli/{run-identity-MRNCEGV2.mjs → run-identity-MAZ7ANH5.mjs} +9 -3
- package/dist/cli/search-TKSPTPHA.js +32 -0
- package/dist/cli/{search-6AOJ4XPP.mjs → search-VTFUFTOY.mjs} +11 -11
- package/dist/cli/{search-output-S5ODBL5E.js → search-output-G2AGDCOY.js} +13 -12
- package/dist/cli/{search-output-6ADMTOU5.mjs → search-output-PFVXQCWA.mjs} +10 -9
- package/dist/cli/{secrets-TFIFBFB3.mjs → secrets-7CIMEMX7.mjs} +11 -11
- package/dist/cli/{secrets-LHCIIHMT.js → secrets-BCOQ4U7U.js} +20 -20
- package/dist/cli/sessions-4CO556VD.js +23 -0
- package/dist/cli/{sessions-WHBVUHVW.mjs → sessions-IUCQZEF7.mjs} +9 -8
- package/dist/cli/{settings-EBONWL5C.mjs → settings-KZN62UQK.mjs} +16 -16
- package/dist/cli/{settings-CP4FVK2W.js → settings-REL4736M.js} +89 -89
- package/dist/cli/{setup-I5AZE3IU.mjs → setup-2P7OG3OU.mjs} +22 -24
- package/dist/cli/{setup-LFGHTNLQ.js → setup-2XIVBBCS.js} +62 -64
- package/dist/cli/skills-JYT5DEY6.js +37 -0
- package/dist/cli/{skills-W76AO5XE.mjs → skills-VIGNDJKI.mjs} +10 -9
- package/dist/cli/tools-NTVUQ2TG.js +57 -0
- package/dist/cli/{tools-7IJHGF6W.mjs → tools-W3QT5EJY.mjs} +24 -24
- package/dist/cli/{update-GFOPZTHY.mjs → update-GZVBVMY3.mjs} +14 -11
- package/dist/cli/update-TWJZPUZM.js +37 -0
- package/dist/cli/{views-D4NX4SBG.mjs → views-BOGEH424.mjs} +47 -49
- package/dist/cli/{views-BPL2TQJ4.js → views-TOLJNLSV.js} +62 -64
- package/dist/cli/{workflow-ZYNAUCKC.js → workflow-ENWFRK5M.js} +23 -23
- package/dist/cli/{workflow-YXP42FUI.mjs → workflow-VDG2FDQV.mjs} +13 -13
- package/dist/{client-CyXGrO4D.d.mts → client-B8f7RNF8.d.mts} +1 -1
- package/dist/{client-Bf3IpUKN.d.ts → client-C5TgXmJQ.d.ts} +1 -1
- package/dist/{client-core-BxsLnXlm.d.mts → client-core-SLLGBTht.d.mts} +268 -23
- package/dist/{client-core-BWd0lX0Z.d.ts → client-core-p0sOxnkl.d.ts} +268 -23
- package/dist/{compiler-manifest-BqwVrOri.d.ts → compiler-manifest-D_zZEh9Q.d.mts} +70 -5
- package/dist/{compiler-manifest-BqwVrOri.d.mts → compiler-manifest-D_zZEh9Q.d.ts} +70 -5
- package/dist/{errors-BU8FB99X.d.mts → errors-CZCrBFrQ.d.mts} +1 -1
- package/dist/{errors-DfVN_FUG.d.ts → errors-DsUkLrdZ.d.ts} +1 -1
- package/dist/{index-BGnvtYGc.d.ts → index-B6RTOZGC.d.ts} +1 -1
- package/dist/{index-DjZgwpGw.d.mts → index-DeOVrEmX.d.mts} +1 -1
- package/dist/index.d.mts +7 -7
- package/dist/index.d.ts +7 -7
- package/dist/index.js +66 -55
- package/dist/index.mjs +25 -14
- package/dist/install-integrity.json +163 -144
- package/dist/plays/bundle-play-file.d.mts +3 -3
- package/dist/plays/bundle-play-file.d.ts +3 -3
- package/dist/plays/bundle-play-file.mjs +23 -4
- package/dist/plays/csv-data-input.js +3 -3
- package/dist/plays/csv-data-input.mjs +2 -2
- package/dist/plays/play-description.d.mts +2 -2
- package/dist/plays/play-description.d.ts +2 -2
- package/dist/plays/run-request.d.mts +2 -2
- package/dist/plays/run-request.d.ts +2 -2
- package/dist/plays/run-request.js +4 -4
- package/dist/plays/run-request.mjs +3 -3
- package/dist/release.d.mts +1 -1
- package/dist/release.d.ts +1 -1
- package/dist/release.js +2 -2
- package/dist/release.mjs +1 -1
- package/dist/server.d.mts +4 -4
- package/dist/server.d.ts +4 -4
- package/dist/server.js +15 -13
- package/dist/server.mjs +9 -7
- package/package.json +1 -1
- package/dist/cli/auth-MMNVWATX.js +0 -43
- package/dist/cli/chunk-AID3OYVJ.js +0 -8
- package/dist/cli/chunk-OVDNJAJN.mjs +0 -8
- package/dist/cli/concurrent-runs-help-FQAIHKKC.js +0 -21
- package/dist/cli/describe-QDANCTS3.mjs +0 -50
- package/dist/cli/describe-VUTT5ZKU.js +0 -50
- package/dist/cli/git-ETB3GH3K.js +0 -25
- package/dist/cli/org-GRYVMNSW.js +0 -1282
- package/dist/cli/org-Z37NGJV4.mjs +0 -1282
- package/dist/cli/run-identity-G257GQED.js +0 -25
- package/dist/cli/search-VTW2YNBS.js +0 -32
- package/dist/cli/sessions-CJ4FJ2WB.js +0 -22
- package/dist/cli/skills-R7EBXREW.js +0 -36
- package/dist/cli/tools-V7U2BDXM.js +0 -57
- package/dist/cli/update-4COPZETK.js +0 -34
|
@@ -1,9 +1,9 @@
|
|
|
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 _chunkPQQMPUCZjs = require('./chunk-PQQMPUCZ.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkYQKCH4R7js = require('./chunk-YQKCH4R7.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
@@ -14,17 +14,24 @@ var _chunkVQALXEXOjs = require('./chunk-VQALXEXO.js');
|
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
var _chunk7IKQKKNXjs = require('./chunk-7IKQKKNX.js');
|
|
18
17
|
|
|
19
18
|
|
|
20
19
|
|
|
21
20
|
|
|
21
|
+
var _chunkVIUUTEHYjs = require('./chunk-VIUUTEHY.js');
|
|
22
22
|
|
|
23
23
|
|
|
24
|
-
var _chunkRBEUVDZFjs = require('./chunk-RBEUVDZF.js');
|
|
25
24
|
|
|
26
25
|
|
|
27
|
-
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
var _chunk5CYZHOKIjs = require('./chunk-5CYZHOKI.js');
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
var _chunkLFQJW4S2js = require('./chunk-LFQJW4S2.js');
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
var _chunkUNNOZKRTjs = require('./chunk-UNNOZKRT.js');
|
|
28
35
|
|
|
29
36
|
// src/compat.ts
|
|
30
37
|
var _crypto = require('crypto');
|
|
@@ -59,7 +66,7 @@ function shouldSkipCompatibilityCheck() {
|
|
|
59
66
|
return value === "1" || value === "true" || value === "yes";
|
|
60
67
|
}
|
|
61
68
|
function sdkCompatibilityCachePath(baseUrl, homeDir = _optionalChain([process, 'access', _7 => _7.env, 'access', _8 => _8.HOME, 'optionalAccess', _9 => _9.trim, 'call', _10 => _10()]) || _os.homedir.call(void 0, )) {
|
|
62
|
-
return _path.join.call(void 0,
|
|
69
|
+
return _path.join.call(void 0, _chunkVIUUTEHYjs.sdkCliStateDirPath.call(void 0, baseUrl, homeDir), "compat-cache.json");
|
|
63
70
|
}
|
|
64
71
|
function legacySdkCompatibilityCachePath(homeDir = _optionalChain([process, 'access', _11 => _11.env, 'access', _12 => _12.HOME, 'optionalAccess', _13 => _13.trim, 'call', _14 => _14()]) || _os.homedir.call(void 0, )) {
|
|
65
72
|
return _path.join.call(void 0, homeDir, ".cache", "deepline", "sdk-compat-cache.json");
|
|
@@ -67,9 +74,9 @@ function legacySdkCompatibilityCachePath(homeDir = _optionalChain([process, 'acc
|
|
|
67
74
|
function compatibilityCacheKey(baseUrl, command, skillsVersion) {
|
|
68
75
|
return JSON.stringify({
|
|
69
76
|
baseUrl: baseUrl.replace(/\/$/, ""),
|
|
70
|
-
version:
|
|
71
|
-
apiContract:
|
|
72
|
-
apiMajor:
|
|
77
|
+
version: _chunk5CYZHOKIjs.SDK_VERSION,
|
|
78
|
+
apiContract: _chunk5CYZHOKIjs.SDK_API_CONTRACT,
|
|
79
|
+
apiMajor: _chunk5CYZHOKIjs.SDK_API_MAJOR,
|
|
73
80
|
command: _optionalChain([command, 'optionalAccess', _15 => _15.trim, 'call', _16 => _16()]) || null,
|
|
74
81
|
skillsVersion: _nullishCoalesce(skillsVersion, () => ( null))
|
|
75
82
|
});
|
|
@@ -77,8 +84,8 @@ function compatibilityCacheKey(baseUrl, command, skillsVersion) {
|
|
|
77
84
|
function legacyCompatibilityCacheKey(baseUrl, command) {
|
|
78
85
|
return JSON.stringify({
|
|
79
86
|
baseUrl: baseUrl.replace(/\/$/, ""),
|
|
80
|
-
version:
|
|
81
|
-
apiContract:
|
|
87
|
+
version: _chunk5CYZHOKIjs.SDK_VERSION,
|
|
88
|
+
apiContract: _chunk5CYZHOKIjs.SDK_API_CONTRACT,
|
|
82
89
|
command: _optionalChain([command, 'optionalAccess', _17 => _17.trim, 'call', _18 => _18()]) || null
|
|
83
90
|
});
|
|
84
91
|
}
|
|
@@ -103,7 +110,7 @@ function isSavedWithin(savedAt, windowMs, now) {
|
|
|
103
110
|
}
|
|
104
111
|
var UPDATE_ADVISORY_INTERVAL_MS = 24 * 60 * 60 * 1e3;
|
|
105
112
|
function claimUpdateAdvisory(baseUrl, now = Date.now()) {
|
|
106
|
-
const path = _path.join.call(void 0,
|
|
113
|
+
const path = _path.join.call(void 0, _chunkVIUUTEHYjs.sdkCliStateDirPath.call(void 0, baseUrl), "update-advisory.json");
|
|
107
114
|
try {
|
|
108
115
|
const { shownAt } = JSON.parse(_fs.readFileSync.call(void 0, path, "utf8"));
|
|
109
116
|
if (isSavedWithin(shownAt, UPDATE_ADVISORY_INTERVAL_MS, now)) return false;
|
|
@@ -176,21 +183,19 @@ function writeCachedCompatibility(baseUrl, command, skillsVersion, response) {
|
|
|
176
183
|
} catch (e6) {
|
|
177
184
|
}
|
|
178
185
|
}
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
186
|
+
function asError(error) {
|
|
187
|
+
return error instanceof Error ? error : new Error(String(error));
|
|
188
|
+
}
|
|
189
|
+
async function attemptSdkCompatibility(baseUrl, options, timeoutMs) {
|
|
183
190
|
const controller = new AbortController();
|
|
184
191
|
const abortFromCaller = () => controller.abort(_optionalChain([options, 'access', _27 => _27.signal, 'optionalAccess', _28 => _28.reason]));
|
|
185
192
|
if (_optionalChain([options, 'access', _29 => _29.signal, 'optionalAccess', _30 => _30.aborted])) abortFromCaller();
|
|
186
|
-
else
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
_nullishCoalesce(options.timeoutMs, () => ( CHECK_TIMEOUT_MS))
|
|
190
|
-
);
|
|
193
|
+
else
|
|
194
|
+
_optionalChain([options, 'access', _31 => _31.signal, 'optionalAccess', _32 => _32.addEventListener, 'call', _33 => _33("abort", abortFromCaller, { once: true })]);
|
|
195
|
+
const timeout = setTimeout(() => controller.abort(), timeoutMs);
|
|
191
196
|
try {
|
|
192
197
|
const url = new URL("/api/v2/sdk/compat", baseUrl);
|
|
193
|
-
url.searchParams.set("version",
|
|
198
|
+
url.searchParams.set("version", _chunk5CYZHOKIjs.SDK_VERSION);
|
|
194
199
|
if (_optionalChain([options, 'access', _34 => _34.command, 'optionalAccess', _35 => _35.trim, 'call', _36 => _36()])) {
|
|
195
200
|
url.searchParams.set("command", options.command.trim());
|
|
196
201
|
}
|
|
@@ -198,7 +203,7 @@ async function checkSdkCompatibility(baseUrl, options = {}) {
|
|
|
198
203
|
url.searchParams.set("skills_version", _nullishCoalesce(options.skillsVersion, () => ( "")));
|
|
199
204
|
url.searchParams.set(
|
|
200
205
|
"skills_cli_capability",
|
|
201
|
-
String(
|
|
206
|
+
String(_chunkUNNOZKRTjs.SDK_RELEASE.packageCapabilities.skillsGuidance)
|
|
202
207
|
);
|
|
203
208
|
}
|
|
204
209
|
if (options.catalog) {
|
|
@@ -210,72 +215,148 @@ async function checkSdkCompatibility(baseUrl, options = {}) {
|
|
|
210
215
|
const response = await fetch(url, {
|
|
211
216
|
method: "GET",
|
|
212
217
|
headers: {
|
|
213
|
-
...
|
|
214
|
-
"User-Agent": `deepline-ts-sdk/${
|
|
215
|
-
"X-Deepline-SDK-Version":
|
|
216
|
-
"X-Deepline-API-Major": String(
|
|
217
|
-
"X-Deepline-API-Contract":
|
|
218
|
+
..._chunk5CYZHOKIjs.deploymentProtectionHeaders.call(void 0, ),
|
|
219
|
+
"User-Agent": `deepline-ts-sdk/${_chunk5CYZHOKIjs.SDK_VERSION}`,
|
|
220
|
+
"X-Deepline-SDK-Version": _chunk5CYZHOKIjs.SDK_VERSION,
|
|
221
|
+
"X-Deepline-API-Major": String(_chunk5CYZHOKIjs.SDK_API_MAJOR),
|
|
222
|
+
"X-Deepline-API-Contract": _chunk5CYZHOKIjs.SDK_API_CONTRACT,
|
|
218
223
|
"X-Deepline-CLI-Update-Preferences": "1",
|
|
219
224
|
"X-Deepline-CLI-Auto-Update-Capability": SDK_CLI_AUTO_UPDATE_CAPABILITY,
|
|
220
|
-
...options.catalog ? { Authorization: `Bearer ${
|
|
225
|
+
...options.catalog ? { Authorization: `Bearer ${_chunkVIUUTEHYjs.resolveApiKeyForBaseUrl.call(void 0, baseUrl)}` } : {},
|
|
221
226
|
..._optionalChain([options, 'access', _37 => _37.catalog, 'optionalAccess', _38 => _38.cliInvocationId]) ? { "X-Deepline-CLI-Invocation-ID": options.catalog.cliInvocationId } : {}
|
|
222
227
|
},
|
|
223
228
|
signal: controller.signal
|
|
224
229
|
});
|
|
225
|
-
const
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
const { catalog_metadata: catalogMetadata, ...data } = raw;
|
|
233
|
-
if (options.persistCache !== false) {
|
|
234
|
-
writeCachedCompatibility(
|
|
235
|
-
baseUrl,
|
|
236
|
-
options.command,
|
|
237
|
-
options.skillsVersion,
|
|
238
|
-
data
|
|
239
|
-
);
|
|
240
|
-
}
|
|
241
|
-
if (data.ok && options.catalog && catalogMetadata && typeof catalogMetadata === "object" && "toolId" in catalogMetadata && catalogMetadata.toolId === options.catalog.toolId) {
|
|
242
|
-
options.catalog.acceptMetadata(catalogMetadata);
|
|
230
|
+
const text = await response.text();
|
|
231
|
+
controller.signal.throwIfAborted();
|
|
232
|
+
let raw;
|
|
233
|
+
try {
|
|
234
|
+
raw = JSON.parse(text);
|
|
235
|
+
} catch (e7) {
|
|
236
|
+
raw = null;
|
|
243
237
|
}
|
|
244
|
-
|
|
245
|
-
} catch (error) {
|
|
246
|
-
if (_optionalChain([options, 'access', _42 => _42.signal, 'optionalAccess', _43 => _43.aborted])) {
|
|
238
|
+
if (!raw || typeof raw.ok !== "boolean" || typeof raw.status !== "string") {
|
|
247
239
|
return {
|
|
248
|
-
|
|
249
|
-
|
|
240
|
+
ok: false,
|
|
241
|
+
transient: _chunkVIUUTEHYjs.TRANSIENT_HTTP_STATUSES.has(response.status),
|
|
242
|
+
error: new Error(
|
|
243
|
+
`SDK compatibility endpoint returned a non-policy response (HTTP ${response.status}).`
|
|
244
|
+
)
|
|
250
245
|
};
|
|
251
246
|
}
|
|
252
|
-
const
|
|
247
|
+
const { catalog_metadata: catalogMetadata, ...data } = raw;
|
|
248
|
+
return { ok: true, response: data, catalogMetadata };
|
|
249
|
+
} catch (error) {
|
|
250
|
+
_optionalChain([options, 'access', _39 => _39.signal, 'optionalAccess', _40 => _40.throwIfAborted, 'call', _41 => _41()]);
|
|
251
|
+
return { ok: false, transient: true, error: asError(error) };
|
|
252
|
+
} finally {
|
|
253
|
+
clearTimeout(timeout);
|
|
254
|
+
_optionalChain([options, 'access', _42 => _42.signal, 'optionalAccess', _43 => _43.removeEventListener, 'call', _44 => _44("abort", abortFromCaller)]);
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
function acceptSdkCompatibility(baseUrl, options, attempt) {
|
|
258
|
+
const { response: data, catalogMetadata } = attempt;
|
|
259
|
+
if (options.persistCache !== false) {
|
|
260
|
+
writeCachedCompatibility(
|
|
253
261
|
baseUrl,
|
|
254
262
|
options.command,
|
|
255
|
-
options.skillsVersion
|
|
263
|
+
options.skillsVersion,
|
|
264
|
+
data
|
|
256
265
|
);
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
266
|
+
}
|
|
267
|
+
if (data.ok && options.catalog && catalogMetadata && typeof catalogMetadata === "object" && "toolId" in catalogMetadata && catalogMetadata.toolId === options.catalog.toolId) {
|
|
268
|
+
options.catalog.acceptMetadata(catalogMetadata);
|
|
269
|
+
}
|
|
270
|
+
return data;
|
|
271
|
+
}
|
|
272
|
+
async function checkSdkCompatibility(baseUrl, options = {}) {
|
|
273
|
+
if (shouldSkipCompatibilityCheck()) {
|
|
274
|
+
return { response: null, error: null, live: false };
|
|
275
|
+
}
|
|
276
|
+
let attempt;
|
|
277
|
+
try {
|
|
278
|
+
attempt = await attemptSdkCompatibility(
|
|
279
|
+
baseUrl,
|
|
280
|
+
options,
|
|
281
|
+
_nullishCoalesce(options.timeoutMs, () => ( CHECK_TIMEOUT_MS))
|
|
282
|
+
);
|
|
283
|
+
} catch (error) {
|
|
284
|
+
return { response: null, error: asError(error), live: false };
|
|
285
|
+
}
|
|
286
|
+
if (attempt.ok) {
|
|
267
287
|
return {
|
|
268
|
-
response:
|
|
269
|
-
error:
|
|
288
|
+
response: acceptSdkCompatibility(baseUrl, options, attempt),
|
|
289
|
+
error: null,
|
|
290
|
+
live: true
|
|
270
291
|
};
|
|
271
|
-
} finally {
|
|
272
|
-
clearTimeout(timeout);
|
|
273
|
-
_optionalChain([options, 'access', _44 => _44.signal, 'optionalAccess', _45 => _45.removeEventListener, 'call', _46 => _46("abort", abortFromCaller)]);
|
|
274
292
|
}
|
|
293
|
+
const cached = readCachedCompatibility(
|
|
294
|
+
baseUrl,
|
|
295
|
+
options.command,
|
|
296
|
+
options.skillsVersion
|
|
297
|
+
);
|
|
298
|
+
if (cached) {
|
|
299
|
+
if (options.persistCache !== false && options.timeoutMs !== void 0 && options.timeoutMs < CHECK_TIMEOUT_MS) {
|
|
300
|
+
invalidateCachedCompatibility(
|
|
301
|
+
baseUrl,
|
|
302
|
+
options.command,
|
|
303
|
+
options.skillsVersion
|
|
304
|
+
);
|
|
305
|
+
}
|
|
306
|
+
return { response: cached, error: null, live: false };
|
|
307
|
+
}
|
|
308
|
+
return { response: null, error: attempt.error, live: false };
|
|
309
|
+
}
|
|
310
|
+
async function requireSdkCompatibility(baseUrl, options = {}) {
|
|
311
|
+
if (shouldSkipCompatibilityCheck()) return null;
|
|
312
|
+
const maxRetries = _nullishCoalesce(options.maxRetries, () => ( _chunkVIUUTEHYjs.DEFAULT_MAX_RETRIES));
|
|
313
|
+
const backoffMs = _nullishCoalesce(options.backoffMs, () => ( _chunkVIUUTEHYjs.defaultRetryBackoffMs));
|
|
314
|
+
let attempt;
|
|
315
|
+
let attempts = 0;
|
|
316
|
+
for (; ; ) {
|
|
317
|
+
attempts += 1;
|
|
318
|
+
attempt = await attemptSdkCompatibility(
|
|
319
|
+
baseUrl,
|
|
320
|
+
options,
|
|
321
|
+
_nullishCoalesce(options.attemptTimeoutMs, () => ( _chunkVIUUTEHYjs.DEFAULT_TIMEOUT))
|
|
322
|
+
);
|
|
323
|
+
if (attempt.ok) return acceptSdkCompatibility(baseUrl, options, attempt);
|
|
324
|
+
if (!attempt.transient || attempts > maxRetries) break;
|
|
325
|
+
await sleepUnlessAborted(backoffMs(attempts), options.signal);
|
|
326
|
+
}
|
|
327
|
+
const cached = readCachedCompatibility(
|
|
328
|
+
baseUrl,
|
|
329
|
+
options.command,
|
|
330
|
+
options.skillsVersion
|
|
331
|
+
);
|
|
332
|
+
if (cached) return cached;
|
|
333
|
+
throw Object.assign(
|
|
334
|
+
new (0, _chunkLFQJW4S2js.DeeplineError)(
|
|
335
|
+
`Could not read the Deepline SDK compatibility policy from ${baseUrl} after ${attempts} attempt${attempts === 1 ? "" : "s"}: ${attempt.error.message}`,
|
|
336
|
+
void 0,
|
|
337
|
+
"SDK_COMPATIBILITY_UNAVAILABLE",
|
|
338
|
+
{ attempts, transient: attempt.transient }
|
|
339
|
+
),
|
|
340
|
+
{ cause: attempt.error }
|
|
341
|
+
);
|
|
342
|
+
}
|
|
343
|
+
function sleepUnlessAborted(ms, signal) {
|
|
344
|
+
_optionalChain([signal, 'optionalAccess', _45 => _45.throwIfAborted, 'call', _46 => _46()]);
|
|
345
|
+
return new Promise((resolve, reject) => {
|
|
346
|
+
const onAbort = () => {
|
|
347
|
+
clearTimeout(timer);
|
|
348
|
+
reject(_optionalChain([signal, 'optionalAccess', _47 => _47.reason]));
|
|
349
|
+
};
|
|
350
|
+
const timer = setTimeout(() => {
|
|
351
|
+
_optionalChain([signal, 'optionalAccess', _48 => _48.removeEventListener, 'call', _49 => _49("abort", onAbort)]);
|
|
352
|
+
resolve();
|
|
353
|
+
}, ms);
|
|
354
|
+
_optionalChain([signal, 'optionalAccess', _50 => _50.addEventListener, 'call', _51 => _51("abort", onAbort, { once: true })]);
|
|
355
|
+
});
|
|
275
356
|
}
|
|
276
357
|
function isCiEnvironment() {
|
|
277
358
|
return ["CI", "GITHUB_ACTIONS"].some((name) => {
|
|
278
|
-
const value = _optionalChain([process, 'access',
|
|
359
|
+
const value = _optionalChain([process, 'access', _52 => _52.env, 'access', _53 => _53[name], 'optionalAccess', _54 => _54.trim, 'call', _55 => _55(), 'access', _56 => _56.toLowerCase, 'call', _57 => _57()]);
|
|
279
360
|
return value === "1" || value === "true" || value === "yes";
|
|
280
361
|
});
|
|
281
362
|
}
|
|
@@ -386,7 +467,7 @@ function skillsSourceUrl(baseUrl) {
|
|
|
386
467
|
function buildSkillsAddArgs(baseUrl, skillName, options = {}) {
|
|
387
468
|
const skillNames = Array.isArray(skillName) ? skillName : [skillName];
|
|
388
469
|
const [firstSkillName, ...extraSkillNames] = skillNames;
|
|
389
|
-
const agents = _nullishCoalesce(options.agents, () => (
|
|
470
|
+
const agents = _nullishCoalesce(options.agents, () => ( _chunkVIUUTEHYjs.DEFAULT_SKILL_AGENTS));
|
|
390
471
|
const values = {
|
|
391
472
|
skills_index_url: skillsIndexUrl(baseUrl),
|
|
392
473
|
skills_source_url: skillsSourceUrl(baseUrl),
|
|
@@ -443,8 +524,11 @@ function resolveShellSpawn(command, args, platform = process.platform, env = pro
|
|
|
443
524
|
return { command: executable, args: [...args], shell: false };
|
|
444
525
|
}
|
|
445
526
|
return {
|
|
446
|
-
command:
|
|
447
|
-
|
|
527
|
+
command: [
|
|
528
|
+
escapeCmdCommand(executable),
|
|
529
|
+
...args.map((arg) => escapeCmdArgument(arg))
|
|
530
|
+
].join(" "),
|
|
531
|
+
args: [],
|
|
448
532
|
shell: true
|
|
449
533
|
};
|
|
450
534
|
}
|
|
@@ -460,7 +544,7 @@ function resolveWindowsExecutable(command, env, cwd) {
|
|
|
460
544
|
) : _path.win32.resolve(cwd, command + extension);
|
|
461
545
|
try {
|
|
462
546
|
if (_fs.statSync.call(void 0, candidate).isFile()) return candidate;
|
|
463
|
-
} catch (
|
|
547
|
+
} catch (e8) {
|
|
464
548
|
}
|
|
465
549
|
}
|
|
466
550
|
}
|
|
@@ -473,7 +557,7 @@ function resolveWindowsExecutable(command, env, cwd) {
|
|
|
473
557
|
|
|
474
558
|
function skillsSyncDisabledPath() {
|
|
475
559
|
return _path.join.call(void 0,
|
|
476
|
-
_optionalChain([process, 'access',
|
|
560
|
+
_optionalChain([process, 'access', _58 => _58.env, 'access', _59 => _59.HOME, 'optionalAccess', _60 => _60.trim, 'call', _61 => _61()]) || _os.homedir.call(void 0, ),
|
|
477
561
|
".local",
|
|
478
562
|
"deepline",
|
|
479
563
|
"sdk-cli",
|
|
@@ -514,25 +598,25 @@ var CHECK_TIMEOUT_MS2 = 3e3;
|
|
|
514
598
|
var INSTALLER_PROBE_TIMEOUT_MS = 1e3;
|
|
515
599
|
var PUBLISHED_VERIFICATION_RETRY_MS = 5 * 6e4;
|
|
516
600
|
function shouldSkipSkillsSync() {
|
|
517
|
-
if (
|
|
601
|
+
if (_chunk5CYZHOKIjs.detectAgentRuntime.call(void 0, ) === "claude_cowork" || isCiEnvironment()) {
|
|
518
602
|
return true;
|
|
519
603
|
}
|
|
520
|
-
const value = _optionalChain([process, 'access',
|
|
604
|
+
const value = _optionalChain([process, 'access', _62 => _62.env, 'access', _63 => _63.DEEPLINE_SKIP_SKILLS_SYNC, 'optionalAccess', _64 => _64.trim, 'call', _65 => _65(), 'access', _66 => _66.toLowerCase, 'call', _67 => _67()]);
|
|
521
605
|
return value === "1" || value === "true" || value === "yes" || value === "on" || !isCliSkillsSyncEnabled();
|
|
522
606
|
}
|
|
523
607
|
function unavailableSkillsNoticePath(baseUrl) {
|
|
524
|
-
return _path.join.call(void 0,
|
|
608
|
+
return _path.join.call(void 0, _chunkVIUUTEHYjs.sdkCliStateDirPath.call(void 0, baseUrl), "skills-sync-unavailable-version");
|
|
525
609
|
}
|
|
526
610
|
var SKILLS_SYNC_IN_PROGRESS_TTL_MS = 10 * 60 * 1e3;
|
|
527
611
|
var SKILLS_SYNC_IN_PROGRESS_PID_CAP_MS = 6 * 60 * 60 * 1e3;
|
|
528
|
-
var agentLeaseSegment =
|
|
612
|
+
var agentLeaseSegment = _chunkVIUUTEHYjs.skillsAgentPathSegment;
|
|
529
613
|
function sortedLeaseAgents(agents) {
|
|
530
|
-
const expanded = agents.includes("*") ? [...agents, ...
|
|
614
|
+
const expanded = agents.includes("*") ? [...agents, ..._chunkVIUUTEHYjs.KNOWN_SKILL_AGENTS] : agents;
|
|
531
615
|
return [...new Set(expanded)].sort((a, b) => a.localeCompare(b));
|
|
532
616
|
}
|
|
533
617
|
function inProgressSkillsSyncPath(baseUrl, agent) {
|
|
534
618
|
return _path.join.call(void 0,
|
|
535
|
-
|
|
619
|
+
_chunkVIUUTEHYjs.sdkCliStateDirPath.call(void 0, baseUrl),
|
|
536
620
|
`skills-sync-in-progress-${agentLeaseSegment(agent)}`
|
|
537
621
|
);
|
|
538
622
|
}
|
|
@@ -592,7 +676,7 @@ function quarantine(path, tag) {
|
|
|
592
676
|
try {
|
|
593
677
|
_fs.renameSync.call(void 0, path, holding);
|
|
594
678
|
return holding;
|
|
595
|
-
} catch (
|
|
679
|
+
} catch (e9) {
|
|
596
680
|
return null;
|
|
597
681
|
}
|
|
598
682
|
}
|
|
@@ -691,7 +775,7 @@ var SkillsStateUnavailableError = class extends Error {
|
|
|
691
775
|
constructor(baseUrl, error) {
|
|
692
776
|
const detail = error instanceof Error ? error.message : String(error);
|
|
693
777
|
super(
|
|
694
|
-
`Could not save skills state in ${
|
|
778
|
+
`Could not save skills state in ${_chunkVIUUTEHYjs.sdkCliStateDirPath.call(void 0, baseUrl)}: ${detail}`
|
|
695
779
|
);
|
|
696
780
|
this.name = "SkillsStateUnavailableError";
|
|
697
781
|
}
|
|
@@ -712,7 +796,7 @@ function recordOwnPidOnInProgressSkillsSync(baseUrl, leases) {
|
|
|
712
796
|
`,
|
|
713
797
|
"utf-8"
|
|
714
798
|
);
|
|
715
|
-
} catch (
|
|
799
|
+
} catch (e10) {
|
|
716
800
|
}
|
|
717
801
|
}
|
|
718
802
|
}
|
|
@@ -722,7 +806,7 @@ function releaseInProgressSkillsSync(baseUrl, claimTokens) {
|
|
|
722
806
|
if (!claimToken) {
|
|
723
807
|
try {
|
|
724
808
|
_fs.rmSync.call(void 0, dir, { recursive: true, force: true });
|
|
725
|
-
} catch (
|
|
809
|
+
} catch (e11) {
|
|
726
810
|
}
|
|
727
811
|
continue;
|
|
728
812
|
}
|
|
@@ -733,7 +817,7 @@ function releaseInProgressSkillsSync(baseUrl, claimTokens) {
|
|
|
733
817
|
_fs.renameSync.call(void 0, tombstone, dir);
|
|
734
818
|
continue;
|
|
735
819
|
}
|
|
736
|
-
} catch (
|
|
820
|
+
} catch (e12) {
|
|
737
821
|
}
|
|
738
822
|
_fs.rmSync.call(void 0, tombstone, { recursive: true, force: true });
|
|
739
823
|
}
|
|
@@ -766,7 +850,7 @@ async function acquireSkillsInstallLease(baseUrl, agents, version, options = {
|
|
|
766
850
|
if (Date.now() >= deadline) return null;
|
|
767
851
|
if (!waited) {
|
|
768
852
|
waited = true;
|
|
769
|
-
_optionalChain([options, 'access',
|
|
853
|
+
_optionalChain([options, 'access', _68 => _68.onWait, 'optionalCall', _69 => _69()]);
|
|
770
854
|
}
|
|
771
855
|
await new Promise((resolve) => setTimeout(resolve, pollMs));
|
|
772
856
|
}
|
|
@@ -776,7 +860,7 @@ function skillsInstallLeasePath(baseUrl, agents) {
|
|
|
776
860
|
}
|
|
777
861
|
function deferredSkillsNoticePath(baseUrl, agents) {
|
|
778
862
|
return _path.join.call(void 0,
|
|
779
|
-
|
|
863
|
+
_chunkVIUUTEHYjs.sdkCliStateDirPath.call(void 0, baseUrl),
|
|
780
864
|
`skills-sync-notice-${sortedLeaseAgents(agents).map(agentLeaseSegment).join("-")}`
|
|
781
865
|
);
|
|
782
866
|
}
|
|
@@ -787,7 +871,7 @@ function deferSkillsNotice(baseUrl, agents) {
|
|
|
787
871
|
_fs.mkdirSync.call(void 0, _path.dirname.call(void 0, path), { recursive: true });
|
|
788
872
|
_fs.appendFileSync.call(void 0, path, `${text.trimEnd()}
|
|
789
873
|
`, "utf-8");
|
|
790
|
-
} catch (
|
|
874
|
+
} catch (e13) {
|
|
791
875
|
}
|
|
792
876
|
};
|
|
793
877
|
}
|
|
@@ -799,19 +883,19 @@ function flushDeferredSkillsNotices(baseUrl, agents) {
|
|
|
799
883
|
let text = "";
|
|
800
884
|
try {
|
|
801
885
|
text = _fs.readFileSync.call(void 0, tombstone, "utf-8");
|
|
802
|
-
} catch (
|
|
886
|
+
} catch (e14) {
|
|
803
887
|
return;
|
|
804
888
|
} finally {
|
|
805
889
|
try {
|
|
806
890
|
_fs.unlinkSync.call(void 0, tombstone);
|
|
807
|
-
} catch (
|
|
891
|
+
} catch (e15) {
|
|
808
892
|
}
|
|
809
893
|
}
|
|
810
894
|
if (text.trim()) writeSdkSkillsStatusLine(text.trimEnd());
|
|
811
895
|
}
|
|
812
896
|
function flushDeferredSkillsSyncNotices(baseUrl) {
|
|
813
|
-
if (shouldSkipSkillsSync() ||
|
|
814
|
-
const agents =
|
|
897
|
+
if (shouldSkipSkillsSync() || _chunkVIUUTEHYjs.hasActivePluginSkills.call(void 0, )) return;
|
|
898
|
+
const agents = _chunkVIUUTEHYjs.resolveAutoSyncSkillAgents.call(void 0, );
|
|
815
899
|
if (agents.length === 0) return;
|
|
816
900
|
flushDeferredSkillsNotices(baseUrl, agents);
|
|
817
901
|
}
|
|
@@ -829,12 +913,12 @@ function spawnDetachedSkillsSyncChild(argv, onSpawnError, sidecarPath) {
|
|
|
829
913
|
env: process.env,
|
|
830
914
|
shell: launch.shell
|
|
831
915
|
});
|
|
832
|
-
child.on("error", () => _optionalChain([onSpawnError, 'optionalCall',
|
|
916
|
+
child.on("error", () => _optionalChain([onSpawnError, 'optionalCall', _70 => _70()]));
|
|
833
917
|
child.unref();
|
|
834
918
|
}
|
|
835
919
|
function failedSkillsSyncPath(baseUrl, agents) {
|
|
836
920
|
return _path.join.call(void 0,
|
|
837
|
-
|
|
921
|
+
_chunkVIUUTEHYjs.sdkCliStateDirPath.call(void 0, baseUrl),
|
|
838
922
|
`skills-sync-failed-${sortedLeaseAgents(agents).map(agentLeaseSegment).join("-")}-version`
|
|
839
923
|
);
|
|
840
924
|
}
|
|
@@ -844,7 +928,7 @@ function hasMarkedSkillsSyncVersion(path, version) {
|
|
|
844
928
|
function readMarkedSkillsSyncVersion(path) {
|
|
845
929
|
try {
|
|
846
930
|
return _fs.existsSync.call(void 0, path) ? _fs.readFileSync.call(void 0, path, "utf-8").trim() : "";
|
|
847
|
-
} catch (
|
|
931
|
+
} catch (e16) {
|
|
848
932
|
return "";
|
|
849
933
|
}
|
|
850
934
|
}
|
|
@@ -854,7 +938,7 @@ function writeMarkedSkillsSyncVersion(path, version) {
|
|
|
854
938
|
_fs.writeFileSync.call(void 0, path, `${version}
|
|
855
939
|
`, "utf-8");
|
|
856
940
|
return true;
|
|
857
|
-
} catch (
|
|
941
|
+
} catch (e17) {
|
|
858
942
|
return false;
|
|
859
943
|
}
|
|
860
944
|
}
|
|
@@ -863,8 +947,8 @@ function writeUnavailableSkillsNotice(baseUrl, remoteVersion, skillNames, reason
|
|
|
863
947
|
if (hasMarkedSkillsSyncVersion(path, remoteVersion)) return;
|
|
864
948
|
writeMarkedSkillsSyncVersion(path, remoteVersion);
|
|
865
949
|
const probes = reason === "no-installer" ? _nullishCoalesce(knownProbes, () => ( probeInstallers())) : null;
|
|
866
|
-
const manualCommand = _optionalChain([probes, 'optionalAccess',
|
|
867
|
-
const explanation = reason === "unsupported-agent" ? "the detected agent has no automatic skills sync target. Automatic sync was skipped." : _optionalChain([probes, 'optionalAccess',
|
|
950
|
+
const manualCommand = _optionalChain([probes, 'optionalAccess', _71 => _71.npx]) === "missing" && probes.bunx !== "missing" ? `bunx ${buildBunxSkillsInstallArgs(baseUrl, skillNames, _chunkVIUUTEHYjs.DEFAULT_SKILL_AGENTS).map(shellQuote).join(" ")}` : `npx ${buildSkillsInstallArgs(baseUrl, skillNames).join(" ")}`;
|
|
951
|
+
const explanation = reason === "unsupported-agent" ? "the detected agent has no automatic skills sync target. Automatic sync was skipped." : _optionalChain([probes, 'optionalAccess', _72 => _72.bunx]) === "missing" && probes.npx === "missing" ? "neither `bunx` nor `npx` was found on PATH. Make one available." : `installer version check failed for ${Object.entries(_nullishCoalesce(probes, () => ( {}))).filter(([, result]) => result === "failed").map(([command]) => `\`${command}\``).join(" and ")}. Check those commands with --version.`;
|
|
868
952
|
notice(
|
|
869
953
|
`Deepline agent skills are out of date, but ${explanation} To install manually, run:
|
|
870
954
|
${manualCommand}`
|
|
@@ -873,7 +957,7 @@ ${manualCommand}`
|
|
|
873
957
|
function clearUnavailableSkillsNotice(baseUrl) {
|
|
874
958
|
try {
|
|
875
959
|
_fs.unlinkSync.call(void 0, unavailableSkillsNoticePath(baseUrl));
|
|
876
|
-
} catch (
|
|
960
|
+
} catch (e18) {
|
|
877
961
|
}
|
|
878
962
|
}
|
|
879
963
|
function hasFailedSkillsSync(baseUrl, remoteVersion, agents) {
|
|
@@ -885,7 +969,7 @@ function hasFailedSkillsSync(baseUrl, remoteVersion, agents) {
|
|
|
885
969
|
const retry = JSON.parse(marked);
|
|
886
970
|
const now = Date.now();
|
|
887
971
|
return retry.version === remoteVersion && typeof retry.retryAfter === "number" && retry.retryAfter > now && retry.retryAfter <= now + PUBLISHED_VERIFICATION_RETRY_MS;
|
|
888
|
-
} catch (
|
|
972
|
+
} catch (e19) {
|
|
889
973
|
return false;
|
|
890
974
|
}
|
|
891
975
|
}
|
|
@@ -910,7 +994,7 @@ function deferPublishedVerificationRetry(baseUrl, remoteVersion, agents) {
|
|
|
910
994
|
function clearFailedSkillsSync(baseUrl, agents) {
|
|
911
995
|
try {
|
|
912
996
|
_fs.unlinkSync.call(void 0, failedSkillsSyncPath(baseUrl, agents));
|
|
913
|
-
} catch (
|
|
997
|
+
} catch (e20) {
|
|
914
998
|
}
|
|
915
999
|
}
|
|
916
1000
|
function clearFailedAutomaticSkillsSync(baseUrl, agents) {
|
|
@@ -933,14 +1017,14 @@ async function fetchV1SkillIndex(baseUrl) {
|
|
|
933
1017
|
if (!response.ok) return null;
|
|
934
1018
|
const data = await response.json().catch(() => null);
|
|
935
1019
|
return data;
|
|
936
|
-
} catch (
|
|
1020
|
+
} catch (e21) {
|
|
937
1021
|
return null;
|
|
938
1022
|
} finally {
|
|
939
1023
|
clearTimeout(timeout);
|
|
940
1024
|
}
|
|
941
1025
|
}
|
|
942
1026
|
function v1SkillNames(index) {
|
|
943
|
-
const skills = Array.isArray(_optionalChain([index, 'optionalAccess',
|
|
1027
|
+
const skills = Array.isArray(_optionalChain([index, 'optionalAccess', _73 => _73.skills])) ? index.skills : [];
|
|
944
1028
|
return sortedUniqueSkillNames(
|
|
945
1029
|
skills.filter((skill) => skill && skill.install_surface === "v1").map((skill) => skill.name).filter(
|
|
946
1030
|
(name) => typeof name === "string" && name.length > 0
|
|
@@ -951,7 +1035,7 @@ function buildSdkSkillNames(v1SkillNames2) {
|
|
|
951
1035
|
return sortedUniqueSkillNames(v1SkillNames2);
|
|
952
1036
|
}
|
|
953
1037
|
function isDefaultAgentSet(agents) {
|
|
954
|
-
return agents.length ===
|
|
1038
|
+
return agents.length === _chunkVIUUTEHYjs.DEFAULT_SKILL_AGENTS.length && agents.every((agent, index) => agent === _chunkVIUUTEHYjs.DEFAULT_SKILL_AGENTS[index]);
|
|
955
1039
|
}
|
|
956
1040
|
function safeSkillFilePath(value) {
|
|
957
1041
|
if (typeof value !== "string" || !value) return false;
|
|
@@ -1011,7 +1095,7 @@ function publishedArchiveFiles(bytes, expectedFiles, name) {
|
|
|
1011
1095
|
var PublishedSkillsVerificationError = class extends Error {
|
|
1012
1096
|
};
|
|
1013
1097
|
async function verifyDefaultAgentSkillsInstall(baseUrl, remoteVersion, skillNames, index) {
|
|
1014
|
-
if (_optionalChain([index, 'optionalAccess',
|
|
1098
|
+
if (_optionalChain([index, 'optionalAccess', _74 => _74.version]) !== remoteVersion) {
|
|
1015
1099
|
throw new PublishedSkillsVerificationError(
|
|
1016
1100
|
"the published skill index version does not match the server version"
|
|
1017
1101
|
);
|
|
@@ -1027,7 +1111,7 @@ async function verifyDefaultAgentSkillsInstall(baseUrl, remoteVersion, skillName
|
|
|
1027
1111
|
const entry = entries.find(
|
|
1028
1112
|
(skill) => skill && skill.name === name && skill.install_surface === "v1"
|
|
1029
1113
|
);
|
|
1030
|
-
if (!Array.isArray(_optionalChain([entry, 'optionalAccess',
|
|
1114
|
+
if (!Array.isArray(_optionalChain([entry, 'optionalAccess', _75 => _75.files])) || !entry.files.length || !entry.files.every(safeSkillFilePath) || new Set(entry.files).size !== entry.files.length || !entry.files.includes("SKILL.md") || entry.type !== "archive" || entry.url !== `./archives/${name}.tar.gz` || typeof entry.digest !== "string" || !/^sha256:[a-f0-9]{64}$/.test(entry.digest)) {
|
|
1031
1115
|
throw new PublishedSkillsVerificationError(
|
|
1032
1116
|
`invalid published file list for ${name}`
|
|
1033
1117
|
);
|
|
@@ -1081,7 +1165,7 @@ async function verifyDefaultAgentSkillsInstall(baseUrl, remoteVersion, skillName
|
|
|
1081
1165
|
controller.abort();
|
|
1082
1166
|
}
|
|
1083
1167
|
const home = _os.homedir.call(void 0, );
|
|
1084
|
-
const claudeConfigDir = _optionalChain([process, 'access',
|
|
1168
|
+
const claudeConfigDir = _optionalChain([process, 'access', _76 => _76.env, 'access', _77 => _77.CLAUDE_CONFIG_DIR, 'optionalAccess', _78 => _78.trim, 'call', _79 => _79()]) || _path.join.call(void 0, home, ".claude");
|
|
1085
1169
|
for (const [name, { files }] of published) {
|
|
1086
1170
|
for (const root of [
|
|
1087
1171
|
_path.join.call(void 0, home, ".agents", "skills", name),
|
|
@@ -1108,23 +1192,23 @@ async function fetchSkillsUpdate(baseUrl, localVersion) {
|
|
|
1108
1192
|
method: "POST",
|
|
1109
1193
|
headers: { "Content-Type": "application/json" },
|
|
1110
1194
|
body: JSON.stringify({
|
|
1111
|
-
sdk_cli: { version:
|
|
1195
|
+
sdk_cli: { version: _chunk5CYZHOKIjs.SDK_VERSION },
|
|
1112
1196
|
skills: {
|
|
1113
1197
|
version: localVersion,
|
|
1114
|
-
capability:
|
|
1198
|
+
capability: _chunkUNNOZKRTjs.SDK_RELEASE.packageCapabilities.skillsGuidance
|
|
1115
1199
|
}
|
|
1116
1200
|
}),
|
|
1117
1201
|
signal: controller.signal
|
|
1118
1202
|
});
|
|
1119
1203
|
if (!response.ok) return null;
|
|
1120
1204
|
const data = await response.json().catch(() => null);
|
|
1121
|
-
const skills = _optionalChain([data, 'optionalAccess',
|
|
1205
|
+
const skills = _optionalChain([data, 'optionalAccess', _80 => _80.skills]);
|
|
1122
1206
|
if (!skills) return null;
|
|
1123
1207
|
return {
|
|
1124
1208
|
needsUpdate: skills.needs_update === true,
|
|
1125
|
-
remoteVersion: typeof _optionalChain([skills, 'access',
|
|
1209
|
+
remoteVersion: typeof _optionalChain([skills, 'access', _81 => _81.remote, 'optionalAccess', _82 => _82.version]) === "string" ? skills.remote.version.trim() : ""
|
|
1126
1210
|
};
|
|
1127
|
-
} catch (
|
|
1211
|
+
} catch (e22) {
|
|
1128
1212
|
return null;
|
|
1129
1213
|
} finally {
|
|
1130
1214
|
clearTimeout(timeout);
|
|
@@ -1150,7 +1234,7 @@ function probeInstallers(timeoutMs) {
|
|
|
1150
1234
|
}
|
|
1151
1235
|
function noInstallerProbePath(baseUrl) {
|
|
1152
1236
|
return _path.join.call(void 0,
|
|
1153
|
-
|
|
1237
|
+
_chunkVIUUTEHYjs.sdkCliStateDirPath.call(void 0, baseUrl),
|
|
1154
1238
|
"skills-sync-no-installer-unknown.json"
|
|
1155
1239
|
);
|
|
1156
1240
|
}
|
|
@@ -1158,12 +1242,12 @@ function cachedUnavailableInstallerProbes(baseUrl, remoteVersion, allowBoundedFa
|
|
|
1158
1242
|
const path = noInstallerProbePath(baseUrl);
|
|
1159
1243
|
try {
|
|
1160
1244
|
const cached = JSON.parse(_fs.readFileSync.call(void 0, path, "utf-8"));
|
|
1161
|
-
if (typeof cached.version === "string" && (!remoteVersion || cached.version === remoteVersion) && typeof cached.checkedAt === "number" && cached.checkedAt <= Date.now() && Date.now() - cached.checkedAt < NEGATIVE_INSTALLER_PROBE_TTL_MS && (_optionalChain([cached, 'access',
|
|
1245
|
+
if (typeof cached.version === "string" && (!remoteVersion || cached.version === remoteVersion) && typeof cached.checkedAt === "number" && cached.checkedAt <= Date.now() && Date.now() - cached.checkedAt < NEGATIVE_INSTALLER_PROBE_TTL_MS && (_optionalChain([cached, 'access', _83 => _83.probes, 'optionalAccess', _84 => _84.bunx]) === "missing" || _optionalChain([cached, 'access', _85 => _85.probes, 'optionalAccess', _86 => _86.bunx]) === "failed") && (_optionalChain([cached, 'access', _87 => _87.probes, 'optionalAccess', _88 => _88.npx]) === "missing" || _optionalChain([cached, 'access', _89 => _89.probes, 'optionalAccess', _90 => _90.npx]) === "failed") && // A terminal timeout is not evidence that the unbounded child probe
|
|
1162
1246
|
// will fail. Older caches without probe provenance are ambiguous too.
|
|
1163
1247
|
(allowBoundedFailures || cached.probeTimeoutMs === null || cached.probes.bunx === "missing" && cached.probes.npx === "missing")) {
|
|
1164
1248
|
return cached.probes;
|
|
1165
1249
|
}
|
|
1166
|
-
} catch (
|
|
1250
|
+
} catch (e23) {
|
|
1167
1251
|
}
|
|
1168
1252
|
return null;
|
|
1169
1253
|
}
|
|
@@ -1182,14 +1266,14 @@ function rememberUnavailableInstallerProbes(baseUrl, remoteVersion, probes, prob
|
|
|
1182
1266
|
}),
|
|
1183
1267
|
"utf-8"
|
|
1184
1268
|
);
|
|
1185
|
-
} catch (
|
|
1269
|
+
} catch (e24) {
|
|
1186
1270
|
}
|
|
1187
1271
|
}
|
|
1188
1272
|
}
|
|
1189
1273
|
function clearUnavailableInstallerProbes(baseUrl) {
|
|
1190
1274
|
try {
|
|
1191
1275
|
_fs.unlinkSync.call(void 0, noInstallerProbePath(baseUrl));
|
|
1192
|
-
} catch (
|
|
1276
|
+
} catch (e25) {
|
|
1193
1277
|
}
|
|
1194
1278
|
}
|
|
1195
1279
|
function dueUnknownInstallerProbes(baseUrl, remoteVersion) {
|
|
@@ -1213,7 +1297,7 @@ function probeCommand(command, timeoutMs) {
|
|
|
1213
1297
|
timeout: timeoutMs
|
|
1214
1298
|
});
|
|
1215
1299
|
if (result.status === 0) return "available";
|
|
1216
|
-
return _optionalChain([result, 'access',
|
|
1300
|
+
return _optionalChain([result, 'access', _91 => _91.error, 'optionalAccess', _92 => _92.code]) === "ENOENT" ? "missing" : "failed";
|
|
1217
1301
|
}
|
|
1218
1302
|
function hasCommand(command) {
|
|
1219
1303
|
return probeCommand(command) === "available";
|
|
@@ -1230,7 +1314,7 @@ function temporarySkillsSyncSkipCommand() {
|
|
|
1230
1314
|
function resolveSkillsInstallSpawn(install, platform = process.platform) {
|
|
1231
1315
|
return resolveShellSpawn(install.command, install.args, platform);
|
|
1232
1316
|
}
|
|
1233
|
-
function resolveSkillsInstallCommands(baseUrl, skillNames = DEFAULT_SDK_SKILL_NAMES, agents =
|
|
1317
|
+
function resolveSkillsInstallCommands(baseUrl, skillNames = DEFAULT_SDK_SKILL_NAMES, agents = _chunkVIUUTEHYjs.DEFAULT_SKILL_AGENTS, knownProbes) {
|
|
1234
1318
|
const commands = [];
|
|
1235
1319
|
const probes = _nullishCoalesce(knownProbes, () => ( probeInstallers()));
|
|
1236
1320
|
if (probes.bunx === "available") {
|
|
@@ -1374,7 +1458,7 @@ function runLegacySkillsCleanup(agents) {
|
|
|
1374
1458
|
}
|
|
1375
1459
|
}
|
|
1376
1460
|
function writeSdkSkillsStatusLine(line) {
|
|
1377
|
-
const progress =
|
|
1461
|
+
const progress = _chunkPQQMPUCZjs.getActiveCliProgress.call(void 0, );
|
|
1378
1462
|
if (progress) {
|
|
1379
1463
|
progress.writeLine(line);
|
|
1380
1464
|
return;
|
|
@@ -1385,11 +1469,11 @@ function writeSdkSkillsStatusLine(line) {
|
|
|
1385
1469
|
async function syncSdkSkillsIfNeeded(baseUrl, options = {}) {
|
|
1386
1470
|
const skip = shouldSkipSkillsSync();
|
|
1387
1471
|
if (skip && !options.claim) return;
|
|
1388
|
-
const usingPluginSkills =
|
|
1472
|
+
const usingPluginSkills = _chunkVIUUTEHYjs.hasActivePluginSkills.call(void 0, );
|
|
1389
1473
|
if (usingPluginSkills) {
|
|
1390
1474
|
return;
|
|
1391
1475
|
}
|
|
1392
|
-
const agents =
|
|
1476
|
+
const agents = _chunkVIUUTEHYjs.resolveAutoSyncSkillAgents.call(void 0, );
|
|
1393
1477
|
if (options.mode === "detached" && agents.length > 0) {
|
|
1394
1478
|
flushDeferredSkillsNotices(baseUrl, agents);
|
|
1395
1479
|
}
|
|
@@ -1410,7 +1494,7 @@ async function syncSdkSkillsIfNeeded(baseUrl, options = {}) {
|
|
|
1410
1494
|
const spawnDetached = _nullishCoalesce(options.spawnDetached, () => ( ((argv, onSpawnError) => spawnDetachedSkillsSyncChild(
|
|
1411
1495
|
argv,
|
|
1412
1496
|
onSpawnError,
|
|
1413
|
-
_optionalChain([options, 'access',
|
|
1497
|
+
_optionalChain([options, 'access', _93 => _93.afterCliUpdate, 'optionalAccess', _94 => _94.sidecarPath])
|
|
1414
1498
|
))));
|
|
1415
1499
|
if (options.mode === "detached" && agents.length > 0 && options.update === void 0 && !claimedVersion) {
|
|
1416
1500
|
if (cachedUnavailableInstallerProbes(baseUrl)) return;
|
|
@@ -1426,12 +1510,12 @@ async function syncSdkSkillsIfNeeded(baseUrl, options = {}) {
|
|
|
1426
1510
|
return;
|
|
1427
1511
|
}
|
|
1428
1512
|
try {
|
|
1429
|
-
const localVersion =
|
|
1513
|
+
const localVersion = _chunkVIUUTEHYjs.readSdkSkillsLocalVersion.call(void 0, baseUrl);
|
|
1430
1514
|
const update = options.update === void 0 ? claimedVersion ? { needsUpdate: true, remoteVersion: claimedVersion } : await fetchSkillsUpdate(baseUrl, localVersion) : options.update ? {
|
|
1431
1515
|
needsUpdate: options.update.needs_update,
|
|
1432
1516
|
remoteVersion: options.update.remote.version
|
|
1433
1517
|
} : null;
|
|
1434
|
-
if (!_optionalChain([update, 'optionalAccess',
|
|
1518
|
+
if (!_optionalChain([update, 'optionalAccess', _95 => _95.needsUpdate]) || !update.remoteVersion || update.remoteVersion === localVersion) {
|
|
1435
1519
|
return;
|
|
1436
1520
|
}
|
|
1437
1521
|
if (agents.length > 0 && hasFailedSkillsSync(baseUrl, update.remoteVersion, agents)) {
|
|
@@ -1548,7 +1632,7 @@ async function runInlineSkillsSync(baseUrl, remoteVersion, agents, notices) {
|
|
|
1548
1632
|
update.remoteVersion,
|
|
1549
1633
|
agents
|
|
1550
1634
|
);
|
|
1551
|
-
void
|
|
1635
|
+
void _chunkYQKCH4R7js.maybeReportAutomaticSkillsSyncFailure.call(void 0, {
|
|
1552
1636
|
baseUrl,
|
|
1553
1637
|
remoteSkillsVersion: update.remoteVersion,
|
|
1554
1638
|
agents,
|
|
@@ -1579,7 +1663,7 @@ async function runInlineSkillsSync(baseUrl, remoteVersion, agents, notices) {
|
|
|
1579
1663
|
notice(
|
|
1580
1664
|
publishedFailure ? `Deepline could not verify the published skills: ${detail}. The local version remains stale; it will retry automatically on a later command.` : `Deepline agent-skills refresh could not verify the five installed targets: ${detail}. The local version remains stale. After fixing the install, remove ${failedSkillsSyncPath(baseUrl, agents)} to retry this version automatically.`
|
|
1581
1665
|
);
|
|
1582
|
-
void
|
|
1666
|
+
void _chunkYQKCH4R7js.maybeReportAutomaticSkillsSyncFailure.call(void 0, {
|
|
1583
1667
|
baseUrl,
|
|
1584
1668
|
remoteSkillsVersion: update.remoteVersion,
|
|
1585
1669
|
agents,
|
|
@@ -1592,7 +1676,7 @@ async function runInlineSkillsSync(baseUrl, remoteVersion, agents, notices) {
|
|
|
1592
1676
|
}
|
|
1593
1677
|
}
|
|
1594
1678
|
runLegacySkillsCleanup(agents);
|
|
1595
|
-
if (!
|
|
1679
|
+
if (!_chunkVIUUTEHYjs.writeSdkSkillsLocalVersion.call(void 0, baseUrl, update.remoteVersion, agents)) {
|
|
1596
1680
|
notice(
|
|
1597
1681
|
"Deepline agent skills installed, but the local skills version could not be recorded. A later command will retry the refresh."
|
|
1598
1682
|
);
|
|
@@ -1627,4 +1711,5 @@ async function runInlineSkillsSync(baseUrl, remoteVersion, agents, notices) {
|
|
|
1627
1711
|
|
|
1628
1712
|
|
|
1629
1713
|
|
|
1630
|
-
|
|
1714
|
+
|
|
1715
|
+
exports.SDK_COMPATIBILITY_FAST_DEADLINE_MS = SDK_COMPATIBILITY_FAST_DEADLINE_MS; exports.readFreshCleanCompatibility = readFreshCleanCompatibility; exports.readTrustedCleanCompatibility = readTrustedCleanCompatibility; exports.claimUpdateAdvisory = claimUpdateAdvisory; exports.checkSdkCompatibility = checkSdkCompatibility; exports.requireSdkCompatibility = requireSdkCompatibility; exports.isCiEnvironment = isCiEnvironment; exports.enforceSdkCompatibilityResponse = enforceSdkCompatibilityResponse; exports.SKILLS_NPX_PACKAGE = SKILLS_NPX_PACKAGE; exports.DEFAULT_SDK_SKILL_NAMES = DEFAULT_SDK_SKILL_NAMES; exports.LEGACY_SKILL_NAMES_TO_REMOVE = LEGACY_SKILL_NAMES_TO_REMOVE; exports.skillsSourceUrl = skillsSourceUrl; exports.resolveShellSpawn = resolveShellSpawn; exports.isCliSkillsSyncEnabled = isCliSkillsSyncEnabled; exports.setCliSkillsSyncEnabled = setCliSkillsSyncEnabled; exports.SkillsStateUnavailableError = SkillsStateUnavailableError; exports.acquireSkillsInstallLease = acquireSkillsInstallLease; exports.skillsInstallLeasePath = skillsInstallLeasePath; exports.flushDeferredSkillsSyncNotices = flushDeferredSkillsSyncNotices; exports.SKILLS_AUTO_SYNC_COMMAND = SKILLS_AUTO_SYNC_COMMAND; exports.hasFailedAutomaticSkillsSync = hasFailedAutomaticSkillsSync; exports.clearFailedAutomaticSkillsSync = clearFailedAutomaticSkillsSync; exports.syncSdkSkillsIfNeeded = syncSdkSkillsIfNeeded;
|