Skip to content

Commit 5be56b8

Browse files
committed
chore: changeset for the flow-inspector sibling-block fix (objectstack#4045)
1 parent cfbcb54 commit 5be56b8

1 file changed

Lines changed: 42 additions & 0 deletions

File tree

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
---
2+
"@object-ui/app-shell": patch
3+
---
4+
5+
fix(flow-designer): a published `configSchema` can no longer delete a node's sibling-block editors — objectstack#4045
6+
7+
`FlowNodeInspector` resolved its form as `serverFields ?? fieldsForNodeType(type)`,
8+
so an engine-published `configSchema` **replaced the hand-written field group
9+
wholesale**. But a `configSchema` describes `node.config` and nothing else
10+
(ADR-0018), and `jsonSchemaToFlowFields` roots every field it emits at
11+
`['config', key]` — so the replacement silently deleted every editor rooted
12+
anywhere else.
13+
14+
18 fields sit in that blast radius: `connectorConfig.*` (3), `waitEventConfig.*`
15+
(5), `boundaryConfig.*` (6) and the top-level `timeoutMs` (4). For `wait` and
16+
`boundary_event` those blocks are the node's **entire** contract.
17+
18+
This already happened once. `connector_action`'s descriptor published a schema
19+
declaring `connectorId` / `actionId` / `input` as CONFIG keys, so against a live
20+
backend the generated form replaced the `connectorConfig` group — connector and
21+
action pickers included — and an author configuring a connector node in Studio
22+
wrote the trio to `node.config`, which the executor never reads. The node then
23+
refused to dispatch with `connectorConfig.connectorId and .actionId are
24+
required`. objectstack#4210 retired that schema on the server; this change is
25+
what stops the next mis-rooted one from doing the same to `wait` or
26+
`boundary_event`.
27+
28+
New `mergeServerFlowFields()` splits the resolution by root:
29+
30+
- **the server owns the config-rooted fields** — it is the authority on what the
31+
executor actually reads, so its set replaces the hand-written config fields
32+
rather than merging with them (a stale client key must not linger);
33+
- **non-config fields are always preserved** from the hand-written group, in
34+
declared order;
35+
- a server field duplicating a preserved sibling key is **dropped**, not rendered
36+
twice — two editors for one value, one of them writing where nothing reads, is
37+
the same bug wearing a different hat.
38+
39+
With no published schema the hand-written group is still used whole, unchanged.
40+
41+
Verified by mutation: reverting to the old replacement turns all three new
42+
assertions red, one of which replays the `connector_action` incident directly.

0 commit comments

Comments
 (0)