Commit the human-read public tier as YAML (was JSON) #11

Closed
opened 2026-06-07 03:53:26 +00:00 by coilysiren · 0 comments
Owner

The committed, human-read tier is the public tier - but it was serialized as JSON, which is noisier to eyeball in a diff than YAML. Switch the committed public tier to YAML; keep the gitignored normalized tier (machine diff substrate) as JSON.

Change

  • dbglib.dump_doc / load_doc / tier_file / tier_ext centralize tier serialization. public -> YAML via yq -p=json -o=yaml, so no PyYAML dependency (matches the existing parser-spec read path that already shells to yq). normalized -> JSON as before.
  • step.py and bless.py write/read through those helpers instead of hardcoding current.json.
  • Migrated every committed outputs/**/public/*.json -> *.yml.
  • Docs (README tier table, o2r-coupling) updated to public/*.yml.

Diff round-trip fix

YAML renders 0.0 as 0, so reloading the public baseline gives int 0 while a fresh probe yields float 0.0. The structural diff's type(a) is not type(b) guard would flag that as a spurious 0 -> 0.0 every run. Fixed by making diff_json compare numbers by value, not type (bools excluded). Verified: yaml-reloaded baseline vs fresh-float = no diff; a real 0.0 -> 100.0 still reports.

Public tier stays leak-scrubbed for the opaque tailnet suffix (#3 unchanged).

The committed, human-read tier is the **public** tier - but it was serialized as JSON, which is noisier to eyeball in a diff than YAML. Switch the committed public tier to YAML; keep the gitignored normalized tier (machine diff substrate) as JSON. ## Change * `dbglib.dump_doc` / `load_doc` / `tier_file` / `tier_ext` centralize tier serialization. public -> YAML via `yq -p=json -o=yaml`, so **no PyYAML dependency** (matches the existing parser-spec read path that already shells to yq). normalized -> JSON as before. * `step.py` and `bless.py` write/read through those helpers instead of hardcoding `current.json`. * Migrated every committed `outputs/**/public/*.json` -> `*.yml`. * Docs (README tier table, o2r-coupling) updated to `public/*.yml`. ## Diff round-trip fix YAML renders `0.0` as `0`, so reloading the public baseline gives int `0` while a fresh probe yields float `0.0`. The structural diff's `type(a) is not type(b)` guard would flag that as a spurious `0 -> 0.0` every run. Fixed by making `diff_json` compare numbers by value, not type (bools excluded). Verified: yaml-reloaded baseline vs fresh-float = no diff; a real `0.0 -> 100.0` still reports. Public tier stays leak-scrubbed for the opaque tailnet suffix (#3 unchanged).
Commenting is not possible because the repository is archived.
No description provided.