ReviewOS

home-lang/home

fix(resolver): preserve POSIX semantics for drive-like module paths

#734
Closed glennmichael123 opened this 9 days ago ·
9 days ago

Parent

Confirmed divergence

js/bun/resolve/resolve-error.test.ts aborts Home on import(":://filesystem") with Invalid cache key "::/". The active bun.strings.withoutTrailingSlashWindowsPath copy lacks the POSIX short-circuit present in Bun's live Rust and in Home's two sibling path implementations. On POSIX, "::/" must normalize to "::"; retaining the slash violates the resolver cache-key invariant.

Scope

  • Port Bun live Rust's cfg!(unix) guard into packages/runtime/src/strings.zig.
  • Add focused host-semantics regression coverage.
  • Verify the corpus file against a fresh runtime build before closing.

This is a direct semantic port, not a test or resolver workaround.

9 days ago

Ported and pushed in 3ad4093f3 (fix(resolver): preserve POSIX path semantics (#734)).

  • Active bun.strings.withoutTrailingSlashWindowsPath now takes Bun live Rust's POSIX short-circuit.
  • Added focused regressions for the crashing pseudo-drive root (::/ -> ::) and an ordinary drive-like spelling (C:/ -> C:) on POSIX.
  • Focused ReleaseFast result: 1/1 passed; 255 MB peak supervised tree footprint; host low-water 50%.
  • Commit author: glennmichael123 <gtorregosa@gmail.com>; no coauthors; pushed to origin/main.

Keeping this issue open until js/bun/resolve/resolve-error.test.ts is run against a fresh full runtime build.

9 days ago

Verified end to end on the fresh ReleaseFast runtime at current main (bae99f883):

  • implementation remains in 3ad4093f3;
  • unchanged js/bun/resolve/resolve-error.test.ts: 15 passed, 0 failed;
  • the import(":://filesystem") case completes without the resolver cache-key abort;
  • no test edits, skips, timeout changes, or resolver workarounds were used.

Closing this focused checkpoint as complete. Parent parity tracking continues in #66.

Sign in to comment on this issue.