Repository navigation
fix(sidecar): carry parkedAt through the v2 deployment record (CL-8184) - #771
Merged
Merged
Conversation
The lifecycle test fixture cast an empty object into AgentDeployFrame's config, so a deployed record was missing the v2-required tenantId/ principalId and every subsequent readWorkflowDeploymentRecord silently failed schema validation (returning undefined). That made workflow-teardown-flavor.test.ts's parkedAt assertions fail against an undefined record, not a missing marker -- give the fixture real tenantId/principalId so records round-trip.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
apps/sidecar/test/workflow-teardown-flavor.test.tshad 2 failing cases since PR #764 introduced deployment-record schema v2 (tenantId/principalIdrequired inworkflow-deployment-record.ts).Root cause:
apps/sidecar/test/support/workflow-lifecycle-fixture.ts'smakeWorkflowFramecast an empty object intoAgentDeployFrame["config"]. The deploy path persiststenantId/principalIdstraight fromframe.config, so the fixture wrote a record missing both fields.readWorkflowDeploymentRecordvalidates on read and returnsundefinedfor a record that fails the v2 schema -- so every post-deploy read in the suite silently came backundefined, andrecord?.parkedAtwasundefinednot because the hibernate path dropped the marker, but because the record itself never round-tripped.Fix: give the fixture real
tenantId/principalIdvalues so a deployed record is v2-valid and round-trips throughreadWorkflowDeploymentRecordas production deploys do. No production code changed --markWorkflowDeploymentRecordParkedalready threadsparkedAtcorrectly.Test plan
bun test apps/sidecar/test/workflow-teardown-flavor.test.ts-- 6 pass, 0 failbun --cwd apps/sidecar test-- 324 pass, 0 failbun run typecheck-- clean