Skip to content

Commit bc0b18e

Browse files
committed
Add note about the dequeued run schema
1 parent de247ab commit bc0b18e

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

internal-packages/run-engine/src/engine/systems/dequeueSystem.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -559,11 +559,13 @@ export class DequeueSystem {
559559
friendlyId: result.worker.friendlyId,
560560
version: result.worker.version,
561561
},
562+
// TODO: use a discriminated union schema to differentiate between dequeued runs in dev and in deployed environments.
563+
// Would help make the typechecking stricter
562564
deployment: {
563-
id: result.deployment?.id ?? "",
564-
friendlyId: result.deployment?.friendlyId ?? "",
565-
version: result.deployment?.version ?? "",
566-
imagePlatform: result.deployment?.imagePlatform,
565+
id: result.deployment?.id ?? "NO_DEPLOYMENT_DEV_ENV",
566+
friendlyId: result.deployment?.friendlyId ?? "NO_DEPLOYMENT_DEV_ENV",
567+
version: result.deployment?.version ?? "NO_DEPLOYMENT_DEV_ENV",
568+
imagePlatform: result.deployment?.imagePlatform ?? "NO_DEPLOYMENT_DEV_ENV",
567569
},
568570
run: {
569571
id: lockedTaskRun.id,

0 commit comments

Comments
 (0)