ReviewOS

home-lang/home

Native Blob corpus: activate ownership and allocation tests; remove substitutes

#700
Closed chris opened this 9 days ago ·
9 days ago

Published resolution

Published f491cacd7 to origin/main, authored and committed by Chris Breuer without coauthors.

  • All six unchanged Blob files now execute natively through the ordinary grouped Home command: 65 passes / zero failures, TODOs or unsupported cases, including all four original snapshots. Pinned controls previously established the same 65 tests / 215 assertions / four snapshots.
  • Removed the UTF-16 child-process interception, filename-specific global Object.defineProperty override, and simulated prototype-descriptor lookup, including definitions and call sites. Original ownership loops, allocation-limit APIs, getter/array mutation, child code, GC calls and snapshots remain intact.
  • Final optimized build: 46/46 steps. Focused harness: 23/23 steps / 4/4 tests, with independent metadata confirming the full native matrix, retained bootstrap storage test, removal/workload checks and registration guard.
  • Adjacent ordinary commands pass in this run: body/stream 9,467 passes / four upstream skips, Headers/Response 170/170, Request 24/24, bootstrap FormData 5/5 and microtasks 2/2. The earlier Request deadline failure remains open in #701; this pass does not explain or repair it. #694 also remains open.
  • The stronger source audit compares directly with pinned Git blob objects, preserving raw symlink bytes and executable modes: 12,990 identical regular files / five identical symlinks / zero missing paths / zero mode differences. The sole content difference remains historical expectations.txt metadata. Formatting, documentation Pickier and whitespace checks pass.

#700 is complete for native Blob activation and substitute removal. Full logical parity, aggregate execution, remaining semantic substitutes and native build ownership remain incomplete. #202 now clearly marks the old adapter-green claim as historical evidence rather than current proof of parity. The next HTML web batch is #702: five original files have native Home/Bun baselines of 145 passes / one upstream platform skip / 530 assertions per runtime, with fake FormData child/RSS paths identified for removal.

Verified Home SHA-256: e444d3378dc349b89bf786228995209ae9f6e88d40ceb8ce80d34c12d7c90c65.

Implementation and evidence.


Part of #66 and #202; follows #699's body/stream native activation.

All six original test/js/web/fetch/blob*.test.ts files pass in strict-native Home and pinned Bun. Their ordinary corpus routes still need migration, and the Blob-specific bootstrap substitutions must be removed.

Verified baseline

Bun pin: 4982b91e3702094330f3be3883354c52b8c01323. Home baseline: published commit 649c3c48ffbffcc5f9079704616ce781d9fb709a, binary SHA-256 f7e0abf6e3e75795c70f48221810814e986bcfa52c80cda7a6f614d82a29257f.

Each unchanged file ran once per runtime from the mirrored Bun project root, with upstream startup internal-testing/GC defaults. These are separate per-file native runs, not a full aggregate or ordinary native routing.

Original filePasses each runtimeAssertions each
blob-array-fast-path.test.ts1113
blob-cow.test.ts113
blob-file-name-ownership.test.ts13
blob-oom.test.ts1616
blob-write.test.ts1025
blob.test.ts26145

Total per runtime: 65 passes / zero failures, skips or TODOs / 215 assertions / four original snapshots. The original allocation-limit testing APIs and allocation workloads in blob-oom.test.ts execute as written; no replacement memory counters or added limits were introduced into the tests.

Concrete adapter removals

packages/home_test/src/corpus_runner.zig still contains:

  • __home_spawn_blob_utf16_bom_fixture, which intercepts the original UTF-16 child process and evaluates a substitute decoding path instead of executing the original child.
  • A filename-specific Object.defineProperty override for blob-array-fast-path.test.ts that stores the Array.prototype[1] descriptor separately instead of defining the actual prototype property, plus its synthetic descriptor lookup in Blob parts processing.

Native execution makes these substitutes unnecessary. Remove their definitions and call sites, retain the original subprocess/prototype assertions, and migrate associated bootstrap coverage to real native execution. Remaining unrelated adapters stay tracked in #202.

Acceptance

  • Activate all six original files in ordinary native Home routes using the corrected mirror launch context.
  • Remove the Blob child interception and prototype-descriptor substitute paths; no fallback success responses.
  • Preserve all original array mutation, copy-on-write, file-name ownership, UTF-16, memory-failure, file I/O, snapshot and child-process assertions and workloads.
  • Run focused execution tests with verified discovery, ordinary corpus commands and adjacent body/Request/Headers/Response checks.
  • Re-audit original corpus bytes, push to origin/main as the user without coauthors, and update #66/#202 with exact evidence and remaining scope.

Local evidence: /tmp/home-699-blob-baseline.log, /tmp/home-699-blob-baseline.json, /tmp/home-699-blob-results/.

9 days ago

#699 is published on origin/main in 04644b2d0. All seven original body/stream files now execute natively: 9,467 passes, four upstream skips, zero failures or unsupported cases. The fabricated clone child result, filename-specific chunk deduplication and special clone stream branch are removed. The focused harness passes 4/4 with verified discovery; the optimized build passes 46/46.

#66 is updated and #699 is closed for that completed activation/removal scope. The adjacent original Request deadline failure remains open in #701; a later diagnostic pass was not counted as a repair. #700 is the next Blob activation/removal batch. Full aggregate/parity and the remaining adapters are still incomplete.

9 days ago

The six-file native Blob route, UTF-16 child interception removal, and prototype-descriptor substitute removal are implemented together. The focused matrix executes all original allocation, ownership, getter, UTF-16 and snapshot cases. A retained bootstrap byte-storage regression checks the shared code after removing the global property override. Optimized build and focused execution are running.

Next is #702: all five unchanged HTML web files have separate native Home/Bun baselines of 145 passes, one upstream platform skip and 530 assertions per runtime. That batch explicitly removes the FormData fake JSON child and fabricated RSS-result branch; the original native file-error child measures real memory growth.

The previously observed Request deadline failure remains unresolved in #701 and is not treated as repaired by this work.

9 days ago

Published f491cacd7 to origin/main, authored and committed by Chris Breuer without coauthors.

  • All six unchanged Blob files now execute natively through the ordinary grouped Home command: 65 passes / zero failures, TODOs or unsupported cases, including all four original snapshots. Pinned controls previously established the same 65 tests / 215 assertions / four snapshots.
  • Removed the UTF-16 child-process interception, filename-specific global Object.defineProperty override, and simulated prototype-descriptor lookup, including definitions and call sites. Original ownership loops, allocation-limit APIs, getter/array mutation, child code, GC calls and snapshots remain intact.
  • Final optimized build: 46/46 steps. Focused harness: 23/23 steps / 4/4 tests, with independent metadata confirming the full native matrix, retained bootstrap storage test, removal/workload checks and registration guard.
  • Adjacent ordinary commands pass in this run: body/stream 9,467 passes / four upstream skips, Headers/Response 170/170, Request 24/24, bootstrap FormData 5/5 and microtasks 2/2. The earlier Request deadline failure remains open in #701; this pass does not explain or repair it. #694 also remains open.
  • The stronger source audit compares directly with pinned Git blob objects, preserving raw symlink bytes and executable modes: 12,990 identical regular files / five identical symlinks / zero missing paths / zero mode differences. The sole content difference remains historical expectations.txt metadata. Formatting, documentation Pickier and whitespace checks pass.

#700 is complete for native Blob activation and substitute removal. Full logical parity, aggregate execution, remaining semantic substitutes and native build ownership remain incomplete. #202 now clearly marks the old adapter-green claim as historical evidence rather than current proof of parity. The next HTML web batch is #702: five original files have native Home/Bun baselines of 145 passes / one upstream platform skip / 530 assertions per runtime, with fake FormData child/RSS paths identified for removal.

Verified Home SHA-256: e444d3378dc349b89bf786228995209ae9f6e88d40ceb8ce80d34c12d7c90c65.

Implementation and evidence.

Sign in to comment on this issue.