Homebrew VFS: Reuse declared lazy-bundle outputs for shell archives#1037
Merged
Conversation
Phase B-1 matrix build status —
|
| Package | Arch | Status | Sha |
|---|---|---|---|
| kandelo-sdk | wasm32 | built | fc1d0809 |
| nethack-browser-bundle | wasm32 | built | c50cb85a |
| rootfs | wasm32 | built | b1f4c0f2 |
| vim-browser-bundle | wasm32 | built | cf5f9141 |
| shell | wasm32 | built | 3b6ac0b5 |
| lamp | wasm32 | built | 01a260b1 |
| node-vfs | wasm32 | built | f3751905 |
| wordpress | wasm32 | built | d2d574b8 |
Auto-generated; replaced on each push. Raw data in the publish-status workflow artifact.
brandonpayton
force-pushed
the
fix/shell-use-declared-lazy-bundles
branch
2 times, most recently
from
July 21, 2026 09:03
0448037 to
56cd0e0
Compare
Canonicalize archive order, timestamps, modes, compression metadata, and symlink storage so independent producer and image jobs share one byte identity. Cover the canonical bytes and VFS registration contract with a cross-tool fixture.
brandonpayton
force-pushed
the
fix/shell-use-declared-lazy-bundles
branch
from
July 21, 2026 11:51
56cd0e0 to
afcd937
Compare
|
prepare-merge: test-gate passed against the synthetic PR merge and sealed |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The shell image records lazy ZIP metadata for Vim and NetHack. It previously
rebuilt those ZIPs even though Kandelo already publishes
vim-browser-bundleandnethack-browser-bundleoutputs. Separate ZIP buildscan contain the same files but still produce different bytes because path
order, timestamps, permissions, environment options, or ZIP metadata differ.
That is what the new lazy-archive integrity check in #1024 exposed: the shell
recorded one Vim digest while Chromium fetched a different, independently
generated Vim ZIP. The integrity check correctly rejected the mismatch.
What changes
Use one declared producer
shelldepend on the Vim and NetHack browser-bundle packages insteadof the underlying program packages.
programs/wasm32/vim.zipandnethack.zipoutputs. The shell no longer rebuilds either archive or falls back to a
public-directory copy.
executable, and derive its byte length and SHA-256 from those exact bytes.
Make independent bundle builds byte-reproducible
compression level, locale, timezone, and host-specific ZIP fields.
registration.
4, and keep the shell bump from revision 13 to 14.
Protect the lazy-archive mount boundary
mappings, or group metadata.
and non-directory-ancestor member paths.
Missing, corrupt, wrong, non-reproducible, or path-escaping bundle outputs now
fail at the producer/consumer contract instead of being hidden by a lookalike
rebuild or partially mutating the VFS. This is a packaging, host-VFS, and VFS
build change; it does not change the kernel or weaken #1024.
Validation
bytes/digests, deterministic ZIP bytes, canonical entry order, permissions,
local and central timestamps/extra fields, DEFLATE bytes, symlink
preservation and VFS registration, resolver calls, fail-loudly stat and
newline boundaries, missing/corrupt/wrong outputs, no fallback, and package
declarations.
symlink traversal proofs plus absolute, backslash, empty-component,
duplicate, and non-directory-ancestor rejection before any VFS/group
mutation.
67b198037eb2b47e6d5acadbdfc94f25ec83c469c5374d719342392b08ef0bd0from source trees with different creation order, mtimes, permission bits,
timezone,
SOURCE_DATE_EPOCH, andZIPOPT. It passed with both the Darwinand GNU command sets in the repository dev shell and asserts that the large
fixture member uses DEFLATE.
shell builder, and both focused test files.
bash -npassed for the shared ZIP helper and both bundle builders.vim-browser-bundle:cf5f9141bfc5047f7548121cafb993708a8da25b2639967cc603e4d0347a4347nethack-browser-bundle:c50cb85a33c8e4dd8157998a3c7fde468d33193054b7f0ce6cef111ccb26b011shell:802b871c980a8d8e44b28ab25a0a6947e6b350f93e2b4825ad4345553f5ede7dvim.zipandnethack.zip.git diff --checkpassed.The full repository test path is left to CI because a fresh isolated checkout
does not have the prebuilt sysroot needed by the unrelated global C-fixture
setup.
#1024 handoff
Current main does not yet accept integrity metadata in
registerLazyArchiveFromEntries, so this PR returns the exact computedintegrity without pretending an ignored argument is enforced. After this
producer fix lands, #1024 must rebase onto it, pass
archive.integrityintothe real integrity-aware registration API, and rerun the exact Chromium proof.
Both halves are required.