fix(supabase): sheet-assets guard review LOWs (one destination, no anon key at build, issuer wording)

This commit is contained in:
bchanot committed 2026-11-02 00:34:04 +01:00
1 parent e24e747d90
commit 882905ed21
3 files changed
+6 -6

No files matched your search

+1 -1
View File
@@ -135,7 +135,7 @@ pnpm preview:draft # same, then serves it
pnpm import:equine --check | --out <dir> # since R5.6 the official seed writer: the Rust pipeline (same as `pnpm r5:import-equine`), fingerprint `sha256-rfc8785-validated-v1`; the TypeScript generator left at R5.7 (replayed from a historical revision only, RUST.md §11.23)
pnpm r5:import-equine --check | --out <dir> # the Rust pipeline (R5.2 importer, R5.3 draft, R5.4 review files): compare the 18 generated files with the committed folders (bytes; app drawings under the declared R3 rule), or write <dir>/{legacy-import,draft} into an empty folder; never deletes (scripts/import-equine.sh, first run compiles)
pnpm assets:upload [--check] <seed folder> # R5.5: uploads the sheet drawings of a generated seed folder to the LOCAL stack's private bucket (Rust `upload-sheet-assets`, feature `upload`; SUPABASE_URL local with a port, SUPABASE_SERVICE_ROLE_KEY typed, never printed; no overwrite, confirm after verify; run by hand, scripts/upload-sheet-assets.sh)
pnpm e2e:sheet-assets # scripts/sheet-assets-e2e.sh: sandbox only, refuses before any request unless the sandbox gateway URL and sandbox-issued keys are set (its runner `pnpm db:sandbox sheet-assets-e2e` arrives with V1-2); never DEV
pnpm e2e:sheet-assets # scripts/sheet-assets-e2e.sh: sandbox only, refuses before any request unless the sandbox gateway URL and keys naming the sandbox issuer are set (its runner `pnpm db:sandbox sheet-assets-e2e` arrives with V1-2); never DEV
pnpm report:compare <pdf|dir>... # archive check: attachment vs its v3 reading, unresolved items flagged (docs/PDF-FORMAT.md); the core's `report-compare` binary since R4.7 (scripts/report-compare.sh, first run compiles)
# Rust (docs/development/RUST.md) — native toolchain (user-level rustup, channel of rust-toolchain.toml) first
+1 -1
View File
@@ -159,7 +159,7 @@ never printed and goes through no proxy. `pnpm e2e:sheet-assets` runs the
whole behaviour (upload, rerun, anon and wrong key, refused destinations,
unreachable port) on the throwaway sandbox only: since 2026-11-02 it refuses,
before building or any request, every target but the sandbox gateway
`http://127.0.0.1:57800` with keys issued by the sandbox (its runner
`http://127.0.0.1:57800` with keys naming the sandbox issuer (its runner
`pnpm db:sandbox sheet-assets-e2e` arrives with V1-2); it never reads the DEV
keys and never targets DEV. The TypeScript tool
(`packages/supabase/scripts/upload-sheet-assets.ts`) was deleted at R5.7 (RUST.md §11.23).
+4 -4
View File
@@ -24,8 +24,8 @@ try:
except Exception:
sys.exit(1)'; }
if [ "${SUPABASE_URL:-}" != "$SANDBOX_URL" ] || ! sandbox_key "$SERVICE" || ! sandbox_key "$ANON"; then
echo "sheet-assets-e2e: refused, nothing was run. Sandbox only: the sandbox gateway URL and sandbox-issued" >&2
echo "keys, set by pnpm db:sandbox sheet-assets-e2e where that runner exists; it never targets DEV." >&2
echo "sheet-assets-e2e: refused, nothing was run. Sandbox only: the sandbox gateway URL and keys naming" >&2
echo "the sandbox issuer, set by pnpm db:sandbox sheet-assets-e2e where that runner exists; it never targets DEV." >&2
exit 2
fi
@@ -34,8 +34,8 @@ SEED=supabase/seed/anatomical-sheets/equine/draft
BIN=target/release/upload-sheet-assets
FAIL=0
env -u SUPABASE_SERVICE_ROLE_KEY cargo build --release --locked -q -p faunosteo-core --features upload --bin upload-sheet-assets || exit 2
LOCAL=http://127.0.0.1:57800
env -u SUPABASE_SERVICE_ROLE_KEY -u SUPABASE_ANON_KEY cargo build --release --locked -q -p faunosteo-core --features upload --bin upload-sheet-assets || exit 2
LOCAL=$SANDBOX_URL
# expect <name> <expected exit> <url> <key> <args...>; output kept to grep, keys never echoed.
expect() {