From f153a48d7ef1f0bddf6c6cc60d0f33b992206b04 Mon Sep 17 00:00:00 2001 From: Julian Noble Date: Mon, 27 Jul 2026 16:01:21 +1000 Subject: [PATCH] G-126 pre-activation baseline recorded: upstream punkzip 0.15.2 green checkpoint Upstream c:/repo/jn/zig/punkzip commits e9b5b553 (0.15.2 migration completed, zig build test 122/122 green - bitstream wiring fixed, CLI suite compiling and pinning current output) and 78453fc0 (localtime banner restored dependency-free on stderr; zeit stays out per user decision). Context refreshed; Notes record the decisions, the stdout/stderr contract, and the known upstream gaps (base_offset untested zig-side, build subcommand scaffolding, 0.16 argsAlloc). Non-contract detail-file updates only; status stays proposed - activation flip awaits user confirmation. goals_lint clean. Assisted-by: harness=claude; primary-model=claude-fable-5; api-location=anthropic.com --- goals/G-126-punkzip-accelerator.md | 35 +++++++++++++++++++++++++----- 1 file changed, 30 insertions(+), 5 deletions(-) diff --git a/goals/G-126-punkzip-accelerator.md b/goals/G-126-punkzip-accelerator.md index 5ed3c0f0..459e958d 100644 --- a/goals/G-126-punkzip-accelerator.md +++ b/goals/G-126-punkzip-accelerator.md @@ -49,11 +49,11 @@ Toolchain is on hand: `bin/tools/` already carries unpacked zig 0.16.0 alongside 0.15.2 and 0.14.1 (`bin/tools/zig` is currently 0.15.2), with `bin/punk-getzig.cmd` for per-version fetch. -Upstream state at drafting: the 0.15.2 migration is IN PROGRESS and uncommitted -(`build.zig`, `build.zig.zon`, `src/punkzip.zig`, `src/punkzip_test.zig`, -`src/zipper.zig` modified; `AGENTS.md`, `ZIG_IO.md`, `ZIG_ARRAYLIST.md`, -`refactor_2026-01-19.txt` untracked). Vendoring must take a deliberate, recorded upstream -state rather than a working tree. +Upstream state: the drafting-time 0.15.2 migration (then in progress and uncommitted) was +completed, made fully green and committed 2026-07-27 as upstream e9b5b553, with the +localtime banner restored dependency-free in 78453fc0 - see Notes for the pre-activation +baseline record. Vendoring must take a deliberate, recorded upstream state rather than a +working tree; one now exists. ## Approach @@ -138,3 +138,28 @@ state rather than a working tree. `build` subcommand using `zipper.add_pathinfo_items`. Compression methods store, shrink, reduce, implode, deflate - the legacy methods are implemented in-tree, so it reads archives zlib-based readers cannot. +- Pre-activation upstream baseline (user-directed, 2026-07-27): the maintained checkout + `c:/repo/jn/zig/punkzip` now carries commit e9b5b553 "zig 0.15.2 migration complete: + build + test green (122/122)" and 78453fc0 "restore localtime diagnostic banner, + dependency-free, on stderr". `zig build test` under the pinned 0.15.2 toolchain runs + all ten test modules - 122/122 tests green on Windows, including the previously + mis-wired `bitstream_test.zig` (its 4 tests had never run anywhere: build.zig pointed + test_bitstream at bits_test.zig) and the 13 exact-stdout CLI tests, whose expected + outputs now PIN the current human table listing and creating:/extracting: wording. + Port-order decision per Approach: UPSTREAM-FIRST, adopted in practice - port and + stabilise upstream, then vendor the ported state. +- zeit decision (user, 2026-07-27): the zeit timezone dependency stays out - the + localtime diagnostic returns dependency-free instead (Windows kernel32 + GetLocalTime/GetTimeZoneInformation with numeric offset + zone name; honest UTC line + elsewhere), emitted on STDERR. Contract worth keeping: stdout is the parseable + product, diagnostics go to stderr - the machine-readable listing mode this goal adds + must preserve that split. Fallback if real tz fidelity is ever wanted: zeit v0.9.0 is + zig-0.16-compatible, MIT, zero transitive deps - vendor it as a path dep (never a + build-time URL fetch, which conflicts with this goal's no-network-build premise). +- Known upstream gaps carried into the goal work: the catenated/prefixed-zip + `base_offset` read path (`src/zip.zig`) - the fork's raison d'etre - has NO direct + zig-side test; add coverage alongside the machine-listing pin (the parity suite covers + it from the Tcl side only). The undocumented `build` subcommand remains unfinished + scaffolding (wrong arg indexing, writes only an EOCD; its finalize call was restored at + the checkpoint) - finish or remove it during the port. 0.16 first surfaced error + re-confirmed 2026-07-27: `std.process.argsAlloc` removed.