Commit Graph
14 Commits
Author SHA1 Message Date
bchanot ac5fbfbc44 feat(supabase): owner trial sandbox commands and the V1-2.6 trial guide 2026-11-04 14:11:23 +01:00
bchanot f924ad056d test(supabase): sheet-assets e2e on the sandbox only
pnpm e2e:sheet-assets is now an alias of pnpm db:sandbox sheet-assets-e2e:
gateway on 127.0.0.1:57800 (occupied port refused), the runner refuses any
URL but the sandbox gateway and any key not issued by the sandbox, before
building or any request; no DEV URL, port or key remains.
2026-11-02 00:09:02 +01:00
bchanot 3c141c942b fix(supabase): targeted review LOWs on retry and sandbox isolation
fail_sheet_verification refuses lease_expired (the claim's record, never a
worker report); the sandbox state dir guard resolves the repository path; the
avatar suite also refuses keys not issued by the sandbox. pgTAP 021: 90.
2026-11-01 23:13:42 +01:00
bchanot cdd43ac431 test(supabase): avatar e2e on the sandbox only, per-session seed secret
pnpm e2e:avatar is now an alias of pnpm db:sandbox avatar-e2e and the DEV
script scripts/avatar-e2e.sh is removed; the suite fails on any target but
the sandbox gateway and database; an occupied port 57800 stops the run before
anything starts. The sandbox replaces the seed accounts' DEV password by a
per-session secret.
2026-11-01 22:55:23 +01:00
bchanot 2a84e3702e test(supabase): avatar suite on the sandbox, per-run sandbox passwords
pnpm db:sandbox avatar-e2e runs tests/e2e/avatar-flow.e2e.ts with the real
worker (default mode) on the throwaway stack; the suite now requires its
database container by name, makes both accounts per run and expedites only
its own purges. Throwaway sandbox accounts get random passwords per run.
2026-11-01 21:02:59 +01:00
bchanot 6aa85fe7e4 fix(worker): V1-2.3 hostile corpus through verify, verdict and memory caps aligned 2026-11-01 17:55:49 +01:00
bchanot 5afb34ed0f test(supabase): V1-2.3 verification worker end to end on the sandbox 2026-11-01 17:34:33 +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 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 2dc04bcfba chore(supabase): sandbox upgrade can stop at an intermediate migration
`pnpm db:sandbox up upgrade <version> <then>` applies the migrations before
<then> over the seeded older base, reports the workspaces, then the rest: the
path of a DEV database that took M1 first and M2 + M3 later.
2026-10-26 00:52:21 +01:00
bchanot e3a2b3e114 test(app): authenticated shell suite on the isolated stack
pnpm e2e:shell (db-sandbox e2e-shell) builds a Vite server on 127.0.0.1:5192 against a Supabase URL that resolves nowhere and replays its calls on the sandbox. Per-test fictitious accounts through the admin API, a clean avatar seeded: sign-in, dashboard, the photo confirmation with a slow removal, the phone drawer, FR and EN, axe. No trace kept, fixture values masked in reports.
2026-10-25 22:46:19 +01:00
bchanot 57922e0902 fix(supabase): refuse bad sandbox arguments before starting anything
pnpm db:sandbox up with an unknown mode or a missing or malformed upgrade version started four containers and wrote the secrets before refusing. The mode and the version (fourteen digits) are now checked first.
2026-10-25 22:20:55 +01:00
bchanot a945e79131 fix(supabase): keep sandbox secrets off command lines and DEV out of reach
Security gate findings on db-sandbox.sh: containers get secrets from 600 env files, psql and the CLI read PGPASSWORD (no password in --db-url), an incomplete secrets file stops the script before any CLI call, the state folder is refused inside the repository.
2026-10-25 21:27:29 +01:00
bchanot 08abe42c48 test(supabase): isolated Supabase stack and real-stack suite for M1
scripts/db-sandbox.sh (pnpm db:sandbox): DEV images on an own network, loopback ports distinct from DEV, no volume, secrets generated outside Git; fresh and upgrade modes through the CLI's migration up, test db and gen types with --db-url. packages/supabase/tests/sandbox: M1 sign-up and confirmation, reads and refusals per role, residual GoTrue admin path, correlation cap, concurrent sessions.
2026-10-25 20:57:09 +01:00