({
message,
value,
cause,
}: { message?: string; value?: T; cause?: unknown } = {})
| 3 | * |
| 4 | * These are the engine's own cap-breach codes; the union is intentionally |
| 5 | * **extendable** (new caps add a member). An `AbortSignal`-driven cancellation |
| 6 | * instead carries the signal's `reason` through `cause`, which may be any |
| 7 | * value, so consumers should treat an unrecognized `cause` as opaque. |
| 8 | * |
| 9 | * - `'timeout'`: an enclosing `ce.withTimeLimit(...)` span's deadline was |
| 10 | * exceeded. |
| 11 | * - `'step-budget'`: an enclosing `ce.withStepBudget(...)` span (or an |
| 12 | * internal step budget) was spent — a deterministic budget, not the clock. |
| 13 | * - `'iteration-limit-exceeded'`: a loop/iterator exceeded |
| 14 | * `engine.iterationLimit`. |
| 15 | * - `'recursion-depth-exceeded'`: user-function recursion exceeded |
| 16 | * `engine.recursionLimit`. |
| 17 | */ |
nothing calls this directly
no outgoing calls
no test coverage detected