Skip to content

v0.5.2 — native dust-sync sidecar ships to npm

Choose a tag to compare

@nel349 nel349 released this 11 Sep 03:36
· 160 commits to main since this release
3a9c0bd

📦 npm: https://www.npmjs.com/package/midnight-wallet-cli/v/0.5.2 — npm i -g midnight-wallet-cli@0.5.2

Added

  • The native dust-sync sidecar now ships to npm — fast cold dust sync out of the box. Until now the Rust sidecar was source-only, so every npm install fell back to the WASM reader (~22 min for a cold ~1.45M-event preprod prime vs ~4.5 min native); native was reachable only from a repo checkout or via MN_DUST_SYNC_BIN. The prebuilt binary now ships as per-platform packages (@nel349/dust-sync-<os>-<arch> for darwin-arm64/x64, linux-x64/arm64, win32-x64), wired as optionalDependencies so npm installs only the one matching the host and a platform with no published binary still installs fine and falls back to WASM. A GitHub Actions matrix builds each target on its native runner (Cargo pins --locked to ledger-v8 =8.1.0 so the serialized DustLocalState round-trips byte-identically) and publishes the platform packages before the main package. resolveSidecarBinary() already preferred this package; it now finds it on a plain install. MN_DUST_SYNC_BIN still overrides; MN_DISABLE_NATIVE_DUST=1 still forces WASM.

Fixed

  • mn serve no longer orphans its heap-bumped child when the launcher is killed. Facade commands re-exec themselves with a larger --max-old-space-size (the heap-guard), and the re-exec'd child is the process that binds the serve port. The launcher previously ignored SIGINT/SIGTERM (it blocked in spawnSync), so kill <launcher-pid> was swallowed and the child kept running and holding the port. The launcher now forwards SIGINT/SIGTERM/SIGHUP to the child and force-kills it on any exit, and the child self-terminates if it gets reparented (the uncatchable kill -9 <launcher> case). Verified live: killing only the launcher now takes the child down and frees the port.

Package on npm: https://www.npmjs.com/package/midnight-wallet-cli

Full changelog: https://github.com/nel349/midnight-wallet-cli/blob/main/CHANGELOG.md