14 Commits
Author SHA1 Message Date
bchanot 2c445063a4 feat(supabase): R5.5 upload-sheet-assets in Rust, R5.4 caps and FLOOR clarification
Core rules curation::upload (manifest, local destination, bytes through the SVG reader,
plan from observed state); binary upload-sheet-assets over ureq (handshake, no overwrite,
confirm after verify, bounded retries, key never printed); pnpm assets:upload repointed,
e2e:sheet-assets for the local stack. 4 MiB cap on changes.json and references.json.
FLOOR clarification for audit prose with its negative proof.
2026-10-23 21:15:22 +02:00
bchanot 03bdb5eaa0 feat(anatomy): R5.2 legacy importer in Rust (curation feature, import-equine --check/--out), Prettier JSON and table layout, JS semantics; parity oracles frozen from the TypeScript 2026-10-22 21:14:45 +02:00
bchanot aed6b1e300 fix(domain): js_number rounds exact decimal ties to even as ECMAScript (zmij digits); V8 oracle of 44,322 values, Zod oracle bytes checked against the core's printing 2026-10-22 20:50:32 +02:00
bchanot a604c07f50 test(worker): the HTTPS client refuses a self-signed server certificate (in-process rustls server, rcgen dev-dependency) 2026-10-21 17:23:38 +02:00
bchanot 7a7b71cf1b chore(worker): rustls-webpki 0.103.16 and webpki-roots 1.0.10 (RUSTSEC-2026-0382, RUSTSEC-2026-0381) 2026-10-21 17:18:37 +02:00
bchanot 50c8fe0b33 feat(domain): R4.5e wasm proof export, resources per page, N-1 and TS-engine read-back, cost comparison
export_pdf_for_test on the proofs build (ExportInput JSON + base64 rasters): the 14 O2
runs give the native digests through wasm; the frozen O11 scanner reads every R4 PDF and
the N-1 Zod readers accept its envelope; a stripped R4 PDF answers attachment_stripped;
the TypeScript engine reads the R4 PDFs back to the R3 outcome; E2 size ≤ R3 + 5 %. Page
resources list the images the page draws (listing every embed cost 9 MB on CAP). Node,
stub rasters, TS → Rust: demo 198 → 36 ms, L 772 → 57 ms, CAP 5.7 s → 0.22 s; files
236 KB, 386 KB, 1.6 MB against 243 KB, 463 KB, 2.2 MB. Module with the writer linked
(proofs build): 531.6 KB gzip; shipped unchanged at 426 KB until R4.6 links it.
2026-10-18 23:21:05 +02:00
bchanot 5dd4c26f18 chore(domain): R4.5 scaffold: content and png modules, test targets, lopdf as a dev-dependency 2026-10-18 22:41:46 +02:00
bchanot 21d34fb9a7 feat(domain): R4.2 scaffold of the pdf reader module (feature pdf-read, miniz_oxide)
Module layout of plan §B.1.1 for the reader (read/{scan,strings,stamp,inflate,probe},
json_js), shared constants and types, index_of; feature-gated test targets; the wasm
facade enables the feature; rust-check runs the gated clippy and tests.
2026-10-18 15:29:58 +02:00
bchanot e3168215f7 test(pdf): R3 O4 corpus edge cases (Number() values, namespaces, BOM, refused subtrees); roxmltree dependency 2026-10-14 23:34:34 +02:00
bchanot f99b4a581f fix(worker): bump rustls to 0.23.46 (RUSTSEC-2026-0346..0349) 2026-10-14 22:26:39 +02:00
bchanot ee0700887f feat(domain): R2.1 Rust contracts of the sheet, report and archive documents
Sheet document v2, report v3 / v2 / identity, migration map, sheet snapshot,
branding, PDF labels and archive envelope ported from the Zod schemas with
their exact semantics: strict objects where Zod is strict, optional fields
absent (never null), nullable fields required, integers as JavaScript
numbers, UTF-16 caps, hand-checked patterns, url crate for .url(), lone
surrogate escapes read as U+FFFD (L1, owner confirmation pending).
Fields in Zod schema order (PDF labels in the engine dictionary order):
the curated and legacy sheets, the demo report and the three frozen
archive envelopes print byte for byte as their Zod / attachment form.
ts-rs types regenerated; plan rev 2 after three plan challenges.
2026-10-14 00:04:01 +02:00
bchanot 0410af0c35 feat(worker): R1 job loop — claim, download, sandboxed decode, clean upload, commit, purge sweeps
Keyed parent on ureq 3 (rustls + ring, bundled roots), no async runtime:
config from the environment (secret never printed, JWT expiry logged), JSON
line logs with a field allowlist (child stderr escaped and truncated), strict
key validation before any URL, Backend trait over PostgREST RPCs and Storage
objects with closed error kinds, one job per claim with the STORAGE.md §3.4
mapping (content codes, processing_error on signals / timeout / overflow,
Broken stops the loop with exit 20, a refused commit deletes nothing), sweeper
(expire pending, purge queue, quarantine leftovers), per-stage watchdog
(exit 21), WORKER_ONCE for tests, run --check extended. 11 loop tests on a
fake backend and decoder; sandbox tests and seccomp derivation unchanged
(the child still makes the same 7 syscalls); image 11.6 MB.
2026-10-13 19:32:38 +02:00
bchanot a8b644a515 fix(worker): second security pass — content-only rejection codes (resource_limit, explicit list), negative proofs of the seccomp argument filters, PR_GET_DUMPABLE self-check, strict WebP chunk structure, iCCP-bomb fixture, separate test target cache; ci: release-images builder actually used (job-level DOCKER_CONFIG, --builder), literal cleanup path, token scoped to the login step, npm advisories gate, digests from build metadata 2026-10-13 00:36:30 +02:00
bchanot 2a38fa37b5 chore(workspace): Rust workspace R0 — builder image, core crate (JS-compatible JSON, report contracts, facade), wasm facade, core-wasm package with proofs 2026-10-13 00:01:25 +02:00