Commit Graph
779 Commits
Author SHA1 Message Date
bchanot 532c61e087 docs(docs): V1-2.1 measured equine size, e2e:sheet-assets citers, logs
The M5 row gives the measured content::text size; §15 and §16.4 point the
e2e:sheet-assets rerun to the owner; the walk log carries its script and
the HTTP timing lines are committed.
2026-10-28 21:15:08 +01:00
bchanot 9350366913 docs(docs): V1-2.1 M5 row, e2e:sheet-assets as an owner step, walk log
Contract §12.3 M5 row names the size CHECK swap and its validation on DEV
rows; §9.5 and §16.11 move the e2e:sheet-assets rerun to the owner (DEV
target). Evidence: 017 count, raw number-walk timings committed.
2026-10-28 21:08:23 +01:00
bchanot 1f9fa8b835 chore(memory): V1-2.1 raw old-schema repro log, evidence, LRN, TODO 2026-10-28 20:51:17 +01:00
bchanot 2379d28d9b test(supabase): V1-2.1 number-walk timing on a small base document 2026-10-28 20:42:52 +01:00
bchanot f9e40ba6aa docs(docs): V1-2.1 the size guard's number walk is linear 2026-10-28 20:34:36 +01:00
bchanot 538d10369f fix(supabase): V1-2.1 walk the document's numbers in linear time
jsonb_path_query row by row is quadratic on PostgreSQL 17: a document of
200k numbers under the cap ran into the statement timeout. One
jsonb_path_query_array call, then its elements. pgTAP 017 saves 600 000
numbers; the perf suite times 600k (saved) and 1M (closed code) over HTTP.
2026-10-28 20:34:35 +01:00
bchanot 7c4bf124f4 chore(memory): V1-2.1 review findings fixed, evidence, TODO, journal 2026-10-28 20:16:34 +01:00
bchanot 5620399492 docs(docs): V1-2.1 size bound on numbers, M7 note in 9.5, old measure
Contract §1 and §9.5 aligned with the text measure and the Git fixture,
§12.2 says where the size vectors live and how numbers are bounded.
2026-10-28 20:08:19 +01:00
bchanot 3eba6d89b2 fix(supabase): V1-2.1 bound printed numbers before the size measure
check_document_structure sums the numbers' printed digits one at a time
before building the whole text, so huge exponents answer
document.too_large instead of an out-of-memory error. pgTAP 020: the
full AR-1 B matrix and the rights RPCs refused to every non-owner; 017:
exponent vectors, the number bomb, publish.species.other alone.
2026-10-28 20:08:18 +01:00
bchanot 12816671e4 chore(memory): V1-2.1 final decisions evidence, BDR-085, TODO, journal 2026-10-28 19:41:17 +01:00
bchanot 7eca44167b docs(docs): V1-2.1 owner decisions M6, M7 fixture and the size measure
Contract §5.2, §5.5 (owner may review others' drafts), §12.2 (one text
measure for SQL, TypeScript and Rust), §12.3 and §16.2 (Git fixture for
the upgrade, live DEV object not read), §15 tests, §17.3 decisions.
2026-10-28 19:32:57 +01:00
bchanot b1de87b5d0 fix(supabase): V1-2.1 owner self-review grant and the text size measure
M6 option A: grant_catalog_right no longer refuses an owner granting
itself sheet_reviewer; authors stay refused at acknowledgment, approval
and publication. The document cap is the UTF-8 bytes of the JSON text:
check_document_structure drops pg_column_size and M5 replaces the base
table CHECK by octet_length(content::text). pgTAP 015 and 017 cover the
owner-reviewer journey and cap - 1, cap, cap + 1, multi-byte, dense.
2026-10-28 19:32:57 +01:00
bchanot 2af61e72cc chore(memory): V1-2.1 portable M7 rehearsal, final evidence 2026-10-28 19:02:12 +01:00
bchanot b9470b4d2d fix(supabase): V1-2.1 take the write budget after the foreign-key locks 2026-10-28 19:02:11 +01:00
bchanot f80f325fd6 chore(memory): V1-2.1 evidence update, M7 rehearsal scripts, TODO, journal 2026-10-28 18:44:00 +01:00
bchanot 961995804a fix(supabase): V1-2.1 close the second verifier and security findings
Save and submit lock the sheet before the version; change_note length and a
blank FR name answer closed codes; pgTAP for a capability refused to a
factorless account and the five remaining historical-sheet RPC refusals.
2026-10-28 18:44:00 +01:00
bchanot 4a829416c6 chore(memory): V1-2.1 corrections evidence, TODO 2026-10-28 18:14:11 +01:00
bchanot a21866e25c docs(docs): drop stale references to the removed SQL mirror and client gate 2026-10-28 18:14:10 +01:00
bchanot ef1f4b593f test(supabase): V1-2.1 re-runnable sandbox suite, two-session cases, caps timing
F18 and workspaces no longer leave the seed owner changed. Ten two-session
scenarios with a blocking session, seed-owner AR-1 acceptance, shim columns
against the image, save/submit/approve/publish timed at the caps.
2026-10-28 18:14:10 +01:00
bchanot d05f75da84 fix(supabase): V1-2.1 audit M1 M2 M3 and LOW fixes in M5
Approval needs an active sheet (lock sheet, version, round); a base only
from a still-published round version; rights.mfa before rights.capability;
withdrawal of a published round refused; approver separation at publish;
deprecate and working copy serialised; closed codes; append-only acks;
upload policy bound to the registering editor. pgTAP 017-019 added.
2026-10-28 18:14:09 +01:00
bchanot 3914eaa866 fix(supabase): V1-2.1 harden M5 after the security and verifier gates
Fresh security audit PASS; verifier ECARTS(10) addressed:
- publish re-checks the approver's sheet_reviewer grant (publish.approval.invalid)
- scope disclaimer enforced at approve and publish (publish.disclaimer.missing, O6)
- to_confirm split from inherited (publish.to_confirm.open distinct from publish.inherited.present)
- save_sheet_draft requires an active sheet; working copy adds the 2 MiB octet_length check
- delete_sheet_asset EXECUTE revoked from service_role (§5.4 surface)
- species table comment updated (§7.2); lease columns dropped from the reviews grant
- lock order sheet->version->round in decide/publish; conflict_retry kind (40001/40P01) in sheets.ts
Tests: pgTAP 016 (omitted status, separation, revoked-reviewer + renewal, ack carry,
inactive-species publish refusal, deprecated-delete, schema_version 1, content-write
without actor, working-copy positive), 001 census (no other writer of profile_roles).
871 real-stack pgTAP / 122 PGlite / 4 sandbox green; typecheck, lint, types drift clean.
2026-10-28 16:20:51 +01:00
bchanot 77e5fa4cf5 feat(supabase): V1-2.1 M4/M5 secure sheet access and review workflow
M4 20261028100000_sheet_access_hardening + M5 20261028110000_sheet_review_workflow
(applied together; no unprotected window). Implements contract §5-§14.

- Catalogue rights table + owner RPCs; has_mfa / has_aal2_session (live
  auth.sessions check); grant_active vs caller_has split; catalogue reader
  predicate; can_edit_sheet on the sheet_editor capability (F14).
- AR-1 B: aal2 required on every platform role change, target verified factor,
  race-free last-owner guard (F18/F19); service_role loses table privileges on
  the catalogue + profiles/profile_roles and EXECUTE on the role RPCs (F12/F17).
- Reviewed lifecycle: version provenance + review columns, content/freeze/
  author triggers, rounds/comments/acknowledgments, save/submit/withdraw/
  comment/acknowledge/decide, atomic publish_sheet_version(review_id) on the
  stored verdict, deprecate/archive/restore, species RPCs, equine working copy,
  uploads with the storage check (F7) + editor INSERT policy + 2 MiB bucket.
  F1-F3,F5,F6,F8,F9,F13,F15,F16 closed. Verdict is a fixture until M6 (V1-2.3).
- O22: SQL business mirror removed, declared status check kept; pgTAP 011 and
  the Rust generator's SQL parts deleted, ledger retargeted.
- Access layer sheets.ts (closed SheetFailure kinds); old client publish gate
  deleted; types regenerated; upload tool reads via get_sheet_asset_state.

Tested on the throwaway sandbox only; DEV untouched. pgTAP 850 (real stack) /
122 (PGlite) green; real-GoTrue AR-1 B + F18 race green; fresh install and
M3->M5 upgrade green; V1-1 regression green; rust:check, typecheck, lint,
build, types drift clean. BDR-084, LRN-095.
2026-10-28 15:52:49 +01:00
bchanot 9c13bae4bc docs(security): ratify AR-1 MFA for platform roles
AR-1 option B (BDR-083): aal2 for every platform role change. Contract 5.7 rule, path inventory, bootstrap, factors, recovery, sessions; F17-F19; M4 scope, tests, DEV preconditions; fresh security review integrated (19.4).
2026-10-28 12:20:11 +01:00
bchanot 41d3b09120 chore(memory): BDR-082 V1-2 decisions ratified, TODO, journal 2026-10-28 11:35:52 +01:00
bchanot 7fec2ce86f docs(docs): consolidate V1-2 contract with ratified O1-O23, open AR-1 2026-10-28 11:35:51 +01:00
bchanot 397d6007b4 chore(memory): V1-1 closed in TODO, V1-2.0 plan line, BDR-081, journal 2026-10-27 22:36:49 +01:00
bchanot 78636d0bd5 docs(docs): draft V1-2 anatomical sheets contract, record V1-1 merge 2026-10-27 22:36:48 +01:00
bchanot 9135d73cfa merge: integrate V1-1 clients and animals into develop
ci / rust (push) Canceled after 0s
ci / check (push) Canceled after 0s
ci / docker (push) Canceled after 0s
ci / supabase (push) Canceled after 0s
2026-10-27 19:54:09 +01:00
bchanot f93412c8e9 docs(supabase): close RESP-01, AVATAR-01 class A, AVATAR-02 ticket 2026-10-27 19:44:36 +01:00
bchanot 7e40c44a64 chore(memory): RESP-01 fix, AVATAR-01 diagnosis, LRN-094 2026-10-27 19:37:55 +01:00
bchanot 8c8478c052 docs(supabase): DEV acceptance run, RESP-01 and AVATAR-01 recorded 2026-10-27 19:37:55 +01:00
bchanot a70166ea11 fix(app): dashboard cards keep the screen width with a long e-mail
The card grid had no explicit column below md: its implicit auto track
took the cards' min-content, so the account e-mail never truncated and
pushed the page sideways. One minmax(0,1fr) column; the e-mail wraps.
e2e/shell/responsive.spec.ts sweeps 320-430 px and desktop (RESP-01).
2026-10-27 19:37:54 +01:00
bchanot dd5a23c39d chore(memory): journal — CLAUDE.md split into .claude/rules/ (0b) 2026-10-27 16:05:06 +01:00
bchanot 7a75974dc3 chore(docs): split 11 CLAUDE.md sections into .claude/rules/ 2026-10-27 16:04:30 +01:00
bchanot 78aacc09e1 chore(memory): DEV migration, db:test run 1, pgTAP fix, LRN-093 2026-10-27 14:44:03 +01:00
bchanot 7244648b4c test(supabase): pgTAP 007 and 010 independent of the base's data 2026-10-27 14:44:03 +01:00
bchanot 6c36e2f22d docs(supabase): sandbox role prerequisite for the DEV restore check 2026-10-27 13:52:05 +01:00
bchanot 545a161f69 chore(memory): restore check rehearsal 2, LRN-091 2026-10-26 22:00:52 +01:00
bchanot fcac11294b docs(supabase): restore check on a filtered TOC that must exit 0 2026-10-26 22:00:51 +01:00
bchanot a2507fc083 docs(supabase): restore check reads pg_restore exit and every error 2026-10-26 21:46:02 +01:00
bchanot 9570089147 chore(memory): V1-1.6 validated, DEV checkpoint prep, BDR-080, LRN-090 2026-10-26 18:29:29 +01:00
bchanot e3b841799a docs(supabase): DEV procedure with read-only checks and sandbox restore
Preflight of DEV recorded; backup adds row fingerprints and Storage bytes; restore check runs on the isolated stack; post-migration SQL, test effects, failure and restore effects; browser acceptance aligned on the owner brief.
2026-10-26 18:29:28 +01:00
bchanot 9f585e9185 chore(memory): EVAL-041, V1-1.6 journal, TODO, gate outcomes in contract §11.8 2026-10-26 18:03:03 +01:00
bchanot e7fd7e34e6 test(supabase): the audit privacy check no longer reads a uuid as a date
014 #237 matched « 20[0-9]{2}- » inside a workspace uuid on a long-lived stack.
The pattern now reads the metadata without workspace_id, still over every
audit row. It would have stopped the DEV procedure at db:test. Found by the
V1-1.6 verifier.
2026-10-26 17:53:37 +01:00
bchanot 10413478fb test(app): every shell suite drops late replays after a test
The client journey could fail after it passed: since V1-1.6 the client page
reloads its animals after a restore, and that replay outlived the test. One
support helper unroutes without waiting, for the three shell specs. Found by
the V1-1.6 verifier. Memory: BDR-079, LRN-087 to 089.
2026-10-26 17:38:52 +01:00
bchanot 212392263c chore(memory): V1-1.6 progress in TODO, gate contract 2026-10-26 17:24:56 +01:00
bchanot e215e9b2cb docs(docs): V1-1.6 as built, D11 drawer only, closure inventory, DEV steps
Contract §11.8 and §15; D11 and U3 decided, D12 open; SUPABASE.md §3.3 gains
the rehearsed restore check and the owner's browser acceptance on DEV; browser,
test and frontend docs, design README, CLAUDE.md map.
2026-10-26 17:24:19 +01:00
bchanot 3e968eeeab test(app): Playwright animal and relation journeys on the sandbox
Ten journeys, FR and EN, desktop and 375 px, axe on every state. Seeds go
through quoted SQL literals; db:sandbox e2e-shell passes its arguments to
Playwright.
2026-10-26 17:11:29 +01:00
bchanot 930499cd25 feat(app): animal screens, relation panels, animals on the client page
Routes /app/animals, new, :animalId, edit under one workspace gate; list with
species filter; form (D-R7, U3 birth, no default sex or role, optional first
client); page with current and former relations, end, dates, void; client page
links its animals, adds one pre-associated, links an existing one. Card now
passes aria-labelledby, which it silently dropped.
2026-10-26 17:11:28 +01:00
bchanot e22357630f feat(supabase): animals and relations access layer
animals.ts: POST search with species filter and a probe row, read by id with
explicit columns, create with the optional first client in one call, update,
archive. relations.ts: an animal's relations in one select (voided left out),
create, end, dates, void. Kinds duplicate_relation and already_ended added.
2026-10-26 17:11:23 +01:00