deepline 0.3.87 → 0.3.89
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.ts +532 -2
- package/dist/bundling-sources/sdk/src/config.ts +77 -0
- package/dist/bundling-sources/sdk/src/http.ts +76 -30
- package/dist/bundling-sources/sdk/src/index.ts +6 -0
- package/dist/bundling-sources/sdk/src/play.ts +15 -1
- package/dist/bundling-sources/sdk/src/plays/bundle-play-file.ts +1 -1
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/sdk/src/types.ts +83 -4
- package/dist/bundling-sources/shared_libs/monitors/deactivation-reasons.ts +16 -0
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-batch-operation.ts +263 -0
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-identity-claims.ts +9 -1
- package/dist/bundling-sources/shared_libs/monitors/provider-monitor-state.ts +122 -0
- package/dist/bundling-sources/shared_libs/play-runtime/activity-observation.ts +6 -11
- package/dist/bundling-sources/shared_libs/play-runtime/app-runtime-api.ts +90 -12
- package/dist/bundling-sources/shared_libs/play-runtime/async-play-invocation.ts +78 -0
- package/dist/bundling-sources/shared_libs/play-runtime/checkpoint-boundaries.ts +70 -0
- package/dist/bundling-sources/shared_libs/play-runtime/context.ts +407 -53
- package/dist/bundling-sources/shared_libs/play-runtime/coordinator-headers.ts +1 -32
- package/dist/bundling-sources/shared_libs/play-runtime/ctx-types.ts +57 -0
- package/dist/bundling-sources/shared_libs/play-runtime/default-batch-strategies.ts +20 -1
- package/dist/bundling-sources/shared_libs/play-runtime/execution-capabilities.ts +6 -0
- package/dist/bundling-sources/shared_libs/play-runtime/execution-protocol.ts +7 -1
- package/dist/bundling-sources/shared_libs/play-runtime/lane-retirement-gate.ts +189 -0
- package/dist/bundling-sources/shared_libs/play-runtime/play-runtime-semantics.ts +28 -0
- package/dist/bundling-sources/shared_libs/play-runtime/protocol.ts +2 -0
- package/dist/bundling-sources/shared_libs/play-runtime/run-failure.ts +23 -0
- package/dist/bundling-sources/shared_libs/play-runtime/run-snapshot-stream.ts +1 -1
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-lifecycle.ts +18 -4
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-start-admission.ts +68 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona.ts +2 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/runtime-sandbox-reconciliation.ts +1 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-api.ts +10 -8
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-capacity-policy.ts +20 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-contract.ts +6 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-scheduler-topology.ts +24 -0
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backend.ts +30 -1
- package/dist/bundling-sources/shared_libs/plays/artifact-types.ts +6 -3
- package/dist/bundling-sources/shared_libs/plays/authoring-contract.ts +152 -17
- package/dist/bundling-sources/shared_libs/plays/bundling/index.ts +19 -4
- package/dist/bundling-sources/shared_libs/plays/contracts.ts +6 -14
- package/dist/bundling-sources/shared_libs/plays/core.ts +11 -6
- package/dist/bundling-sources/shared_libs/plays/docflow-binding-owner.ts +16 -11
- package/dist/bundling-sources/shared_libs/plays/resolve-static-pipeline.ts +1 -1
- package/dist/bundling-sources/shared_libs/plays/slug.ts +115 -0
- package/dist/bundling-sources/shared_libs/plays/static-pipeline.ts +44 -14
- package/dist/bundling-sources/shared_libs/product-notifications/catalog.ts +877 -0
- package/dist/bundling-sources/shared_libs/product-notifications/configuration-draft.ts +456 -0
- package/dist/bundling-sources/shared_libs/product-notifications/configuration.ts +560 -0
- package/dist/bundling-sources/shared_libs/product-notifications/content.ts +28 -0
- package/dist/bundling-sources/shared_libs/product-notifications/default-policy.ts +59 -0
- package/dist/bundling-sources/shared_libs/product-notifications/email.ts +246 -0
- package/dist/bundling-sources/shared_libs/product-notifications/evaluation.ts +280 -0
- package/dist/bundling-sources/shared_libs/product-notifications/events.ts +433 -0
- package/dist/bundling-sources/shared_libs/product-notifications/legacy-slack.ts +80 -0
- package/dist/bundling-sources/shared_libs/product-notifications/workspace.ts +38 -0
- package/dist/bundling-sources/shared_libs/security/internal-actor.ts +50 -0
- package/dist/cli/index.js +1065 -190
- package/dist/cli/index.mjs +1052 -177
- package/dist/{compiler-manifest-Dbov16F7.d.mts → compiler-manifest-DsLbQaew.d.mts} +132 -8
- package/dist/{compiler-manifest-Dbov16F7.d.ts → compiler-manifest-DsLbQaew.d.ts} +132 -8
- package/dist/index.d.mts +833 -11
- package/dist/index.d.ts +833 -11
- package/dist/index.js +467 -38
- package/dist/index.mjs +467 -38
- package/dist/install-integrity.json +20 -2
- package/dist/plays/bundle-play-file.d.mts +8 -3
- package/dist/plays/bundle-play-file.d.ts +8 -3
- package/dist/plays/bundle-play-file.mjs +100 -20
- package/package.json +1 -1
|
@@ -50,6 +50,7 @@
|
|
|
50
50
|
"dist/bundling-sources/shared_libs/monitors/org-monitor-limits.ts",
|
|
51
51
|
"dist/bundling-sources/shared_libs/monitors/package.json",
|
|
52
52
|
"dist/bundling-sources/shared_libs/monitors/provider-callback-verification.ts",
|
|
53
|
+
"dist/bundling-sources/shared_libs/monitors/provider-monitor-batch-operation.ts",
|
|
53
54
|
"dist/bundling-sources/shared_libs/monitors/provider-monitor-capability.ts",
|
|
54
55
|
"dist/bundling-sources/shared_libs/monitors/provider-monitor-consumer-health.ts",
|
|
55
56
|
"dist/bundling-sources/shared_libs/monitors/provider-monitor-errors.ts",
|
|
@@ -58,6 +59,7 @@
|
|
|
58
59
|
"dist/bundling-sources/shared_libs/monitors/provider-monitor-priority-execution.ts",
|
|
59
60
|
"dist/bundling-sources/shared_libs/monitors/provider-monitor-public-aliases.ts",
|
|
60
61
|
"dist/bundling-sources/shared_libs/monitors/provider-monitor-runtime-read-eligibility.ts",
|
|
62
|
+
"dist/bundling-sources/shared_libs/monitors/provider-monitor-state.ts",
|
|
61
63
|
"dist/bundling-sources/shared_libs/monitors/provider-monitor-status.ts",
|
|
62
64
|
"dist/bundling-sources/shared_libs/monitors/provider-monitor-upstream-identity.ts",
|
|
63
65
|
"dist/bundling-sources/shared_libs/monitors/provider-webhook-monitor-runtime.ts",
|
|
@@ -84,6 +86,7 @@
|
|
|
84
86
|
"dist/bundling-sources/shared_libs/play-runtime/activity-observation.ts",
|
|
85
87
|
"dist/bundling-sources/shared_libs/play-runtime/app-runtime-api.ts",
|
|
86
88
|
"dist/bundling-sources/shared_libs/play-runtime/async-operation.ts",
|
|
89
|
+
"dist/bundling-sources/shared_libs/play-runtime/async-play-invocation.ts",
|
|
87
90
|
"dist/bundling-sources/shared_libs/play-runtime/auth-scope-resolver.ts",
|
|
88
91
|
"dist/bundling-sources/shared_libs/play-runtime/backend.ts",
|
|
89
92
|
"dist/bundling-sources/shared_libs/play-runtime/batch-runtime.ts",
|
|
@@ -93,6 +96,7 @@
|
|
|
93
96
|
"dist/bundling-sources/shared_libs/play-runtime/builtin-pacing.ts",
|
|
94
97
|
"dist/bundling-sources/shared_libs/play-runtime/cell-provenance.ts",
|
|
95
98
|
"dist/bundling-sources/shared_libs/play-runtime/cell-staleness.ts",
|
|
99
|
+
"dist/bundling-sources/shared_libs/play-runtime/checkpoint-boundaries.ts",
|
|
96
100
|
"dist/bundling-sources/shared_libs/play-runtime/child-execution-strategy.ts",
|
|
97
101
|
"dist/bundling-sources/shared_libs/play-runtime/context.ts",
|
|
98
102
|
"dist/bundling-sources/shared_libs/play-runtime/coordinator-headers.ts",
|
|
@@ -134,6 +138,7 @@
|
|
|
134
138
|
"dist/bundling-sources/shared_libs/play-runtime/governor/policy.ts",
|
|
135
139
|
"dist/bundling-sources/shared_libs/play-runtime/governor/rate-state-backend.ts",
|
|
136
140
|
"dist/bundling-sources/shared_libs/play-runtime/internal-step-ids.ts",
|
|
141
|
+
"dist/bundling-sources/shared_libs/play-runtime/lane-retirement-gate.ts",
|
|
137
142
|
"dist/bundling-sources/shared_libs/play-runtime/lease-policy.ts",
|
|
138
143
|
"dist/bundling-sources/shared_libs/play-runtime/ledger-safe-payload.ts",
|
|
139
144
|
"dist/bundling-sources/shared_libs/play-runtime/live-events.ts",
|
|
@@ -183,6 +188,7 @@
|
|
|
183
188
|
"dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-payload-transport.ts",
|
|
184
189
|
"dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-runtime-watchdog.ts",
|
|
185
190
|
"dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-session-execution.ts",
|
|
191
|
+
"dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-start-admission.ts",
|
|
186
192
|
"dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona.ts",
|
|
187
193
|
"dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/local-process.ts",
|
|
188
194
|
"dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/modal.ts",
|
|
@@ -291,6 +297,7 @@
|
|
|
291
297
|
"dist/bundling-sources/shared_libs/plays/runtime-validation.ts",
|
|
292
298
|
"dist/bundling-sources/shared_libs/plays/sandbox-runtime-limits.ts",
|
|
293
299
|
"dist/bundling-sources/shared_libs/plays/secret-guardrails.ts",
|
|
300
|
+
"dist/bundling-sources/shared_libs/plays/slug.ts",
|
|
294
301
|
"dist/bundling-sources/shared_libs/plays/static-pipeline-storage-codec.ts",
|
|
295
302
|
"dist/bundling-sources/shared_libs/plays/static-pipeline.ts",
|
|
296
303
|
"dist/bundling-sources/shared_libs/plays/tool-category-descriptions.ts",
|
|
@@ -300,9 +307,20 @@
|
|
|
300
307
|
"dist/bundling-sources/shared_libs/plays/tool-result-types.ts",
|
|
301
308
|
"dist/bundling-sources/shared_libs/plays/ts-ast.ts",
|
|
302
309
|
"dist/bundling-sources/shared_libs/plays/user-code-safety.ts",
|
|
310
|
+
"dist/bundling-sources/shared_libs/product-notifications/catalog.ts",
|
|
311
|
+
"dist/bundling-sources/shared_libs/product-notifications/configuration-draft.ts",
|
|
312
|
+
"dist/bundling-sources/shared_libs/product-notifications/configuration.ts",
|
|
313
|
+
"dist/bundling-sources/shared_libs/product-notifications/content.ts",
|
|
303
314
|
"dist/bundling-sources/shared_libs/product-notifications/contract.ts",
|
|
315
|
+
"dist/bundling-sources/shared_libs/product-notifications/default-policy.ts",
|
|
316
|
+
"dist/bundling-sources/shared_libs/product-notifications/email.ts",
|
|
317
|
+
"dist/bundling-sources/shared_libs/product-notifications/evaluation.ts",
|
|
318
|
+
"dist/bundling-sources/shared_libs/product-notifications/events.ts",
|
|
319
|
+
"dist/bundling-sources/shared_libs/product-notifications/legacy-slack.ts",
|
|
320
|
+
"dist/bundling-sources/shared_libs/product-notifications/workspace.ts",
|
|
304
321
|
"dist/bundling-sources/shared_libs/runtime-env.ts",
|
|
305
322
|
"dist/bundling-sources/shared_libs/security/header-safe-env.ts",
|
|
323
|
+
"dist/bundling-sources/shared_libs/security/internal-actor.ts",
|
|
306
324
|
"dist/bundling-sources/shared_libs/security/outbound-url-policy.ts",
|
|
307
325
|
"dist/bundling-sources/shared_libs/security/safe-fetch.ts",
|
|
308
326
|
"dist/bundling-sources/shared_libs/security/safe-outbound-fetch.ts",
|
|
@@ -313,8 +331,8 @@
|
|
|
313
331
|
"dist/cli/index.js",
|
|
314
332
|
"dist/cli/index.mjs",
|
|
315
333
|
"dist/cli/text-imports.d.ts",
|
|
316
|
-
"dist/compiler-manifest-
|
|
317
|
-
"dist/compiler-manifest-
|
|
334
|
+
"dist/compiler-manifest-DsLbQaew.d.mts",
|
|
335
|
+
"dist/compiler-manifest-DsLbQaew.d.ts",
|
|
318
336
|
"dist/helpers.d.mts",
|
|
319
337
|
"dist/helpers.d.ts",
|
|
320
338
|
"dist/helpers.js",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference path="./text-imports.d.ts" />
|
|
2
|
-
import { P as PlayArtifactKind, a as PlayBundleArtifact, b as PlaySandboxRuntimeDeclaration, c as PlayCompilerManifest } from '../compiler-manifest-
|
|
3
|
-
export { d as PLAY_ARTIFACT_KINDS, e as PlayArtifactCompatibility, f as PlayImportPolicy, g as PlayPackageImport, h as PlayRuntimeFeature } from '../compiler-manifest-
|
|
2
|
+
import { P as PlayArtifactKind, a as PlayBundleArtifact, b as PlaySandboxRuntimeDeclaration, c as PlayCompilerManifest } from '../compiler-manifest-DsLbQaew.mjs';
|
|
3
|
+
export { d as PLAY_ARTIFACT_KINDS, e as PlayArtifactCompatibility, f as PlayImportPolicy, g as PlayPackageImport, h as PlayRuntimeFeature } from '../compiler-manifest-DsLbQaew.mjs';
|
|
4
4
|
import '@sinclair/typebox';
|
|
5
5
|
|
|
6
6
|
type ImportedPlayDependency = {
|
|
@@ -25,7 +25,12 @@ type PlayLocalFileDiscoveryResult = {
|
|
|
25
25
|
};
|
|
26
26
|
type PlayBundlingAdapter = {
|
|
27
27
|
projectRoot: string;
|
|
28
|
-
/**
|
|
28
|
+
/**
|
|
29
|
+
* Optional root that makes the artifact independent of where it was built:
|
|
30
|
+
* source paths in the graph hash and esbuild's working directory (which it
|
|
31
|
+
* writes into every module-header comment, and so into `artifactHash`) are
|
|
32
|
+
* both taken relative to it instead of to the build's absolute location.
|
|
33
|
+
*/
|
|
29
34
|
sourceIdentityRoot?: string;
|
|
30
35
|
nodeModulesDir: string;
|
|
31
36
|
cacheDir?: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference path="./text-imports.d.ts" />
|
|
2
|
-
import { P as PlayArtifactKind, a as PlayBundleArtifact, b as PlaySandboxRuntimeDeclaration, c as PlayCompilerManifest } from '../compiler-manifest-
|
|
3
|
-
export { d as PLAY_ARTIFACT_KINDS, e as PlayArtifactCompatibility, f as PlayImportPolicy, g as PlayPackageImport, h as PlayRuntimeFeature } from '../compiler-manifest-
|
|
2
|
+
import { P as PlayArtifactKind, a as PlayBundleArtifact, b as PlaySandboxRuntimeDeclaration, c as PlayCompilerManifest } from '../compiler-manifest-DsLbQaew.js';
|
|
3
|
+
export { d as PLAY_ARTIFACT_KINDS, e as PlayArtifactCompatibility, f as PlayImportPolicy, g as PlayPackageImport, h as PlayRuntimeFeature } from '../compiler-manifest-DsLbQaew.js';
|
|
4
4
|
import '@sinclair/typebox';
|
|
5
5
|
|
|
6
6
|
type ImportedPlayDependency = {
|
|
@@ -25,7 +25,12 @@ type PlayLocalFileDiscoveryResult = {
|
|
|
25
25
|
};
|
|
26
26
|
type PlayBundlingAdapter = {
|
|
27
27
|
projectRoot: string;
|
|
28
|
-
/**
|
|
28
|
+
/**
|
|
29
|
+
* Optional root that makes the artifact independent of where it was built:
|
|
30
|
+
* source paths in the graph hash and esbuild's working directory (which it
|
|
31
|
+
* writes into every module-header comment, and so into `artifactHash`) are
|
|
32
|
+
* both taken relative to it instead of to the build's absolute location.
|
|
33
|
+
*/
|
|
29
34
|
sourceIdentityRoot?: string;
|
|
30
35
|
nodeModulesDir: string;
|
|
31
36
|
cacheDir?: string;
|
|
@@ -48,7 +48,7 @@ var CURRENT_PLAY_ARTIFACT_CONTRACT_VERSION = 2;
|
|
|
48
48
|
// ../plays/authoring-contract.ts
|
|
49
49
|
import { Type } from "@sinclair/typebox";
|
|
50
50
|
import { Value } from "@sinclair/typebox/value";
|
|
51
|
-
var PLAY_AUTHORING_CONTRACT_EDITION =
|
|
51
|
+
var PLAY_AUTHORING_CONTRACT_EDITION = 7;
|
|
52
52
|
var PLAY_SQL_LISTENER_WHERE_OPERATORS = [
|
|
53
53
|
"eq",
|
|
54
54
|
"neq",
|
|
@@ -1117,6 +1117,82 @@ var PLAY_AUTHORING_FIELD_REGISTRY = {
|
|
|
1117
1117
|
description: "Unsupported legacy child-workflow timeout.",
|
|
1118
1118
|
errorMessage: "ctx.runPlay timeoutMs is unsupported because child Plays execute inline."
|
|
1119
1119
|
},
|
|
1120
|
+
"ctx.runPlayAsync.key": {
|
|
1121
|
+
schema: Type.String({ minLength: 1 }),
|
|
1122
|
+
fixtures: {
|
|
1123
|
+
valid: "request-approval",
|
|
1124
|
+
invalid: "",
|
|
1125
|
+
absent: void 0,
|
|
1126
|
+
unresolved: { expression: "callKey" },
|
|
1127
|
+
edition1: "request-approval"
|
|
1128
|
+
},
|
|
1129
|
+
referenceType: "string",
|
|
1130
|
+
required: true,
|
|
1131
|
+
resolution: "runtime-dynamic",
|
|
1132
|
+
issueCode: "play_authoring_run_play_option_invalid",
|
|
1133
|
+
description: "Stable identity for one independent child Play Run.",
|
|
1134
|
+
errorMessage: "ctx.runPlayAsync key must be a non-empty string."
|
|
1135
|
+
},
|
|
1136
|
+
"ctx.runPlayAsync.playRef": {
|
|
1137
|
+
schema: Type.Union([
|
|
1138
|
+
Type.String({ minLength: 1 }),
|
|
1139
|
+
Type.Union([
|
|
1140
|
+
Type.Object(
|
|
1141
|
+
{ playName: Type.String({ minLength: 1 }) },
|
|
1142
|
+
{ additionalProperties: true }
|
|
1143
|
+
),
|
|
1144
|
+
Type.Object(
|
|
1145
|
+
{ name: Type.String({ minLength: 1 }) },
|
|
1146
|
+
{ additionalProperties: true }
|
|
1147
|
+
)
|
|
1148
|
+
])
|
|
1149
|
+
]),
|
|
1150
|
+
fixtures: {
|
|
1151
|
+
valid: "request-approval",
|
|
1152
|
+
invalid: {},
|
|
1153
|
+
absent: void 0,
|
|
1154
|
+
unresolved: { expression: "playRef" },
|
|
1155
|
+
edition1: "request-approval"
|
|
1156
|
+
},
|
|
1157
|
+
referenceType: "string | PlayReferenceLike",
|
|
1158
|
+
required: true,
|
|
1159
|
+
resolution: "runtime-dynamic",
|
|
1160
|
+
issueCode: "play_authoring_run_play_option_invalid",
|
|
1161
|
+
description: "Independently published scalar child Play name or strongly typed definition handle.",
|
|
1162
|
+
errorMessage: "ctx.runPlayAsync playRef must be a non-empty Play name or definition handle."
|
|
1163
|
+
},
|
|
1164
|
+
"ctx.runPlayAsync.input": {
|
|
1165
|
+
schema: Type.Record(Type.String(), Type.Unknown()),
|
|
1166
|
+
fixtures: {
|
|
1167
|
+
valid: { draftId: "draft-1" },
|
|
1168
|
+
invalid: "draft-1",
|
|
1169
|
+
absent: void 0,
|
|
1170
|
+
unresolved: "childInput",
|
|
1171
|
+
edition1: {}
|
|
1172
|
+
},
|
|
1173
|
+
referenceType: "Record<string, unknown>",
|
|
1174
|
+
required: true,
|
|
1175
|
+
resolution: "runtime-dynamic",
|
|
1176
|
+
issueCode: "play_authoring_run_play_option_invalid",
|
|
1177
|
+
description: "Scalar input object submitted to the independent child Run.",
|
|
1178
|
+
errorMessage: "ctx.runPlayAsync input must be an object."
|
|
1179
|
+
},
|
|
1180
|
+
"ctx.runPlayAsync.options.description": {
|
|
1181
|
+
schema: Type.String({ minLength: 1 }),
|
|
1182
|
+
fixtures: {
|
|
1183
|
+
valid: "Request approval.",
|
|
1184
|
+
invalid: "",
|
|
1185
|
+
absent: void 0,
|
|
1186
|
+
unresolved: { expression: "description" },
|
|
1187
|
+
edition1: "Request approval."
|
|
1188
|
+
},
|
|
1189
|
+
referenceType: "string",
|
|
1190
|
+
required: true,
|
|
1191
|
+
resolution: "runtime-dynamic",
|
|
1192
|
+
issueCode: "play_authoring_run_play_option_invalid",
|
|
1193
|
+
description: "Non-empty purpose for one independent child Play Run.",
|
|
1194
|
+
errorMessage: "ctx.runPlayAsync options.description must be non-empty."
|
|
1195
|
+
},
|
|
1120
1196
|
"runtime.timeout": {
|
|
1121
1197
|
schema: Type.String({ pattern: "^\\d+\\s*[mh]$" }),
|
|
1122
1198
|
fixtures: {
|
|
@@ -1404,6 +1480,10 @@ var PLAY_AUTHORING_CLOUD_TYPE_DECLARATIONS = [
|
|
|
1404
1480
|
`export type CsvOptions = { description?: ${cloudReferenceType("ctx.csv.options.description")}; columns?: ${cloudReferenceType("ctx.csv.options.columns")}; rename?: ${cloudReferenceType("ctx.csv.options.rename")}; required?: ${cloudReferenceType("ctx.csv.options.required")} };`,
|
|
1405
1481
|
"export type PlayCallExecution = 'inline';",
|
|
1406
1482
|
`export type PlayCallOptions = { description: ${cloudReferenceType("ctx.runPlay.options.description")}; execution?: ${cloudReferenceType("ctx.runPlay.options.execution")}; timeoutMs?: ${cloudReferenceType("ctx.runPlay.options.timeoutMs")} };`,
|
|
1483
|
+
`export type PlayAsyncCallOptions = { description: ${cloudReferenceType("ctx.runPlayAsync.options.description")} };`,
|
|
1484
|
+
"declare const PLAY_RUN_ID_BRAND: unique symbol;",
|
|
1485
|
+
"export type PlayRunId = string & { readonly [PLAY_RUN_ID_BRAND]: 'PlayRunId' };",
|
|
1486
|
+
"export type AsyncPlayRunRef = Readonly<{ runId: PlayRunId }>;",
|
|
1407
1487
|
`export type RuntimeStepOptions = { semanticKey?: ${cloudReferenceType("ctx.step.semanticKey")}; staleAfterSeconds?: ${cloudReferenceType("ctx.step.staleAfterSeconds")} };`,
|
|
1408
1488
|
`export type FetchOptions = { staleAfterSeconds?: ${cloudReferenceType("ctx.fetch.staleAfterSeconds")}; transient?: boolean };`,
|
|
1409
1489
|
"export type PlayFetchResponse = { ok: boolean; status: number; statusText: string; url: string; headers: Record<string, string>; bodyText: string; json: unknown | null };",
|
|
@@ -1429,11 +1509,11 @@ var PLAY_AUTHORING_CLOUD_TYPE_DECLARATIONS = [
|
|
|
1429
1509
|
" withColumn<Name extends string, Value>(name: Name, definition: DatasetColumnDefinition<OutputRow, Value> & { readonly runIf: (row: OutputRow, index: number) => boolean | Promise<boolean> }): DatasetBuilder<InputRow, OutputRow & Record<Name, Value | null>>;",
|
|
1430
1510
|
" withColumn<Name extends string, Value>(name: Name, definition: DatasetColumnDefinition<OutputRow, Value>): DatasetBuilder<InputRow, OutputRow & Record<Name, Value>>;",
|
|
1431
1511
|
" withColumn<Name extends string, Value>(name: Name, resolver: StepResolver<OutputRow, Value> | RunnableColumnStepProgram<Value>, options: StepOptions<OutputRow, Value>): DatasetBuilder<InputRow, OutputRow & Record<Name, Value | null>>;",
|
|
1432
|
-
" withColumns<
|
|
1512
|
+
" withColumns<ProgramOutput extends OutputRow, Return>(program: StepProgram<OutputRow, ProgramOutput, Return>): DatasetBuilder<InputRow, ProgramOutput>;",
|
|
1433
1513
|
" step<Name extends string, Value>(name: Name, resolver: ColumnResolver<OutputRow, Value>): never;",
|
|
1434
1514
|
" run(options?: DatasetRunOptions<InputRow>): Promise<PlayDataset<OutputRow>>;",
|
|
1435
1515
|
"};",
|
|
1436
|
-
"export type PlayReferenceLike = { readonly playName: string; readonly name?: string } | { readonly name: string; readonly playName?: string };",
|
|
1516
|
+
"export type PlayReferenceLike<TInput extends Record<string, unknown> = Record<string, unknown>> = ({ readonly playName: string; readonly name?: string } | { readonly name: string; readonly playName?: string }) & { readonly __inputType?: TInput };",
|
|
1437
1517
|
"export interface DeeplinePlayRuntimeContext {",
|
|
1438
1518
|
" csv<T = Record<string, unknown>>(path: string | CsvInput<T & object>, options?: CsvOptions): Promise<PlayDataset<T>>;",
|
|
1439
1519
|
" dataset<TSource extends PlayDatasetInput<object>>(key: string, items: TSource): DatasetBuilder<PlayDatasetRow<TSource> & object, PlayDatasetRow<TSource> & object>;",
|
|
@@ -1447,6 +1527,8 @@ var PLAY_AUTHORING_CLOUD_TYPE_DECLARATIONS = [
|
|
|
1447
1527
|
" fetch(key: string, url: string | URL, init?: RequestInit & { headers?: HeadersInit & { 'Idempotency-Key'?: string; 'X-Idempotency-Key'?: string }; auth?: SecretAuthInput }, options?: FetchOptions): Promise<PlayFetchResponse>;",
|
|
1448
1528
|
" secrets: { get(name: string): SecretPromise; bearer(secret: string | SecretPromise | SecretHandle): SecretAuth; header(header: string, secret: string | SecretPromise | SecretHandle): SecretAuth };",
|
|
1449
1529
|
` runPlay<TOutput = unknown>(key: string, playRef: ${cloudReferenceType("ctx.runPlay.playRef")}, input: ${cloudReferenceType("ctx.runPlay.input")}, options: PlayCallOptions): Promise<TOutput>;`,
|
|
1530
|
+
" runPlayAsync<TInput extends Record<string, unknown>>(key: string, playRef: PlayReferenceLike<TInput>, input: NoInfer<TInput>, options: PlayAsyncCallOptions): Promise<AsyncPlayRunRef>;",
|
|
1531
|
+
" runPlayAsync(key: string, playRef: string, input: Record<string, unknown>, options: PlayAsyncCallOptions): Promise<AsyncPlayRunRef>;",
|
|
1450
1532
|
" log(message: string, options?: { level?: 'debug' | 'info' | 'warn' | 'error' }): void;",
|
|
1451
1533
|
` sleep(ms: ${cloudReferenceType("ctx.sleep.ms")}): Promise<void>;`,
|
|
1452
1534
|
"}",
|
|
@@ -1477,21 +1559,10 @@ function normalizeToolResponseReceiptRevision(value) {
|
|
|
1477
1559
|
}
|
|
1478
1560
|
|
|
1479
1561
|
// ../plays/contracts.ts
|
|
1480
|
-
var PLAY_PUBLIC_API_VERSION = 1;
|
|
1481
1562
|
var PLAY_ARTIFACT_VERSION = CURRENT_PLAY_ARTIFACT_CONTRACT_VERSION;
|
|
1482
|
-
var PLAY_MIN_RUNNER_VERSION = 1;
|
|
1483
|
-
var PLAY_RUNTIME_FEATURES = [
|
|
1484
|
-
"artifact_storage",
|
|
1485
|
-
"checkpoint_resume",
|
|
1486
|
-
"durable_sleep",
|
|
1487
|
-
"packaged_files"
|
|
1488
|
-
];
|
|
1489
1563
|
function buildPlayContractCompatibility(input) {
|
|
1490
1564
|
return {
|
|
1491
|
-
apiVersion: PLAY_PUBLIC_API_VERSION,
|
|
1492
1565
|
artifactVersion: PLAY_ARTIFACT_VERSION,
|
|
1493
|
-
minRunnerVersion: PLAY_MIN_RUNNER_VERSION,
|
|
1494
|
-
runtimeFeatures: [...PLAY_RUNTIME_FEATURES],
|
|
1495
1566
|
runtimeBackend: input?.runtimeBackend ?? null,
|
|
1496
1567
|
toolErrorSchemaVersion: input?.toolErrorSchemaVersion ?? TOOL_EXECUTION_ERROR_SCHEMA_VERSION,
|
|
1497
1568
|
authoringContractEdition: input?.authoringContractEdition ?? PLAY_AUTHORING_CONTRACT_EDITION,
|
|
@@ -2807,7 +2878,7 @@ function validatePlaySourceFilesHaveNoInlineSecrets(sourceFiles) {
|
|
|
2807
2878
|
var MAX_PLAY_BUNDLE_BYTES = 30 * 1024 * 1024;
|
|
2808
2879
|
|
|
2809
2880
|
// ../plays/bundling/index.ts
|
|
2810
|
-
var PLAY_BUNDLE_CACHE_VERSION =
|
|
2881
|
+
var PLAY_BUNDLE_CACHE_VERSION = 37;
|
|
2811
2882
|
var PLAY_ARTIFACT_CACHE_DIR = join(
|
|
2812
2883
|
tmpdir(),
|
|
2813
2884
|
`deepline-play-artifacts-v${PLAY_BUNDLE_CACHE_VERSION}`
|
|
@@ -4120,7 +4191,7 @@ function getBundleSizeError(filePath, bundledCode, artifactKind) {
|
|
|
4120
4191
|
artifactKind
|
|
4121
4192
|
);
|
|
4122
4193
|
}
|
|
4123
|
-
async function runEsbuildForCjsNode(entryFile, customerSourceFilePaths, importedPlayDependencies, adapter, exportName) {
|
|
4194
|
+
async function runEsbuildForCjsNode(entryFile, customerSourceFilePaths, importedPlayDependencies, adapter, exportName, bundleRoot) {
|
|
4124
4195
|
const sdkAliasPlugin = localSdkAliasPlugin(adapter);
|
|
4125
4196
|
const playProxyPlugin = importedPlayProxyPlugin(importedPlayDependencies);
|
|
4126
4197
|
const docflowPlugin = docflowRuntimeInstrumentationPlugin([
|
|
@@ -4138,7 +4209,14 @@ async function runEsbuildForCjsNode(entryFile, customerSourceFilePaths, imported
|
|
|
4138
4209
|
loader: "ts"
|
|
4139
4210
|
}
|
|
4140
4211
|
} : { entryPoints: [entryFile] },
|
|
4141
|
-
absWorkingDir
|
|
4212
|
+
// esbuild writes `// <path relative to absWorkingDir>` above every module
|
|
4213
|
+
// it inlines, and artifactHash is sha256 of those bytes. Rooting the build
|
|
4214
|
+
// at the identity root keeps the customer's own files repo-relative, so a
|
|
4215
|
+
// deploy worker building the same commit in a fresh temp directory each
|
|
4216
|
+
// time produces the same bytes. Files outside the root (the SDK on the
|
|
4217
|
+
// worker image) come out as a `..`-prefixed path whose shape depends only
|
|
4218
|
+
// on the image's layout, which is fixed, not on the build's name.
|
|
4219
|
+
absWorkingDir: bundleRoot,
|
|
4142
4220
|
bundle: true,
|
|
4143
4221
|
format: "cjs",
|
|
4144
4222
|
nodePaths: [adapter.nodeModulesDir],
|
|
@@ -4268,12 +4346,14 @@ authoring-contract-edition:${PLAY_AUTHORING_CONTRACT_EDITION}`
|
|
|
4268
4346
|
importedPlayDependencies: analysis.importedPlayDependencies
|
|
4269
4347
|
};
|
|
4270
4348
|
}
|
|
4349
|
+
const bundleRoot = resolve(sourceIdentityRoot ?? adapter.projectRoot);
|
|
4271
4350
|
const buildOutcome = await runEsbuildForCjsNode(
|
|
4272
4351
|
absolutePath,
|
|
4273
4352
|
analysis.importPolicy.localFiles,
|
|
4274
4353
|
analysis.importedPlayDependencies,
|
|
4275
4354
|
adapter,
|
|
4276
|
-
exportName
|
|
4355
|
+
exportName,
|
|
4356
|
+
bundleRoot
|
|
4277
4357
|
);
|
|
4278
4358
|
if (Array.isArray(buildOutcome)) {
|
|
4279
4359
|
return {
|
|
@@ -4285,7 +4365,7 @@ authoring-contract-edition:${PLAY_AUTHORING_CONTRACT_EDITION}`
|
|
|
4285
4365
|
const { bundledCode, sourceMapText, outputExtension } = buildOutcome;
|
|
4286
4366
|
const normalizedSourceMap = normalizeSourceMapForRuntime(
|
|
4287
4367
|
sourceMapText,
|
|
4288
|
-
|
|
4368
|
+
bundleRoot
|
|
4289
4369
|
);
|
|
4290
4370
|
const virtualBaseName = exportName === "default" ? basename(absolutePath).replace(/\.[^.]+$/, "") : `${basename(absolutePath).replace(/\.[^.]+$/, "")}.${exportName}`;
|
|
4291
4371
|
const virtualFilename = `/virtual/deepline-plays/${analysis.graphHash}/${virtualBaseName}.${outputExtension}`;
|
|
@@ -4787,7 +4867,7 @@ async function discoverPackagedLocalFiles(entryFile) {
|
|
|
4787
4867
|
}
|
|
4788
4868
|
|
|
4789
4869
|
// src/plays/bundle-play-file.ts
|
|
4790
|
-
var PLAY_BUNDLE_CACHE_VERSION2 =
|
|
4870
|
+
var PLAY_BUNDLE_CACHE_VERSION2 = 37;
|
|
4791
4871
|
var MODULE_DIR = dirname3(fileURLToPath(import.meta.url));
|
|
4792
4872
|
var SDK_PACKAGE_ROOT = resolve3(MODULE_DIR, "..", "..");
|
|
4793
4873
|
var SOURCE_REPO_ROOT = resolve3(SDK_PACKAGE_ROOT, "..", "..");
|