# Period-Lock Control — final local validation

25 October 2026 · D30-F04-A05 · private local package. Root owns visitor synchronization and any actual aggregate five-kernel integration receipt.

## Definition and independent oracle

Root froze the exact API, entity-wide CLOSING policy, governed reopen/cancel, distinct generation/close version, five required runner checks and 300-second age boundary before algorithm code. **73 independently prescribed complete transition/state goldens,20 accepted**, were materialized without importing the implementation. They include two complete close versions, latest fail/indeterminate, wrong scope/generation/head/K, missing/future/stale evidence, exact 300.000 versus 300.001 seconds, self/wrong-bound approval, role denial, corrupt state and 256-record-cap exact replay.

The canonical model uses a separate September 2026 ledger CB-CLOSE-2026/CB-A, head 3 then 4, not a rewrite of Stage 0's September-closed baseline. Current trusted Trial-Balance consumer requires visible prefix p = validated head h = frozen head and matching complete reported/chart/genesis/source evidence. Structural validity, planned schedules and ready FX proposals are insufficient for runner pass.

## Portable execution

- `python -B tests/test_algorithm.py`: two suites pass, whole independent outputs and detached state/result isolation; inputs unchanged.
- `python tests/run_parity.py`: strict TypeScript compilation; all 73 whole state/result outputs equal Python,20 accepted. Exact strings, receipt/history order, close versions and rejection state are compared.
- Lab uses exact compiled canonical TypeScript, SHA-256 `4ba3a6b9e95b8f9147a64847e422bd28bf96fd203f4e61e28f8c674ba4032765`.

## Actual PostgreSQL18.1 execution

`python tests/run_postgresql.py`: **19 groups pass**. Actual installed PG18.1 binaries launch only a fresh task-owned loopback 55432 cluster; no existing services used or changed. Generated SCRAM credentials are never retained in evidence. fsync/full_page_writes/synchronous_commit verified on; actual data path checked against the task-owned directory. Final cleanup confirms stopped, removed and owned path absent.

1. Profile/settings/isolation.
2. Unchanged old post and other-month journal paths blocked in CLOSING with counter rollback.
3. Original accepted posting replay while CLOSING.
4. CLOSED September denial and permitted OPEN October journal.
5. Separately authenticated checker approval, reopen generation 2, old receipt rejection, new checks/close version 2; full exported SQL history passes portable reconstruction.
6. Role/table/helper/trigger/session-role permission denials, normal-writer forged-runner denial and owner UPDATE rejected by immutable history trigger.
7. Latest fail/indeterminate blocks finalization; governed cancellation increments generation, permits remediation and rejects old-generation evidence.
8. Unchanged correction endpoint blocked atomically; original accepted correction pair still replays.
9. Reservation capture rolls back staged hold/counter/journal effects; accepted capture replays; hold-only reserve remains allowed without head change.
10. Post-first actual COMMIT: observed independent lock wait, closer then includes writer sequence 2.
11. Close-first actual COMMIT: staged CLOSING not externally visible before commit; waiting old writer rejects afterward.
12. Close ROLLBACK releases barrier and accepted identity; waiting writer posts sequence 2.
13. Writer ROLLBACK leaves no journal/counter gap; closer freezes 1.
14. Two independent closers serialize; one accepted version, other VERSION_CONFLICT.
15. Older Repeatable Read writer observes SQLSTATE 40001 after period_epoch changes locked ledger tuple; no stale bypass.
16. Controlled restart retains complete identical history, authority and closed-period guard.
17. Unauthorized late-effective/open-booking adjustment rejects; authorized September-effective/October-booked adjustment preserves both fields without reopening September.
18. Controlled legacy open flag alone cannot register an unmanaged future month; journal/counter roll back.
19. Owner-controlled future period watermark rejects clock regression, then is restored; system clock unchanged.

Raw evidence: `postgresql-results.json`. Canonical SQL export: `actual-period-history.json`. The first two SQL files are byte-pinned from accepted Stage 1/Stage 2. Period extension SHA-256 `6b5e7063115cb6b5a539d8950598b60aeb2f1f0dfdebcf988cc999afe1936159`.

Important scope: these SQL tests supply **synthetic trusted runner attestations** to test policy/authority/transaction boundaries. They do not claim the five actual accounting kernels executed. Root's separate aggregate runner must retain real executions and all contributing bases, including accepted scheduler/revaluation links and every member's intercompany snapshots. External truth/currentness is a trusted runner obligation. Controlled restart is not power-loss proof; function return and recorded time are not physical COMMIT timestamps.300-second equality is portable deterministic evidence, not a five-minute sleep test.

## Actual visual and browser QA

`node tests/build_lab.cjs`, then `node tests/browser_qa.cjs`: six scenarios,18 canonical attempts,390/768/1440px. Final canonical projection generation 2/close version 2/frozen head 4/accepted record 15. Missing checks, replay/conflict, empty checks after reopen, latest fail/indeterminate, exact freshness boundary/stale case and cancellation invalidation verified. All action cards retained. No document horizontal overflow; controls≥44px; audit has labeled local horizontal scroll. Step/Back/Play/Pause/Reset, running speed change, keyboard arrows, scenario timer cancellation and reduced-motion one-step Play pass. No console warnings/errors.

Both standalone SVGs parse as XML and decode/render in Chrome. Workflow and article Mermaid parse/render. Actual phone lifecycle, both static diagrams and full workflow pixels inspected; values/labels align with oracle. Screenshots in visuals/qa. Reader/iframe validation remains a separate root integration receipt.

## Derivative and release checks

Descriptive article YAML title, inline static SVGs/full-size fallback, inline Mermaid, compiled offline lab, exact related tutorial titles and public examples downloads. Scene script includes actual evidence distinctions, deterministic code-motion production instructions and exact canonical Candle Anatomy final outro; no encoded video/audio claim. All prose distinguishes authored policy, synthetic inputs, primary mechanism/context and observed database behavior.

Final full package validator:11 Markdown files, zero errors and zero warnings. Playground validator:one checked, one passed. Public SQL/receipt/validation copies are byte-identical to canonical sources. Metadata private/video-ready means completed source package/script, not public deployment.
