This repository was archived by the owner on Nov 22, 2026. It is now read-only.
Repository navigation
mojo-msgpack v0.1.0
mojo-msgpack v0.1.0
Released: 2026-11-04 · Commit: 0ab9971 · Previous: first release
What it does
MessagePack for Mojo 1.2: an Encoder byte-identical to Python msgpack.packb(use_bin_type=True), and
parse(data) into a flat preorder node table (Doc) that raises on any malformed input.
Highlights
- Encode 5 to 6 ms vs Python msgpack (C ext) 33 to 34 ms on 100,000 records (4.86 MB); decode x5 110 to 119 ms vs 308 to 320 ms; peak RSS 81 MB vs 139 MB.
- Every malformed input raises with the byte named: truncation, overrunning lengths (nothing allocated), invalid UTF-8,
0xc1, trailing bytes, nesting past 1024.
Changes
First release, no earlier version.
Verified
| Check | Result |
|---|---|
scripts/ci.sh (check.sh): encode of 2503 trees and decode of 9475 byte strings identical to tools/oracle.py, API errors, doc examples |
PASS all |
scripts/selfcheck.sh: 6 mutants (boundary, depth, UTF-8, trailing bytes, timestamp form, length) |
PASS selfcheck |
Known limits
- Not covered by the oracle: extension codes below -1 (one checked in
tests/api.mojo) and lengths above 2^32-1 on encode. - Mojo 1.2 only.
Upgrade / run
mojo run -I src app.mojo
Commits
0ab9971ci: badge row and checks badge1270d63docs(skills): add mojo-msgpack skill431ddf3test: property smoke step, encode then parse round trip70bfb3cbuild: conda recipe9e7a7cddocs: one example, one install blockff4a62adocs: install and quickstart block6c48077docs: api, design and perf pages with a compiled doc example40a953fdocs: README, changelog, packaging and CI6b6b22atest: oracle gate, mutant selfcheck and bench against Python msgpack3fad432feat: MessagePack encoder and zero-copy parser in pure Mojo