Repository navigation
fix(ui): workflow builder live defects — canvas height and save 400s - #155
Merged
Merged
Conversation
This was referenced Nov 6, 2026
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.
Fix: Workflow Builder live defects — blank canvas and Save/Test 400s
Live interactive walkthrough (Playwright redo, 2026-11-07,
REPORT.mdStep 4)found the merged #150 Builder unusable as shipped: the canvas paints blank
(
.vue-flowcomputes to 0px) and Save PUT / Test/validateboth return400. This PR fixes the four pinned root causes. No behavior is invented:
every serializer change restores the stored entity shape the server accepts
(stored-shape PUT → 200 in the walkthrough bisection).
1. Canvas height —
WorkflowCanvas.vueThe wrapper's height can sit on its
min-height: 420pxfloor (not a definiteheight), so the library's
.vue-flow { height: 100% }resolves to 0px andoverflow: hiddenclips every node. Fix mirrors the verified LineageGraphpattern in the same repo (live:
.vue-flow635px, renders fine):.workflow-canvasbecomes a flex-column container and.vue-flowa flexitem (
flex: 1 1 auto; min-height: 0), so its size comes from flex layout,not percentage resolution.
2. Defect A — stored user-task subtype discarded
mapNodeTypeAndSubtypehardcodedsubType = 'userApprovalTask', droppingthe stored
createRecognizerFeedbackApprovalTask. Schema mechanism(
openmetadata-spec/.../nodes/userTask/*.json, pina3012259ca): thespecific schema's input allows 4 items and its inputNamespaceMap requires
all 4 keys; the generic schema caps input at 1 item and its namespace at
relatedEntity— so coercing the subtype makes the stored input/namespaceillegal and the PUT 400s. The specific subtype is now preserved (unknown
values still fall back to the generic name).
Required companion (otherwise A itself regresses):
configureUserTaskIOnow applies the approval config for both approval subtypes via the new
shared predicate
isUserApprovalTaskSubType— without it a specific-subtypenode would save with an empty config (
assigneesis required → 400).3. Defect B —
emptyAssigneeStrategyinjectedapplyUserApprovalConfigdefaultedemptyAssigneeStrategy: ... ?? 'none'. The specific-subtype schema'sassignees is
additionalProperties: falsewithout that property → 400.The
...assigneesFromNodespread already carries it when the stored confighas it (all live generic-subtype definitions do); when absent the generic
schema defaults it server-side.
candidates: []is kept (allowed by thespecific schema).
4. Defect C + node descriptions — trigger output and
descriptionoutputwas hardcoded to['relatedEntity', 'updatedBy'],dropping
triggeringObjectId+recognizerFeedback(stored: 4 items).The save now round-trips the stored
trigger.output— only when thetrigger type is unchanged (a type change rebuilds the trigger, so the
stored outputs no longer describe it); otherwise it falls back to the
default pair.
schemas declare
description, sogetNodeConfiguration(task nodes)and
buildWorkflowNodes(start/end nodes) now carry it through whenpresent, and omit it when blank (seed nodes carry none).
Out of scope (recorded, not fixed here)
getTrigger()null server NPE):separate residual, needs official create-flow analysis first.
the walkthrough control PUTs return 200, so not a 400 cause; observed
round-trip lossiness, left for a later decision.
=== 'userApprovalTask'checks (resolveUpdatedByNamespace,migrateWorkflowInputNamespaceMap, condition modal, form dispatch):the load path always saw the stored specific subtype, so fix A does not
change their behavior; left untouched (see
FIX.md).Alignment degree (vs official pin
a3012259ca)verified LineageGraph pattern. No official counterpart to compare.
the server validates against the pin's per-subtype schemas
(
createRecognizerFeedbackApprovalTask.json,userApprovalTask.json,endEvent.json). No official behavior isinvented; no official UI code is copied beyond what WorkflowBuilder port (Vue 3): official OSS builder 1:1 (S1+S2+S3) #150 already ported.
Tests
workflowValidation.test.ts(specific subtypepreserved + approval config, trigger output round-tripped, default output
on trigger-type change, node descriptions carried) and
workflowNodeUtils.test.ts(specific-subtype approval config without theinjected property, stored property carried for the generic subtype,
description carried/omitted, predicate itself).
workflowSerializer.test.ts(live 21 definitions round-trip): 2 cases(AutoPilotWorkflow, RecognizerFeedbackReviewWorkflow) failed before this
fix because their assertions pinned the buggy behavior (hardcoded 2-item
output, subtype collapsed to generic,
'none'default). Retargeted atthe same strength to the stored values; the other 19 cases pass
unchanged. See
FIX.mdfor the per-assertion retarget list.WorkflowCanvas.test.tscases pass with no regression. Live re-verificationwithout the forced-height workaround follows merge + frontend deploy.
Gates (branch head
dabec147e480)npm run build: pass, 9.18svue-tsc --noEmit -p tsconfig.app.json: 233 errors,byte-identical to the main
023a0e1fbaseline (0 new, 0 removed),0 errors in touched files. Full Vitest suite not run (related files only,
per task scope).