1.9 KiB
1.9 KiB
id, name, status, depends_on, scope, risk, impact, level
| id | name | status | depends_on | scope | risk | impact | level | |
|---|---|---|---|---|---|---|---|---|
| schema/enums | Define TypeBox categorical enum schemas and type aliases | completed |
|
narrow | trivial | component | implementation |
Description
Define all categorical enum schemas using Type.Union([Type.Literal(...)]) pattern per schema.md. Each enum gets a schema constant (PascalCase + Enum suffix) and a Static<typeof> type alias (PascalCase, no suffix). Also include the Nullable helper.
The enums: CallStatusEnum, NodeStatusEnum, OperationTypeEnum, EdgeTypeEnum.
Acceptance Criteria
src/schema/enums.tsexports all four enum schemas and their type aliases- Each enum uses
Type.Union([Type.Literal("value"), ...])pattern per typebox conventions CallStatusEnum:"pending" | "running" | "completed" | "failed" | "aborted"with transitions documented in JSDocNodeStatusEnum:"idle" | "waiting" | "ready" | "running" | "completed" | "failed" | "skipped" | "aborted"OperationTypeEnum:"query" | "mutation" | "subscription"EdgeTypeEnum:"triggered" | "depends_on" | "typed" | "sequential" | "conditional"- Type aliases derived via
Static<typeof>:CallStatus,NodeStatus,OperationType,EdgeType - Naming convention matches spec:
Enumsuffix on schema constants only, never on type aliases Nullablehelper exported:const Nullable = <T extends TSchema>(schema: T) => Type.Union([schema, Type.Null()])src/schema/index.tsre-exports all schemas and types- Unit tests for each enum:
Value.Check()validation, compile-time type alias verification
References
- docs/architecture/schema.md — enum definitions, naming convention, nullable helper
- docs/architecture/reactive-execution.md — NodeStatus semantics and transitions
Notes
To be filled by implementation agent
Summary
To be filled on completion