Repository navigation
ZIPP v0.0.39
ZIPP 0.0.39
A bugfix and performance release fixing Python raw stdout/stderr streaming and 64 KiB truncation in both the native CLI (#108) and the embedded WASM API (#109), eliminating quadratic string slicing/searching hotspots in the Python runtime (html.parser, html2text, markdownify), completing textwrap keyword support, and delivering further steady-state DOM and regex throughput gains in the JavaScript engine.
Thank you to @codeandsolder for reporting issues #108 and #109 and sharing detailed v0.0.38 verification results and cross-CPU benchmarks on #99, #100, and #101 — your follow-up reports pinpointed both the CLI and embedded WASM stdout truncation bugs as well as the next wave of Python and JS optimization opportunities.
New in 0.0.39
- Python stdout/stderr past 64 KiB in both the native CLI (#108) and embedded WASM (#109):
- Adds a dedicated raw streaming output sink (
ScriptState::set_raw_output_sink) and native__zipp_py_writebridge sozipp py(file, directory, and stdin-) preserves exact UTF-8 and binary bytes with no spurious trailing newline (print("hello", end=""),sys.stdout.write("hello")) and streams arbitrarily long output past 64 KiB withoutinspect_line's"..."truncation. - Routes non-streaming / embedded WASM Python hosts (
Engine.initPythonProject+Engine.takeConsole) through__zipp_py_writeop1, bypassinginspect_line's 64 KiB truncation so largestdout/stderrpayloads (e.g. 70,000+ characters) crosstakeConsole()intact up to the 8 MiBMAX_LIFETIME_OUTPUT_BYTESsandbox budget, and fail explicitly withRangeError: script exceeded its output budgetif exceeded rather than silently dropping bytes. - Adds
sys.stdout.buffer/sys.stderr.buffer(write,flush),writelines,flush=True,sys.stdout = None, andsys.stdoutredirection support.
- Adds a dedicated raw streaming output sink (
- Python HTML parsing, string,
re, truthiness, andtextwrapthroughput (#100 follow-up):- Eliminates O(N²)
codepoints(s)splitting in Python string slicing (s[i:j]), boundedstr.find/rfind/index/rindex/count, and boundedstr.startswith/endswith, sharing an O(log K) surrogate-pair cache acrossstrandreso both ASCII and astral-containing strings scale linearly. - Adds native ASCII step-1 slicing in
PyStrItem, native boundedPY_STRMfast paths forfind/rfind/count/startswith/endswith, per-classR.truthcaching, broaderPyMethodgbcaching for dict-less builtin classes, and dict-lessre.Pattern/re.Matchobjects with directc1–c4fast paths. - Cuts a 75 KiB
html.parserparse from10.1 sto66.9 ms(~151× faster), cutsPyMethodmisses inmarkdownify+ BeautifulSoup4 by 81.5%, and fixestextwrap.wrap/fill/TextWrapperkeyword options (break_long_words,subsequent_indent, etc.) so unmodifiedhtml2textworks out of the box with its defaultbody_width=78and matches CPython byte-for-byte even past 64 KiB.
- Eliminates O(N²)
- JavaScript
%RegExp.prototype%fast-slot cache and planned object pooling (#101 follow-up):- Registers
@@split(REGEXP_SYM_SPLIT) inREGEXP_PROTOCOL_PROTO_SLOTS, fixing a missed cache fill that previously prevented%RegExp.prototype%fast-slot caching from activating on regexreplace/split/match/flagscalls. - Adds pooled, slab-backed
Heap::alloc_planned_objectforNewPlannedObject(JIT and interpreter) and empty-map guards injit_make_closure, reducing steady-state profiler samples by ~12.4% on Defuddle and ~9.0% on WebforAI (with 55–72% less GC courier traffic) while keeping outputs byte-identical to Node.
- Registers
Downloads
| File | What it is |
|---|---|
zipp-0.0.39-windows-x86_64-portable.exe |
The Windows command line; run it from anywhere. |
zipp-0.0.39-windows-x86_64-installer.msi |
The same binary, installed for the current user into %LOCALAPPDATA%\Programs\ZIPP and added to PATH; no administrator rights. Uninstall from Settings > Apps. |
zipp-0.0.39-linux-x86_64 |
The Linux command line, x86-64 (glibc 2.35 or later). chmod +x it after downloading. |
zipp-0.0.39-linux-arm64 |
The same for 64-bit Arm. |
zipp-0.0.39-linux-armv7 |
The same for 32-bit Arm (hard float); interpreter only, and WebAssembly on wasmi. |
zipp-0.0.39-javascript.wasm |
The JavaScript engine for browsers, Node, Deno and Bun. |
zipp-0.0.39-javascript-typescript.wasm |
The same with TypeScript and TSX. |
zipp-0.0.39-javascript-lite.wasm |
The JavaScript core without Intl and Temporal, built for size. |
zipp-0.0.39-javascript-python.wasm |
JavaScript and Python, torch built in. |
zipp-0.0.39-javascript-python-base.wasm |
JavaScript and Python without torch. |
zipp-0.0.39-javascript-php.wasm |
JavaScript and PHP 8.x, with PhpApp SAPI and SQL bridge support. |
zipp-0.0.39-javascript-rust.wasm |
JavaScript and Rust, with Axum/SQLx worker-boot support. |
zipp-0.0.39-torch-package.wasm |
The torch package for the -python-base engine. |
zipp-0.0.39-<engine>.wasm.br |
Each WebAssembly module compressed with Brotli (quality 11), about a quarter of its size. Serve it with Content-Encoding: br and Content-Type: application/wasm, or let zipp.mjs load it; the plain .wasm is the default. |
zipp-0.0.39-wasm-embed-kit.zip |
zipp.mjs (the loader and sandbox, version 1.5.0) and its types, the host SDK (1.4.0), the engine's TypeScript declarations, the browser GPU adapter, docs and examples. |
SHA256SUMS |
Checksums of every file. |
Verification
- All release binaries, WebAssembly variants, and the embed kit are built and verified from the tagged commit in release.yml and release-build.yml.
- Every WebAssembly engine module retains the audited 51-function host import surface (plus
zippTorchKernelon Python builds) and the 1 GiB linear memory cap.
Full Changelog: v0.0.38...v0.0.39