From 073b25e52b1650b9217e3fe01ccecdec4b2c3e86 Mon Sep 17 00:00:00 2001 From: bchanot Date: Tue, 13 Oct 2026 09:46:07 +0200 Subject: [PATCH] docs(docs): gate stages (drift, advisories), native exposure note, CI target wording, check:all in WORKSPACE and TEST_STRATEGY --- docs/development/RUST.md | 17 ++++++++++++++--- docs/development/RUST_ARCHITECTURE_REVIEW.md | 2 +- docs/development/TEST_STRATEGY.md | 15 ++++++++++----- docs/development/WORKSPACE.md | 3 ++- 4 files changed, 27 insertions(+), 10 deletions(-) diff --git a/docs/development/RUST.md b/docs/development/RUST.md index c73e2dd1..038c3625 100644 --- a/docs/development/RUST.md +++ b/docs/development/RUST.md @@ -91,6 +91,14 @@ separate caches; neither invalidates the other. uses; it is not needed for a compile or a test on the development machine. +Exposure change, stated for the record: a native build runs the build +scripts and proc-macros of the dependencies under the user account (the +builder container ran them with the repository mounted read-write, so the +difference is the rest of the home directory). Mitigations in place: +`--locked` everywhere, `deny.toml` `[sources]` limited to crates.io with +unknown registries and git sources denied, `cargo deny check licenses bans +sources` in every check. + ## 2. Workspace ```text @@ -203,7 +211,10 @@ pnpm check:all # scripts/check-all.sh, stops at the first failure ``` Stages, in order: `scripts/rust-check.sh` (native), the ts-rs types drift -(`git diff --exit-code -- packages/core-wasm/types`), `scripts/wasm-build.sh` +(`git status --porcelain -- packages/core-wasm/types` must be empty: a +modified or a new type file both fail), `cargo deny check advisories` +(warn-only: out of the blocking path by design, review VIII.3, but printed +here because no nightly job runs yet; needs the network), `scripts/wasm-build.sh` (native), `pnpm check` (typecheck, tests including the `core-wasm` proofs on the module just built and the pgTAP suite on PGlite, lint, build), the application image, `pnpm worker:test` (sandbox tests and seccomp derivation @@ -235,8 +246,8 @@ same scripts: `faunosteo_worker:` and print their digests. Deploys nothing (DEPLOY.md "Image deploy by digest"). -Target of the future CI/CD step (not implemented, recorded so the scripts -stay compatible): tests on every push and pull request, Rust and +Target of the future CI/CD step (planned, not yet built; recorded so the +scripts stay compatible): tests on every push and pull request, Rust and TypeScript checks, PostgreSQL/RLS tests, Docker builds, security checks, branch verification before a merge, image publication only in an explicitly authorised workflow. diff --git a/docs/development/RUST_ARCHITECTURE_REVIEW.md b/docs/development/RUST_ARCHITECTURE_REVIEW.md index aa1806cd..1fabc9bc 100644 --- a/docs/development/RUST_ARCHITECTURE_REVIEW.md +++ b/docs/development/RUST_ARCHITECTURE_REVIEW.md @@ -1011,7 +1011,7 @@ and VIII.4 and are implemented on `feature/rust-r0-foundation`: workflow is never reported as passed before it has run on the forge. The pre-merge gate is local: `pnpm check:all` (`scripts/check-all.sh`), which a future runner calls as is. -- Target of that future step (not implemented): tests on every push and pull +- Target of that future step (planned, not yet built): tests on every push and pull request, Rust and TypeScript checks, PostgreSQL/RLS tests, Docker builds, security checks, branch verification before a merge, image publication only in an explicitly authorised workflow. diff --git a/docs/development/TEST_STRATEGY.md b/docs/development/TEST_STRATEGY.md index eaffd0a8..8786646d 100644 --- a/docs/development/TEST_STRATEGY.md +++ b/docs/development/TEST_STRATEGY.md @@ -76,12 +76,17 @@ Target after Step 1: roughly 230–250 cases, all current ones untouched. - Golden PDFs are compared by extracted text and attachment JSON, not by bytes (pdf-lib dates and ids vary); raster hash only on fixed-size inputs. -## 5. CI gates +## 5. Gates before a merge, and the CI target -Per PR: `pnpm typecheck`, `pnpm lint` (0 warnings), `pnpm test:run`, -`pnpm build`; when `supabase/` changes: `supabase db reset`, `supabase test -db`, types diff. Nightly: Playwright suite. Release: full RLS matrix, -backup/restore rehearsal checklist, `pnpm audit`, secret scan. +Today (2026-10-13) no CI runs on the forge; the gate is run on the +development machine: `pnpm check:all` (`docs/development/RUST.md` §4) before +every merge, plus `supabase db reset`, `supabase test db` and the types diff +when `supabase/` changes. The workflow files under `.gitea/workflows/` are +prepared for a future runner and call the same scripts. + +CI target (planned): per PR the stages of `pnpm check:all`; nightly the +Playwright suite and `cargo deny check advisories`; at release the full RLS +matrix, the backup/restore rehearsal checklist, `pnpm audit`, a secret scan. ## 6. Numbers to track diff --git a/docs/development/WORKSPACE.md b/docs/development/WORKSPACE.md index c25a8168..3e751080 100644 --- a/docs/development/WORKSPACE.md +++ b/docs/development/WORKSPACE.md @@ -92,7 +92,8 @@ works as `corepack pnpm `. | `pnpm test` | vitest watch for `apps/app` | | `pnpm lint` | ESLint, 0 warnings, in every package | | `pnpm build` | typecheck + Vite build in every package | -| `pnpm check` | typecheck, test:run, lint, build in sequence (what CI runs) | +| `pnpm check` | typecheck, test:run, lint, build in sequence (the Node gate) | +| `pnpm check:all` | the whole pre-merge gate: native Rust check, types drift, wasm build, `pnpm check`, application and worker images (`docs/development/RUST.md` §4; no CI runs it yet) | | `pnpm format` | Prettier on the whole repository | Package-scoped: `pnpm --filter @faunosteo/app