Failure
Main CI run https://github.com/zig-utils/zig-js/actions/runs/29460140328 failed only unit (shard 1/4) after all 192 selected tests completed: 190 passed, 2 expected skips, 0 failed, but the shard reported one leak.
The exact witness is Context heap_limit_bytes object side-store pressure fails closed. The newer CI Zig/shard allocation layout exhausts the heap while Object.ensureKeyOrderUnlocked is seeding an unpublished key-order list. Every already-duplicated shape key leaks because the error path neither frees the partial list nor destroys its list header. The local full suite passed because its older Zig/allocation layout reached OOM at a different allocation point.
Scope / acceptance
- Build key-order lists transactionally: free every duplicated key, list allocation, and newly activated backing flag when initialization fails before publication.
- Make owned-key append free the just-duplicated key if list growth fails; use the same helper in initialization, incremental record, and replacement paths.
- Add deterministic all-allocation-failures coverage rather than depending on a particular heap-limit/Zig allocation layout.
- Preserve property/accessor creation order, GC backing-store accounting, heap-limit failure behavior, and exact teardown.
- Pass the focused OOM/key-order test, the existing heap-limit witness, and the next batched CI run.