Build reusable schema descriptors

This commit is contained in:
2026-09-06 19:36:14 +00:00
parent 7c78da9cd2
commit 2b65876a7d
7 changed files with 789 additions and 17 deletions

View File

@@ -2,7 +2,7 @@
## Status and ownership
Status: implementation in progress; Stages 1–3 are complete and later stages are
Status: implementation in progress; Stages 1–4 are complete and later stages are
pending.
Audience: a `gpt-5.6-terra` coding agent implementing one stage per prompt, in
@@ -463,7 +463,27 @@ Acceptance:
## Stage 4 — Build the reusable schema binding graph
Status: pending.
Status: complete.
Completion evidence (2026-09-06):
- Implemented a per-operation private descriptor graph in [`schema.go`](../../schema.go)
for structural roots, ordinary/named scalars, duration and paired text scalars,
pointers, structs, string-keyed maps, slices, arrays, dynamic values, and recursive
definitions. No global cache or application method execution is involved.
- Implemented declared-field YAML binding, ignored/private fields, explicit struct/
pointer/map inlining, ambiguity and tag validation, one inline map, secret-tag
retention, and schema-aware key/index path traversal. Runtime default collisions,
cyclic values, cloning, projection, and decoding remain assigned to later stages.
- Added the [current schema contract](../config.md#application-schema-binding) and
updated the component inventory and target-roadmap ownership links.
- Focused tests cover nested and inline conflicts, ignored/private fields, maps of
structs, named scalars, pointer text method sets, missing codec pairs, root and
unsupported-kind rejection, recursive descriptors, side-effect freedom, dynamic
and inline-map paths, parsed numeric indices, and array bounds. Verified
`go test ./...`, `go vet ./...`, `go build ./...`, `go mod tidy -diff`, and
`git diff --check` with Go 1.26.7 on linux/amd64. No deviations were required;
typed value operations remain later work.
Read: feature [typed decoding](initial.md#typed-decoding) and
[type/projection contract](initial.md#supported-types-and-projection).