Repository navigation
Commit 1c1144f
fix(spec): try_catch nodeId and errorVariable describes say what the engine binds (#24694)
Closes #24659
## What
Two `.describe()` sentences in
`packages/spec/src/automation/control-flow.zod.ts` now say what the
engine actually binds. No schema shape, default or runtime path changes.
- `TryCatchErrorValue.nodeId`: was "Node the failure is attributed to".
The engine
(`packages/services/service-automation/src/builtin/try-catch-node.ts`,
the `errorValue` literal) binds `nodeId: node.id`, the Try / Catch
node's own id; the failing inner step only appears inside `message`. New
text: "Id of this Try / Catch node, not of the step that failed inside
its try region; that step is normally named inside `message`".
- `TryCatchConfig.errorVariable`: drops "The value is a
`TryCatchErrorValue`: ..." and says in words what the value carries,
aligned with the node descriptor text that PR #24655 landed ("the id of
this Try / Catch node (`nodeId`), the failure message, which normally
names the step that failed (`message`) ..."). The ADR-0112 `$error.code`
branching hint is kept.
Regenerated with repo tooling (`gen:schema`, `gen:docs`):
`content/docs/references/automation/control-flow.mdx` (the two table
rows). The shipped `json-schema/automation/TryCatchConfig.json` and
`TryCatchErrorValue.json` are gitignored build output and carry the new
text after the build (grep count 1 each, measured on the built tree). No
test pinned either sentence (`git grep` of both old sentences outside
the generated page: zero hits besides the source).
Changeset: `.changeset/24659-try-catch-describes.md`,
`@objectstack/spec` patch.
## Verification (head 9112cb7)
- `pnpm --filter @objectstack/spec build && gen:schema && gen:docs`:
exit 0 ("Generated 227 files").
- `pnpm --filter @objectstack/spec check:generated`: "All 14 generated
artifacts are up to date", exit 0.
- `pnpm --filter @objectstack/spec typecheck`: exit 0.
- `pnpm --filter @objectstack/spec exec vitest run --maxWorkers=2
src/automation`: 37 files, 1576 tests passed.
- `node scripts/pm/dispatch-gates.mjs --commands`: 104 derived commands
run; 103 exit 0 (five of them after building `@objectstack/formula`,
`@objectstack/lint`, `@objectstack/client`, `@objectstack/client-react`,
which they read). NOT MEASURED: `pnpm check:dual-build-cjs-loads`,
reason: PREREQUISITE NOT MET (it reads every package dist/, and a full
workspace build was not run locally); declared to CI. `--ran`
reconciliation: 104 derived, 104 run, 0 UNRUN.
## Acceptance notes
- Open PRs touching `control-flow.zod.ts` were checked before opening
(all 15 open PRs' file lists): none.
- The issue's own premise was re-read on `origin/main` 3a931fc and
holds.
---
_Generated by [Claude
Code](https://claude.ai/code/session_01D6F9axfoPzR7t8G1J7Ytzz)_
---------
Co-authored-by: Claude <noreply@anthropic.com>1 parent 8e14ce0 commit 1c1144f
3 files changed
Lines changed: 9 additions & 4 deletions
File tree
- .changeset
- content/docs/references/automation
- packages/spec/src/automation
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
244 | 244 | | |
245 | 245 | | |
246 | 246 | | |
247 | | - | |
| 247 | + | |
248 | 248 | | |
249 | 249 | | |
250 | 250 | | |
| |||
281 | 281 | | |
282 | 282 | | |
283 | 283 | | |
284 | | - | |
| 284 | + | |
285 | 285 | | |
286 | 286 | | |
287 | 287 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
339 | 339 | | |
340 | 340 | | |
341 | 341 | | |
342 | | - | |
| 342 | + | |
343 | 343 | | |
344 | 344 | | |
345 | 345 | | |
| |||
383 | 383 | | |
384 | 384 | | |
385 | 385 | | |
386 | | - | |
| 386 | + | |
387 | 387 | | |
388 | 388 | | |
389 | 389 | | |
| |||
0 commit comments