docs(docs): V1-2.6 UX U0, contract amendments, O22 checks, level-1 notes

This commit is contained in:
bchanot committed 2026-11-06 11:06:10 +01:00
1 parent a505b24bfd
commit d9e3e34aff
11 files changed
+604 -141

No files matched your search

+12 -11
View File
@@ -2,7 +2,8 @@
Status: PROPOSAL, 2026-11-05, audited at `f58cf23`, revised after the independent review and after the owner's
answers of 2026-11-05 (T2/T3 ratified with conditions, T4 without residual gap, T5 historical preservation, T10
navigation type). Companion of `V1-2-6_UX_PLAN.md`. Each cell states the outcome the code gives today (VERIFIED,
navigation type) and the brief « Autorisation U0 uniquement » (T4 SQL checks approved, T5 defaults, T10 option B;
BDR-101). Companion of `V1-2-6_UX_PLAN.md`. Each cell states the outcome the code gives today (VERIFIED,
file:line) or the outcome the plan requires and must prove by a test (REQUIRED, test in `V1-2-6_UX_TESTS.md`).
Nothing here is proven by assertion alone.
@@ -24,7 +25,7 @@ The change is compatible in one direction only, and these documents never call i
Two optional keys on `AnnotationCategory` (`crates/core/src/domain/sheet/schema.rs:219-228`):
```text
role?: "bone" | "joint" | "vertebra" (+ "navigation" if T10 option B is confirmed)
role?: "bone" | "joint" | "vertebra" | "navigation" (navigation: T10 option B, ratified)
fill_opacity?: integer percent, 10 to 100 (T3)
```
@@ -36,7 +37,7 @@ validated document the fingerprint hashes (the layer applies its constants at re
annotation `color` precedent, `schema.rs:215-216`, `429-430`), every fingerprint, review digest and R4 app-path
digest would change: that serialisation is forbidden and pinned by tests.
If T10 option B is confirmed, the automatic access adds, on demand, one internal category
Under T10 option B (ratified, BDR-101), the automatic access adds, on demand, one internal category
`cat-access` with role `navigation`: an ordinary `{id, name, color}` category for every reader before U6 once the
role is stripped (§4).
@@ -101,11 +102,11 @@ the fixed categories. Published versions are never re-judged by this rule (§5,
|---|---|---|---|---|
| `check_document_structure` | pass | pass | pass (category members never read) | VERIFIED `20261028110000_sheet_review_workflow.sql:411-441` |
| CHECKs `schema_known`, `schema_matches` | pass | pass | pass | VERIFIED `20261010100000:10-12`, `20261008110000:120-121` |
| `save_sheet_draft` | saves | saves a draft without roles; with the recommended non-regression check, refuses a save that removes or duplicates a role of the stored draft or renames its category | same | VERIFIED no category check today `20261028110000:593-623`; REQUIRED U6 pgTAP if the owner confirms (T4) |
| `save_sheet_draft` | saves | saves a draft without roles; with the approved declared check, refuses a save where a role is carried twice, a role-bearing category lacks its fixed names or a role of the stored draft is lost | same | VERIFIED no category check today `20261028110000:593-623`; REQUIRED U6 pgTAP (T4, contract §12.2) |
| Status walk, disclaimer, group keys | unchanged | unchanged | unchanged | VERIFIED `20261028110000:150-215`, `20261101100000:107-181` |
| `sheet_verdict_codes` | unchanged | unchanged | unchanged: report issues map to the existing `verification.validation.rules`; SQL checks only top-level failure codes | VERIFIED `20261101100000:57-69`, `360-368`; `verdict.rs:277-296` |
| Core gate at completion (T4) | n/a | a passed verdict from a core older than U6 refused | same | REQUIRED U6 migration and pgTAP; `verified_with` today `faunosteo-core 0.1.0` for every core (`verdict.rs:164-166`, `Cargo.toml:10`), so a U6 marker is added |
| Rounds in flight when the rules change | rounds of draft versions withdrawn by the U6 migration; the approved round of each published version stays approved (`20261028110000:102-104`, `704-705`) | same | same | REQUIRED U6 pgTAP; contract `V1-2_ANATOMICAL_SHEETS.md:945-949` |
| Rounds in flight when the rules change | rounds of draft versions withdrawn by the U6 migration; the approved round of each published version stays approved (`20261028110000:102-104`, `704-705`) | same | same | REQUIRED U6 pgTAP; contract §6.4 (worded at U0) |
| Worker at `f58cf23` (old image) | verdict as today, without the fixed-category rule (refused by the core gate) | same | definitive `verification.integrity.document` (draft) or `.base` (base) | VERIFIED `verify.rs:93-97`, `verdict.rs:169-185`, `264-274`; `20261101100000:355-378` |
| Worker of U6 | verdict with the fixed-category rule: fails until the draft carries the fixed categories | same | reads; passes when the fixed model holds | REQUIRED `verify-e2e` with an image checked against `HEAD` |
| Approval and publication | need a verdict on the current revision and an approved round on it; U6 adds the declared check `private.sheet_fixed_categories_ok(content)` at both | refused without the fixed categories | pass when the fixed model holds | VERIFIED `20261028110000:984-990`, `1028-1072`; REQUIRED U6 pgTAP (T4, O22 amended at U0) |
@@ -118,7 +119,7 @@ the fixed categories. Published versions are never re-judged by this rule (§5,
| Case | Outcome | Evidence |
|---|---|---|
| Draft saved before U6, opened after | read as New-absent; verification fails until the fixed categories are added (repair action, T4) | REQUIRED U6 |
| Draft stripped of its roles by a direct save or an older tab | refused at save if the owner confirms the non-regression check; otherwise saved, shown with the issue and the repair; in both cases no round opens and no publication | REQUIRED U6 (T4) |
| Draft stripped of its roles by a direct save or an older tab | refused at save by the approved declared check (T4, contract §12.2), the stored draft unchanged; a draft that never carried roles still saves and is shown with the issue and the repair; in both cases no round opens and no publication | REQUIRED U6 (T4) |
| Recovery copy (sessionStorage) taken before U6, restored after | document text read by the same strict reader | VERIFIED storage `recovery.ts:10-57`; REQUIRED U6 |
| Recovery copy taken after U6, restored by a rolled-back app | refused like any `invalid_document`; the copy is kept, not deleted | REQUIRED: test that a refused copy is not purged |
| Undo history across the U6 release | history is per page session, never persisted | VERIFIED `undo.ts`, `editorLoad.ts:136-152` |
@@ -131,9 +132,9 @@ Order for any environment, for U6 and the curves lot (and any later change of th
the fingerprint):
1. SQL: the U6 migration, which withdraws the rounds of draft versions in `verifying`, `open`, `approved` (contract
`V1-2_ANATOMICAL_SHEETS.md:945-949` says « every round »; the approved round linked to each published version
stays approved, T4) and adds the core gate, the rules epoch, the publication check and, if confirmed, the save
check (T4). No verdict code is added, so no
§6.4, worded at U0: rounds of draft versions; the approved round linked to each published version stays
approved, T4) and adds the core gate, the rules epoch, the publication check and the save check (T4, contract
§12.2). No verdict code is added, so no
change to `sheet_verdict_codes`.
2. Worker image, built from the same commit as the app (`.gitea/workflows/release-images.yml:103-120`).
3. Application.
@@ -143,7 +144,7 @@ and creates no new-model sheet until it reads that epoch, so an application depl
v2. SQL first is mandatory: only the orders that start with SQL fail closed (an old worker's passed verdicts
refused by the gate, the publication check refusing a draft outside the fixed model). Worker before SQL leaves
rounds already `approved` on old verdicts publishable until the U6 migration lands; that is why SQL goes first. U6 runs on the sandbox only until the owner decides
otherwise. Before U6 reaches any environment beyond the throwaway sandbox: the read-only count of path geometries (T16) and, for production,
otherwise. Before the new model is activated on an environment, and before U6 or U8 reaches any environment beyond the throwaway sandbox: the read-only count of path geometries (T16) and, for production,
the 0.1.0 reader check below.
Rollback:
@@ -170,7 +171,7 @@ Tests in `V1-2-6_UX_TESTS.md` U6.
|---|---|
| Fingerprints | equine `12d78872…` and alias `27c7383c…` recomputed equal; every seed review digest equal to its pre-U6 pin; `sheet_fingerprint.rs`, `r5_6_switch.rs`, `characterisation_serde_tolerance.rs` green unchanged; a New-present document hashed twice gives one value |
| Rust | both keys round-trip; absent keys not written; explicit `null`, unknown role and out-of-range opacity refused; positional-array and one-key-map shapes handled as decided at U6; `validate.rs` issue lists equal before and after on every fixture; rules and refusals of T4 |
| SQL | U6 migration: draft rounds withdrawn with the reason, published versions' rounds still approved, core gate refusing an older `verified_with`, rules epoch exposed, publication and approval refused outside the fixed model, save non-regression if confirmed; `up upgrade` from the current migration set; `types --check`; publication refused without a current passed U6 verdict |
| SQL | U6 migration: draft rounds withdrawn with the reason, published versions' rounds still approved, core gate refusing an older `verified_with`, rules epoch exposed, publication and approval refused outside the fixed model, save refused when it duplicates, renames away or loses a role; `up upgrade` from the current migration set; `types --check`; publication refused without a current passed U6 verdict |
| PDF | `lean_document` and the export gate strip both keys; PDF goldens and R4 digests unchanged; a New-present sheet's PDF exported and reopened (archive kept) |
| Worker | image rebuilt from `HEAD`; `verify-e2e` with a New-absent draft (fails on the fixed-category rule), the same draft once converted, which then carries roles (passes), and a sheet created by the U6 `sheet.empty` (passes) |
| N-1 reader | New-present fixture and harness: PDFs pass `n-1.reader.test.ts:178-196`; `contracts.types.test.ts` green; frozen copies unchanged in the diff |