Skip to content

Masa v1.8.1 — brew polish: bounded curl, per-formula info lookup, linear JSON walk

Latest

Choose a tag to compare

@ClausValcaTD ClausValcaTD released this 18 Nov 18:20

Masa v1.8.1 is a focused performance and reliability polish of the
Homebrew layer added in v1.8.0 — no behaviour changes to the compiler, the
runtime or the terminal, just a masa brew that never hangs and never
drowns in a 30 MB index.

Highlights

masa brew can no longer hang on a stalled mirror

Every curl call now goes through one helper carrying a 10 s connect
timeout and a 60 s overall limit
:

masa brew update   # download formula.json
masa brew fetch wget   # download one formula's archive

A slow, half-open or wedged mirror now fails with a clear message instead of
blocking forever.

masa brew info <name> no longer needs the whole index

masa brew info <name> used to require a prior masa brew update that
downloaded the full ~30 MB formula.json. Now, when that cache is
missing — or simply does not hold the name — it queries the tiny
per-formula endpoint instead:

# No `masa brew update` needed; hits <base>/formula/wget.json (~2 KB)
masa brew info wget

$MASA_BREW_API_BASE still overrides the https://formulae.brew.sh/api
base, and a file:// base (or a bare path) is read straight from disk, so
the whole path stays testable offline.

Strictly linear JSON walk

The dependency-free JSON reader sized each decoded string's buffer to the
rest of the document, which made a full walk of formula.json quadratic
in both time and allocation. It now measures each string first, so the scan
is strictly O(N). On a 12.6 MB index:

before after
masa brew info (worst case) ~301 s ~0.25 s

— roughly a 1200× speed-up, with no change to the parsed results.

Everything from before

v1.8.1 builds on v1.8.0 (a full multi-tab masa-term with scrollback and
clipboard, pbcopy/pbpaste shims and the online Homebrew index), v1.7.0
(online Homebrew taps, casks and partial Flutter/Dart framework stubs),
v1.6.0 (Danroot Layer 5 — clean-room AppKit and CoreGraphics over SDL2),
v1.5.0 (the cross-architecture bridge), v1.4.0 (CoreFoundation + Objective-C
runtimes), v1.3.0 (virtual root) and v1.2.0 (dynamic library loading) — see
the README.

Packages

Platform Archive
Linux x86_64 masa-1.8.1-linux-x86_64.tar.gz / .zip
Windows x86_64 masa-1.8.1-windows-x86_64.tar.gz / .zip
Android aarch64 masa-1.8.1-android-aarch64.tar.gz / .zip

Each archive contains the masa binary, the README.md and the LICENSE.
Verify with sha256sum -c SHA256SUMS.

Verification

  • 131 core tests, 0 failed, 3 skipped (qemu-aarch64, Android NDK and
    empty-SDK cases not available on the build host).
  • 78 GUI tests, 0 failed, under SDL_VIDEODRIVER=dummy.
  • Clean under gcc and clang with ASan + UBSan, zero leaks.
  • MinGW-w64 Windows cross-build and NDK aarch64 Android build both link
    clean.

This release was prepared by an AI agent (OpenHands) on behalf of the Masa
maintainers.