You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(spec,cli): conversion deprecation notices reach the author, not just os validate (#3855) (#3872)
The ADR-0087 D2 conversion layer rewrites an old-shape key to canonical at load
and emits a structured `ConversionNotice` per rewrite. Being silent about FIXING
the shape is the point — zero consumer action. Being silent about having HAD to
is not: the notice is the one signal that says "this spelling retires in
protocol N, and your metadata stops loading then".
Two of the three surfaces that run the pass discarded every notice:
os validate — passed a sink, printed them.
os build — passed NO sink. Every notice dropped.
defineStack — passed NO sink. Every notice dropped.
That is the #3782 parity class one layer down: not "does this command run the
gate" but "does it listen to what the gate says". Five conversions are live
today (protocol 11 and 15), so an author on one of those shapes was told by one
command and not the other two — and `defineStack` is where that author actually
is, since it runs inside their own config module.
`os build` now prints the notices and includes a `conversions` array in `--json`
under the same key `os validate --json` already uses. `defineStack` warns once
per distinct conversion site, in BOTH strict and non-strict mode: the conversion
happens on the shared `normalizeStackInput` call before the strict branch, and
`strict: false` does not make the old shape any less retiring.
A new assertion in `validate-build-gate-parity.test.ts` fails if either command
calls `normalizeStackInput` without a sink — verified non-vacuous by stripping
the sink and watching it go red. The `defineStack` tests document a sharp edge:
the notice path is index-based (`flows[i].nodes[j].type`) and the warn-once set
is process-scoped, so fixtures must occupy distinct node indices or they
silently reuse an earlier case's dedupe key and assert nothing.
No behaviour change for a stack already on canonical shapes — nothing converts,
so nothing warns.
fix(spec,cli): conversion deprecation notices reach the author, not just `os validate` (#3855)
7
+
8
+
The ADR-0087 D2 conversion layer rewrites an old-shape key to its canonical
9
+
spelling at load and emits a structured `ConversionNotice` for each rewrite. The
10
+
conversion being silent about *fixing* the shape is the point — zero consumer
11
+
action. Being silent about having **had** to is not: the notice is the one signal
12
+
that says *this spelling retires in protocol N, and your metadata stops loading
13
+
then*.
14
+
15
+
Two of the three surfaces that run the conversion pass discarded every notice:
16
+
17
+
| Surface | Before | After |
18
+
|---|---|---|
19
+
|`os validate`| passed a sink, printed them | unchanged |
20
+
|`os build` / `os compile`|**passed no sink — notices discarded**| prints them, and includes a `conversions` array in `--json` under the same key `os validate --json` uses |
21
+
|`defineStack`|**passed no sink — notices discarded**| warns on the console, once per distinct conversion site |
22
+
23
+
This is the #3782 parity class one layer down: not "does this command run the
24
+
gate" but "does it listen to what the gate says". Five conversions are live
25
+
today (protocol 11 and 15), so an author on any of those shapes was told by one
26
+
command and not the other two — and `defineStack` is where that author actually
27
+
is, since it runs inside their own config module.
28
+
29
+
`defineStack` surfaces notices in **both** strict and non-strict mode: the
30
+
conversion happens on the shared `normalizeStackInput` call before the strict
31
+
branch, and `strict: false` does not make the old shape any less retiring.
32
+
33
+
A new assertion in `validate-build-gate-parity.test.ts` fails if either command
34
+
calls `normalizeStackInput` without a sink, so the gap cannot silently reopen.
35
+
36
+
No behaviour change for a stack already on canonical shapes: nothing converts,
0 commit comments