diff --git a/.claude/audits/2026-10-28-v1-2-1-corrections-evidence.md b/.claude/audits/2026-10-28-v1-2-1-corrections-evidence.md index b309e9ef..0d58efc3 100644 --- a/.claude/audits/2026-10-28-v1-2-1-corrections-evidence.md +++ b/.claude/audits/2026-10-28-v1-2-1-corrections-evidence.md @@ -58,10 +58,10 @@ files of this pass: | Run | Fresh stack | Upgraded stack (M3 + drawing object, then M4+M5) | |---|---|---| -| pgTAP (`test-db`) | 1 333/1 333 (final HEAD; 1 325 at 4a82941) | 1 325/1 325 (at 4a82941) | +| pgTAP (`test-db`) | 1 333/1 333 | 1 333/1 333 | | sandbox suite, run 1 | 86/86 | 86/86 | | sandbox suite, run 2 (same stack) | 86/86 | 86/86 | -| pgTAP again after both suite runs | 1 333/1 333 | 1 325/1 325 | +| pgTAP again after both suite runs | 1 333/1 333 | 1 333/1 333 | | `types --check` | | types match | PGlite: 127/127 (packages/supabase: the 17 pgTAP files and the closed-code census). @@ -100,6 +100,7 @@ drawing placed as the operator tool placed it on DEV (the Git file bytes (sha256 equal to the key); the same editor at aal1, a catalogue reader and an anonymous caller are refused (the historical sheet has no published version). -The rehearsal is reproducible: `2026-10-28-v1-2-1-m7/m7-rehearsal.sh` (sandbox only; it applies +The rehearsal is reproducible from the repository, re-run at the final HEAD with the same +results: `bash .claude/audits/2026-10-28-v1-2-1-m7/m7-rehearsal.sh [work dir]` (sandbox only; it applies M4+M5 with `supabase migration up --db-url` on the sandbox port, a step `scripts/db-sandbox.sh` has no subcommand for) and `m7-read.mjs` (the reads with real tokens). diff --git a/.claude/audits/2026-10-28-v1-2-1-m7/m7-rehearsal.sh b/.claude/audits/2026-10-28-v1-2-1-m7/m7-rehearsal.sh index c3aa8cad..eab14f2e 100755 --- a/.claude/audits/2026-10-28-v1-2-1-m7/m7-rehearsal.sh +++ b/.claude/audits/2026-10-28-v1-2-1-m7/m7-rehearsal.sh @@ -5,10 +5,13 @@ # operator tool did on DEV (Git bytes, service-key upload, pre-M4 confirmation RPC), # snapshots bytes and metadata, applies M4+M5 with the CLI, snapshots again, compares. set -uo pipefail -S=/tmp/claude-1000/-home-bchanot-Documents-faunosteo/57f363af-09e1-44d4-88b0-b4d55155b08e/scratchpad -WT=/tmp/claude-1000/-home-bchanot-Documents-faunosteo/e641af9a-743e-46d0-9804-99667836040e/scratchpad/v1-2 -BASE=$S/m7/base-$(date +%s) -OUT=$S/logs/m7 +# Usage: bash .claude/audits/2026-10-28-v1-2-1-m7/m7-rehearsal.sh [work dir] +# The work dir (default: a new mktemp directory) receives the base copy and the logs. +HERE="$(cd "$(dirname "$0")" && pwd)" +WT="$(cd "$HERE/../../.." && pwd)" +WORK="${1:-$(mktemp -d)}" +BASE=$WORK/base-$(date +%s) +OUT=$WORK/logs STATE="$HOME/.cache/faunosteo-db-sandbox" mkdir -p "$OUT" @@ -72,7 +75,7 @@ sleep 2 snapshot after # 5. Reads through the migrated policies with real tokens. -node "$S/m7/m7-read.mjs" "$KEY" > "$OUT/reads.json" +node "$HERE/m7-read.mjs" "$KEY" > "$OUT/reads.json" # 6. The comparison: everything but the bucket limit identical. diff "$OUT/snapshot-before.txt" "$OUT/snapshot-after.txt" > "$OUT/snapshot.diff" || true cmp "$OUT/bytes-before.svg" "$SVG" && cmp "$OUT/bytes-after.svg" "$SVG" && echo "bytes identical to the Git file before and after" > "$OUT/bytes.result"