Browse Source

G-117 achieved: flip, archive, reference sweep; reopened pin; G-118 items 1+7 verified

Acceptance evidence in the archived detail file: embed verified in all three
family members (family_check), sidecar derived from embed with identical
build_id, 'info' identifies sidecar-paired/renamed-stray/pre-v1 files without
execution and flags doctored-sidecar disagreements, punkbin AGENTS.md schema
docs, roundtrip pin green, record survives make.tcl kit wrapping (punk9_beta
reads its runtime's r2 record in-kit), r2 re-emitted with full v1 records.
Sweep: achieved markers in G-025/G-057/G-108/G-116/G-118/G-119 (G-025's
survival expectation updated to confirmed). tclshcmd.test pins
::tclsh(reopened) publication on the rebuilt patched kits (G-118 items 1+7
landed+verified; Progress updated). build905.zig: packager git-identity leg
judges success by output not out_code (resolved 'unrecorded' on this host -
effective at next emission).

Assisted-by: harness=claude; primary-model=claude-fable-5; api-location=anthropic.com
master
Julian Noble 6 days ago
parent
commit
a015ada542
  1. 4
      GOALS-archive.md
  2. 4
      GOALS.md
  3. 10
      goals/G-025-exe-selfreport.md
  4. 2
      goals/G-057-kit-icon-embedding.md
  5. 2
      goals/G-108-buildsuite-debug-tier.md
  6. 3
      goals/G-116-suite-built-tcltls.md
  7. 5
      goals/G-118-tclsh-subcommand-review.md
  8. 3
      goals/G-119-runtime-active-freshness.md
  9. 33
      goals/archive/G-117-self-describing-runtimes.md
  10. 6
      src/buildsuites/suite_tcl90/build905.zig
  11. 8
      src/tests/shell/testsuites/punkexe/tclshcmd.test

4
GOALS-archive.md

@ -152,3 +152,7 @@ Acceptance: on a twapi-less suite runtime, raw enable/disable work via the fallb
### G-103 [achieved 2026-07-22] runtime kit family from buildsuites: plain / punk / bi kits with attached batteries + artifact metadata → detail: goals/archive/G-103-runtime-kit-family.md ### G-103 [achieved 2026-07-22] runtime kit family from buildsuites: plain / punk / bi kits with attached batteries + artifact metadata → detail: goals/archive/G-103-runtime-kit-family.md
Scope: src/buildsuites/suite_tcl90/ (kit assembly steps in recipe/driver; pattern for later suites), src/vfs/_config + src/runtime/mapvfs.config (as consumers of the new runtime names), punkbin repo layout + metadata (c:/repo/jn/punkbin; compatible repos), src/scriptapps runtime scriptset (punk-runtime list/use - renamed under G-097, achieved 2026-07-21) Scope: src/buildsuites/suite_tcl90/ (kit assembly steps in recipe/driver; pattern for later suites), src/vfs/_config + src/runtime/mapvfs.config (as consumers of the new runtime names), punkbin repo layout + metadata (c:/repo/jn/punkbin; compatible repos), src/scriptapps runtime scriptset (punk-runtime list/use - renamed under G-097, achieved 2026-07-21)
Acceptance: suite_tcl90 produces named artifacts for at least plain, punk, and one bi (+Tk) kit; each verified self-contained from a path with no external Tcl visible (info library resolves into the attached zip; package require checks for Thread, vfs + representative vfs::* packages, tcllib module + tcllibc acceleration engaged; bi adds Tk create/destroy) with the checks recorded here; the punk kit demonstrates piperepl active by default and disabled via the documented env opt-out, the plain kit demonstrates stock behaviour (no patch); artifact metadata (variant, versions, target, source provenance) is emitted alongside the binaries in the punkbin layout and surfaced by the runtime scriptset's list/use; the naming scheme for family members is documented, with piperepl-patched runtime executables carrying 'punk' in the name to distinguish them from unpatched (e.g tclsh905punk.exe - the tcl-patchlevel / punk-version / separator questions resolved and the decision recorded here) and mapvfs.config consuming the punk/bi runtimes under the decided names; the 8.6 family variant is explicitly deferred to the G-101 container investigation (static vfs / metakit patching questions). Acceptance: suite_tcl90 produces named artifacts for at least plain, punk, and one bi (+Tk) kit; each verified self-contained from a path with no external Tcl visible (info library resolves into the attached zip; package require checks for Thread, vfs + representative vfs::* packages, tcllib module + tcllibc acceleration engaged; bi adds Tk create/destroy) with the checks recorded here; the punk kit demonstrates piperepl active by default and disabled via the documented env opt-out, the plain kit demonstrates stock behaviour (no patch); artifact metadata (variant, versions, target, source provenance) is emitted alongside the binaries in the punkbin layout and surfaced by the runtime scriptset's list/use; the naming scheme for family members is documented, with piperepl-patched runtime executables carrying 'punk' in the name to distinguish them from unpatched (e.g tclsh905punk.exe - the tcl-patchlevel / punk-version / separator questions resolved and the decision recorded here) and mapvfs.config consuming the punk/bi runtimes under the decided names; the 8.6 family variant is explicitly deferred to the G-101 container investigation (static vfs / metakit patching questions).
### G-117 [achieved 2026-07-24] Self-describing family runtimes: embedded artifact record + metadata schema v1 → detail: goals/archive/G-117-self-describing-runtimes.md
Scope: src/buildsuites/suite_tcl90/ (kit-family staging embeds the record; family_artifacts.tcl schema v1 fields + emission ordering; -Doriginurl/-Dpackager options), tools/family_check.tcl (embedded-record verification), src/scriptapps/bin/punk-runtime.* + bin/punk-runtime.cmd via rewrap ('info' action; schema-tolerant parsing), punkbin AGENTS.md (record relationship + schema/field documentation)
Acceptance: kit-family embeds the record in all three members with the embed-then-hash ordering documented; family_check verifies the embedded record exists and matches probed facts; 'punk-runtime info' identifies fetched-with-sidecar and bare-renamed copies via a non-executing zip central-directory read (cooperative probe documented as fallback) and flags embedded-vs-sidecar disagreement; v1 fields documented in punkbin AGENTS.md; build_id identical embedded+sidecar; '#' field comments emitted; parsing tolerates unknown fields/absent schema (pre-v1 r1 keeps working); both payloads in parity with the roundtrip pin green; r2 re-emitted carrying the full v1 record (r1 immutable as published).

4
GOALS.md

@ -391,10 +391,6 @@ Detail: goals/G-115-declarative-vfs-composition.md
Scope: src/buildsuites/suite_tcl90/ (build_tcltls module + crypto-backend build, sources.config + build.zig.zon source records, kit-family bi payload + metadata extension, test_gate record step), src/vfs kit payloads carrying vendored tcltls binaries (current-state reference + recorded disposition only - removal stays G-004-era work), punkbin (as eventual artifact destination via the G-067 library class); consumers punk::imap4 / punk::netbox (package require tls) as verification context Scope: src/buildsuites/suite_tcl90/ (build_tcltls module + crypto-backend build, sources.config + build.zig.zon source records, kit-family bi payload + metadata extension, test_gate record step), src/vfs kit payloads carrying vendored tcltls binaries (current-state reference + recorded disposition only - removal stays G-004-era work), punkbin (as eventual artifact destination via the G-067 library class); consumers punk::imap4 / punk::netbox (package require tls) as verification context
Detail: goals/G-116-suite-built-tcltls.md Detail: goals/G-116-suite-built-tcltls.md
### G-117 [active] Self-describing family runtimes: embedded artifact record + metadata schema v1
Scope: src/buildsuites/suite_tcl90/ (kit-family staging embeds the record; family_artifacts.tcl schema v1 fields + emission ordering; -Doriginurl/-Dpackager options), tools/family_check.tcl (embedded-record verification), src/scriptapps/bin/punk-runtime.* + bin/punk-runtime.cmd via rewrap ('info' action; schema-tolerant parsing), punkbin AGENTS.md (record relationship + schema/field documentation)
Detail: goals/G-117-self-describing-runtimes.md
### G-118 [active] tclsh subcommand review: stock-parity gaps, piperepl residue, docs and console-path tests ### G-118 [active] tclsh subcommand review: stock-parity gaps, piperepl residue, docs and console-path tests
Scope: src/vfs/_config/punk_main.tcl (tclsh dispatch), src/vfs/_config/project_main.tcl (parity), src/buildsuites/suite_tcl90/patches/ (tclMain piperepl rev items), src/tests/shell/testsuites/punkexe/tclshcmd.test (coverage additions) Scope: src/vfs/_config/punk_main.tcl (tclsh dispatch), src/vfs/_config/project_main.tcl (parity), src/buildsuites/suite_tcl90/patches/ (tclMain piperepl rev items), src/tests/shell/testsuites/punkexe/tclshcmd.test (coverage additions)
Detail: goals/G-118-tclsh-subcommand-review.md Detail: goals/G-118-tclsh-subcommand-review.md

10
goals/G-025-exe-selfreport.md

@ -91,10 +91,12 @@ Edge cases driving the acceptance clauses:
dev paths) would make that mixing observable instead of silent. dev paths) would make that mixing observable instead of silent.
(G-030 achieved 2026-07-14 - goals/archive/G-030-maketcl-punkargs.md) (G-030 achieved 2026-07-14 - goals/archive/G-030-maketcl-punkargs.md)
- Archived-goal references in this file: G-007 achieved 2026-07-05 (goals/archive/G-007-console-location-transparency.md);G-015 achieved 2026-07-07 (goals/archive/G-015-script-subcommand-piped-stdin.md). - Archived-goal references in this file: G-007 achieved 2026-07-05 (goals/archive/G-007-console-location-transparency.md);G-015 achieved 2026-07-07 (goals/archive/G-015-script-subcommand-piped-stdin.md).
- G-117 relationship (recorded 2026-07-24 after overlap review): G-117 (active) embeds - G-117 relationship (recorded 2026-07-24; G-117 achieved 2026-07-24 - see
the RUNTIME-layer artifact metadata record (schema v1, build_id) inside family goals/archive/G-117-self-describing-runtimes.md): G-117 embeds the RUNTIME-layer
runtimes' attached images; make.tcl's kit wrap is expected to carry that record into artifact metadata record (schema v1, build_id) inside family runtimes' attached
wrapped kits. This goal's report should read BOTH layers (kit stamp + inherited images at /app/punkbin-artifact.toml, and the record is CONFIRMED to survive
make.tcl kit wrapping (punk9_beta reads its runtime's r2 record in-kit).
This goal's report should read BOTH layers (kit stamp + inherited
runtime record), and the "input runtime binary name" stamp field should cite the runtime record), and the "input runtime binary name" stamp field should cite the
embedded record's build_id/artifact name when present - exact immutable -r<N> embedded record's build_id/artifact name when present - exact immutable -r<N>
linkage instead of the mutable working name. Coordinate stamp-file naming with linkage instead of the mutable working name. Coordinate stamp-file naming with

2
goals/G-057-kit-icon-embedding.md

@ -80,7 +80,7 @@ delete-then-write). Requirements sketch agreed 2026-07-10:
- G-028 relationship: a locked kit exe blocks the resource update exactly as it - G-028 relationship: a locked kit exe blocks the resource update exactly as it
blocks deploy - G-028's locker-report helper should name the holder on blocks deploy - G-028's locker-report helper should name the holder on
icon-step failure too. icon-step failure too.
- G-025/G-117 note: the parked RT_VERSION follow-on above stamps - G-025/G-117 note (G-117 achieved 2026-07-24 - see goals/archive/G-117-self-describing-runtimes.md): the parked RT_VERSION follow-on above stamps
version/copyright resources from punkproject.toml - when it is drafted as a version/copyright resources from punkproject.toml - when it is drafted as a
goal, reconcile with G-025's kit stamp and G-117's embedded artifact record goal, reconcile with G-025's kit stamp and G-117's embedded artifact record
so the three provenance surfaces tell one story. so the three provenance surfaces tell one story.

2
goals/G-108-buildsuite-debug-tier.md

@ -78,7 +78,7 @@ TCL_COMPILE_STATS similarly must be absent (not =0) for release performance.
- G-105 relationship (recorded 2026-07-24 after overlap review): debug members - G-105 relationship (recorded 2026-07-24 after overlap review): debug members
join the family x target matrix - the -dbg<n> tier suffix composes with join the family x target matrix - the -dbg<n> tier suffix composes with
-target as a dimension sibling, not a separate suite tree. -target as a dimension sibling, not a separate suite tree.
- G-117 relationship: debug-tier artifacts carry the same schema v1 record; the - G-117 relationship (achieved 2026-07-24 - see goals/archive/G-117-self-describing-runtimes.md): debug-tier artifacts carry the same schema v1 record; the
-dbg<n> tier distinction belongs to the artifact-name/variant fields -dbg<n> tier distinction belongs to the artifact-name/variant fields
family_check already probes, not new schema. family_check already probes, not new schema.
- G-116 relationship: its static crypto + tls battery enlarges the - G-116 relationship: its static crypto + tls battery enlarges the

3
goals/G-116-suite-built-tcltls.md

@ -44,7 +44,8 @@ extends).
## Notes ## Notes
- G-117 relationship (recorded 2026-07-24 after overlap review; neither file - G-117 relationship (G-117 achieved 2026-07-24 - see
goals/archive/G-117-self-describing-runtimes.md; recorded 2026-07-24 after overlap review; neither file
previously referenced the other): this goal's Acceptance extends the artifact previously referenced the other): this goal's Acceptance extends the artifact
metadata (tls version + backend name/version) - those fields ride G-117's metadata (tls version + backend name/version) - those fields ride G-117's
schema v1 as the extension point, not a parallel record. schema v1 as the extension point, not a parallel record.

5
goals/G-118-tclsh-subcommand-review.md

@ -15,7 +15,7 @@ The subcommand is an extension of standard tclsh behaviour, not an exact emulato
## Issue list ## Issue list
All 11 items dispositioned by the user 2026-07-24 (activation session). Items 1 and 7 need a tclMain piperepl patch rev + suite rebuild and are batched with the G-117 cycle (item 2 stays document-only, no patch change). All 11 items dispositioned by the user 2026-07-24 (activation session). Items 1 and 7 shipped via the tclMain piperepl patch rev in the G-117 cycle (G-117 achieved 2026-07-24 - see goals/archive/G-117-self-describing-runtimes.md); item 2 stays document-only, no patch change.
1. Reopen message noise: on the eof-with-dorepl console-reopen path the patch unconditionally prints "? reopen stdin from console" to STDOUT (tclMain_piperepl_905.c). Options: drop / move to stderr / env-gate (e.g TCLSH_PIPEREPL_DEBUG). Decision 2026-07-24: FIX - drop the message (stock tclsh prints nothing entering a repl); add a TCLSH_PIPEREPL_DEBUG=1 env gate re-enabling patch diagnostics. Patch rev, batched with the G-117 cycle. 1. Reopen message noise: on the eof-with-dorepl console-reopen path the patch unconditionally prints "? reopen stdin from console" to STDOUT (tclMain_piperepl_905.c). Options: drop / move to stderr / env-gate (e.g TCLSH_PIPEREPL_DEBUG). Decision 2026-07-24: FIX - drop the message (stock tclsh prints nothing entering a repl); add a TCLSH_PIPEREPL_DEBUG=1 env gate re-enabling patch diagnostics. Patch rev, batched with the G-117 cycle.
2. tcl_interactive read divergence (gate open): a script-arg launch from a CONSOLE reads ::tcl_interactive as 1 where stock tclsh reads 0, because the patch links it to the tty flag before the startup script (the early link is load-bearing - it is how a piped script that sets dorepl opts into prompts/echo). Options: accept + document (current state, recorded in patches/README.md) / patch rev that preserves stock read semantics for script-arg launches while keeping the write lever. Decision 2026-07-24: ACCEPT + DOCUMENT - patches/README.md wording stands; no patch change; console dorepl sessions keep their automatic prompts. 2. tcl_interactive read divergence (gate open): a script-arg launch from a CONSOLE reads ::tcl_interactive as 1 where stock tclsh reads 0, because the patch links it to the tty flag before the startup script (the early link is load-bearing - it is how a piped script that sets dorepl opts into prompts/echo). Options: accept + document (current state, recorded in patches/README.md) / patch rev that preserves stock read semantics for script-arg launches while keeping the write lever. Decision 2026-07-24: ACCEPT + DOCUMENT - patches/README.md wording stands; no patch change; console dorepl sessions keep their automatic prompts.
@ -42,4 +42,5 @@ All 11 items dispositioned by the user 2026-07-24 (activation session). Items 1
- 2026-07-24: all 11 items dispositioned (Decision lines inline above); goal activated alongside G-117. - 2026-07-24: all 11 items dispositioned (Decision lines inline above); goal activated alongside G-117.
- 2026-07-24 items 3/4/5/9 LANDED (punkproject 0.20.0): no-script forms set ::argv0 to [info nameofexecutable] (both repl and piped-eval paths); missing script file pre-checked with clean not-found + exit 1; machinery-absent console stdin fails fast via the app-punkscript terminal probe (piped degraded eval unchanged; patch-missing notice reworded to "note:", deliberate TCLSH_PIPEREPL=0 opt-out now quiet, old debug lines deleted); project_main.tcl carries the full mirrored dispatch (script-arg/dash/-encoding/lib: forms - previously single-arg-only with stale gate default) and both layout _config copies byte-synced. Verified: all mapvfs kits rebuilt; tclshcmd.test extended to 19 (tclsh_noscript_argv0, tclsh_script_notfound); shell/*** suite 64 pass / 2 goal-gated skips / 0 fail. - 2026-07-24 items 3/4/5/9 LANDED (punkproject 0.20.0): no-script forms set ::argv0 to [info nameofexecutable] (both repl and piped-eval paths); missing script file pre-checked with clean not-found + exit 1; machinery-absent console stdin fails fast via the app-punkscript terminal probe (piped degraded eval unchanged; patch-missing notice reworded to "note:", deliberate TCLSH_PIPEREPL=0 opt-out now quiet, old debug lines deleted); project_main.tcl carries the full mirrored dispatch (script-arg/dash/-encoding/lib: forms - previously single-arg-only with stale gate default) and both layout _config copies byte-synced. Verified: all mapvfs kits rebuilt; tclshcmd.test extended to 19 (tclsh_noscript_argv0, tclsh_script_notfound); shell/*** suite 64 pass / 2 goal-gated skips / 0 fail.
- 2026-07-24 overlap reconciliation (user-prompted review): cross-references recorded with G-025 (kit-layer stamp counterpart - see G-117 Notes for the record-survives-kit-wrap + filename-namespacing considerations), G-032 (item 10 refined: docs authored as G-032-compatible punk::args definitions), G-031 (item 9 duplication interim), G-077 (tclsh -e boundary note). - 2026-07-24 overlap reconciliation (user-prompted review): cross-references recorded with G-025 (kit-layer stamp counterpart - see G-117 Notes for the record-survives-kit-wrap + filename-namespacing considerations), G-032 (item 10 refined: docs authored as G-032-compatible punk::args definitions), G-031 (item 9 duplication interim), G-077 (tclsh -e boundary note).
- Remaining for acceptance: patch-rev items (1, 7) via the G-117 suite rebuild cycle; item 10 definitions (G-032-compatible) also carrying the documented-as-intended records (items 2, 6, 8) and the G-077 boundary; console-driven test (item 11); ARCHITECTURE.md tclsh-subcommand bullet rides the item-10 docs change-set. - 2026-07-24 items 1 + 7 LANDED and verified (G-117 cycle suite rebuild): reopen notice now TCLSH_PIPEREPL_DEBUG-gated with all reopen-path messages on stderr; ::tclsh(reopened) published (family_check gate probe asserts 0 at gate-open start / absent on plain+opt-out on all three family members; tclshcmd.test tclsh_pr_noarg_machinery pins it against the rebuilt punk9_beta). The console-reopen FLIP to 1 and the notice's console-side silence remain item-11 console-harness verification.
- Remaining for acceptance: item 10 definitions (G-032-compatible) also carrying the documented-as-intended records (items 2, 6, 8) and the G-077 boundary; console-driven test (item 11); ARCHITECTURE.md tclsh-subcommand bullet rides the item-10 docs change-set.

3
goals/G-119-runtime-active-freshness.md

@ -11,7 +11,8 @@ Gap reported by the user 2026-07-24: 'use tclsh9.0.5-punk-r2.exe' + no-name
fetch against a server default of r1 produces "No download required" with no fetch against a server default of r1 produces "No download required" with no
indication the active working copy is a revision ahead of (or, mirrored, indication the active working copy is a revision ahead of (or, mirrored,
behind) the curated default. Verified against both payloads and the goals behind) the curated default. Verified against both payloads and the goals
tree: no existing goal covers freshness comparison - G-117 (identity/schema) tree: no existing goal covers freshness comparison - G-117 (identity/schema;
achieved 2026-07-24 - see goals/archive/G-117-self-describing-runtimes.md)
deliberately rejects lifecycle fields ("repo-level curation (defaults.txt and deliberately rejects lifecycle fields ("repo-level curation (defaults.txt and
successors), not artifact facts"), so this verdict is computed at display time successors), not artifact facts"), so this verdict is computed at display time
from repo data + local state and requires no artifact-record change. The sha1 from repo data + local state and requires no artifact-record change. The sha1

33
goals/G-117-self-describing-runtimes.md → goals/archive/G-117-self-describing-runtimes.md

@ -1,6 +1,6 @@
# G-117 Self-describing family runtimes: embedded artifact record + metadata schema v1 # G-117 Self-describing family runtimes: embedded artifact record + metadata schema v1
Status: active Status: achieved 2026-07-24
Scope: src/buildsuites/suite_tcl90/ (kit-family staging embeds the record; family_artifacts.tcl schema v1 fields + emission ordering; -Doriginurl/-Dpackager options), tools/family_check.tcl (embedded-record verification), src/scriptapps/bin/punk-runtime.* + bin/punk-runtime.cmd via rewrap ('info' action; schema-tolerant parsing), punkbin AGENTS.md (record relationship + schema/field documentation) Scope: src/buildsuites/suite_tcl90/ (kit-family staging embeds the record; family_artifacts.tcl schema v1 fields + emission ordering; -Doriginurl/-Dpackager options), tools/family_check.tcl (embedded-record verification), src/scriptapps/bin/punk-runtime.* + bin/punk-runtime.cmd via rewrap ('info' action; schema-tolerant parsing), punkbin AGENTS.md (record relationship + schema/field documentation)
Goal: every family runtime carries a copy of its artifact metadata record INSIDE the attached image (e.g /app/punkbin-artifact.toml, written at kit-family staging time - necessarily WITHOUT the final sha1, which is computed over the finished binary and lives only in the sidecar toml + sha1sums), so a runtime separated from its sidecar remains identifiable via a punk-runtime 'info' action (embedded record and sidecar shown side by side, disagreements flagged); AND the metadata record is hardened as SCHEMA v1: schema (format version), build_id (uuid stamped in embedded AND sidecar - the offline correlation key for renamed copies), origin (canonical artifact repo the artifact was built FOR - mirrors preserve it; -Doriginurl, default punkbin), packager (declared identity; -Dpackager > env > git identity > unrecorded), project/project_url, license summary, build_host_platform - so records circulating on punkbin-compatible repos from different packagers stay interpretable and attributable. Goal: every family runtime carries a copy of its artifact metadata record INSIDE the attached image (e.g /app/punkbin-artifact.toml, written at kit-family staging time - necessarily WITHOUT the final sha1, which is computed over the finished binary and lives only in the sidecar toml + sha1sums), so a runtime separated from its sidecar remains identifiable via a punk-runtime 'info' action (embedded record and sidecar shown side by side, disagreements flagged); AND the metadata record is hardened as SCHEMA v1: schema (format version), build_id (uuid stamped in embedded AND sidecar - the offline correlation key for renamed copies), origin (canonical artifact repo the artifact was built FOR - mirrors preserve it; -Doriginurl, default punkbin), packager (declared identity; -Dpackager > env > git identity > unrecorded), project/project_url, license summary, build_host_platform - so records circulating on punkbin-compatible repos from different packagers stay interpretable and attributable.
Acceptance: kit-family embeds the record in all three members with the embed-then-hash ordering documented (embedded copy carries the v1 fields but no self-sha1; the sidecar + sha1sums remain the integrity authority); family_check verifies the embedded record exists and its variant/patchlevel/battery fields MATCH the probed facts for each member; 'punk-runtime info <name>' reports identity for (a) a fetched artifact with its sidecar and (b) a bare RENAMED copy with no sidecar - the embedded-read mechanism is decided and documented in the work (zip-central-directory read of the exe-appended archive by the host payload where available vs a cooperative probe that executes the target with a generated script, execution caveat stated) - and flags embedded-vs-sidecar disagreement; the v1 field set is documented in punkbin AGENTS.md with each field's semantics (notably origin's built-for-not-published-on meaning and packager's declarative-not-verified status, with minisign sidecars noted as the verification complement); family_artifacts emits all v1 fields with build_id present and IDENTICAL in embedded and sidecar copies, and the emitted records carry brief '#' comment lines documenting the non-obvious fields (toml-spec comments, ignored by the existing line-based consumers); punk-runtime metadata parsing tolerates unknown fields and absent schema (pre-v1 r1 records keep working); both payloads in parity with the roundtrip pin green; the next family emission after this goal lands is r2 carrying the full v1 record (r1 stays immutable as published). Acceptance: kit-family embeds the record in all three members with the embed-then-hash ordering documented (embedded copy carries the v1 fields but no self-sha1; the sidecar + sha1sums remain the integrity authority); family_check verifies the embedded record exists and its variant/patchlevel/battery fields MATCH the probed facts for each member; 'punk-runtime info <name>' reports identity for (a) a fetched artifact with its sidecar and (b) a bare RENAMED copy with no sidecar - the embedded-read mechanism is decided and documented in the work (zip-central-directory read of the exe-appended archive by the host payload where available vs a cooperative probe that executes the target with a generated script, execution caveat stated) - and flags embedded-vs-sidecar disagreement; the v1 field set is documented in punkbin AGENTS.md with each field's semantics (notably origin's built-for-not-published-on meaning and packager's declarative-not-verified status, with minisign sidecars noted as the verification complement); family_artifacts emits all v1 fields with build_id present and IDENTICAL in embedded and sidecar copies, and the emitted records carry brief '#' comment lines documenting the non-obvious fields (toml-spec comments, ignored by the existing line-based consumers); punk-runtime metadata parsing tolerates unknown fields and absent schema (pre-v1 r1 records keep working); both payloads in parity with the roundtrip pin green; the next family emission after this goal lands is r2 carrying the full v1 record (r1 stays immutable as published).
@ -118,12 +118,31 @@ hosts without a zip reader.
and its gate probe verifies the G-118 patch rev (::tclsh(reopened) published 0 and its gate probe verifies the G-118 patch rev (::tclsh(reopened) published 0
gate-open, absent plain/opt-out). v1 r2 artifacts emitted with sha1sums to gate-open, absent plain/opt-out). v1 r2 artifacts emitted with sha1sums to
out/family/punkbin/win32-x86_64 (build_ids embedded==sidecar by construction). out/family/punkbin/win32-x86_64 (build_ids embedded==sidecar by construction).
- Remaining for acceptance: punk-runtime 'info' action (ps1 + bash + cmd rewrap; - 2026-07-24 ACCEPTANCE MET (flip evidence): punk-runtime 'info' landed in both
zip central-directory read, cooperative-probe fallback documented; embedded-vs- payloads + rewrapped bin/punk-runtime.cmd (roundtrip pin green 9 pass/0 fail).
sidecar disagreement flags; schema-tolerant parsing incl pre-v1 r1), punkbin Read mechanism as decided: NO execution of the target - bash via unzip's
AGENTS.md schema v1 field docs, roundtrip pin green, bin/runtime refresh + wrap central-directory read, ps1 via .NET System.IO.Compression with a manual EOCD
trial (record-survives-kit-wrap verification), then user-gated r2 publication + scan + prepended-exe offset fixup (.NET lacks the self-extractor fixup; the
defaults flip. pure-zip tail is rebased to a temp file); the cooperative probe (piping a reader
into the EXECUTED target) is printed as the fallback for zip-reader-less hosts
with the execution caveat stated. Verified on the emitted v1 r2 artifacts:
sidecar-agree report, renamed-stray copy fully identified embedded-only, pre-v1
artifact reports sidecar-only (schema-tolerant), and a doctored sidecar produces
'!DISAGREE embedded-vs-sidecar on: variant build_id' plus sha1 mismatch flagging.
punkbin AGENTS.md carries the schema v1 field documentation (origin built-for
semantics, packager declarative + minisign complement, build_id derivation,
G-116 extension point). Wrap trial: bin/runtime/win32-x86_64 store refreshed
from the emission (r2 artifacts + materialized working copies), all mapvfs kits
rebuilt - the embedded record SURVIVES make.tcl kit wrapping (punk9_beta reads
//zipfs:/app/punkbin-artifact.toml: schema 1, tclsh9.0.5-punk-r2.exe, variant
punk), closing the kit->-rN traceability gap in-kit; shell suite 64 pass/0 fail
incl the new ::tclsh(reopened) publication pin. Verified on: family kits
tclsh9.0.5[-punk[-bi]] r2, wrapped kits punk9_beta/punk9bi_beta + the mapvfs
set, native tclsh90 runner, Windows PowerShell 5 + pwsh for the ps1 payload.
Remaining manual items (post-goal sequencing, user-gated per activation): punkbin
r2 publication + defaults.txt flip (then G-119 fixture-server verdict tests);
packager git-identity leg resolved "unrecorded" on this host during the suite
run (option/env legs work) - cosmetic, revisit with the next emission.
family_artifacts v1 fields + mount-read derivation + '#' field comments + family_artifacts v1 fields + mount-read derivation + '#' field comments +
-Doriginurl/-Dpackager plumbing, family_check embedded-record verification, -Doriginurl/-Dpackager plumbing, family_check embedded-record verification,
punk-runtime 'info' action (ps1 + bash + cmd rewrap; zip central-directory read, punk-runtime 'info' action (ps1 + bash + cmd rewrap; zip central-directory read,

6
src/buildsuites/suite_tcl90/build905.zig

@ -2385,13 +2385,15 @@ pub fn build(b: *std.Build) !void {
if (b.graph.environ_map.get("PUNKBIN_PACKAGER")) |p| { if (b.graph.environ_map.get("PUNKBIN_PACKAGER")) |p| {
if (p.len != 0) break :blk p; if (p.len != 0) break :blk p;
} }
//out_code is only meaningful on some runAllowFail paths - judge
//success by usable trimmed output, not the code
var gc: u8 = undefined; var gc: u8 = undefined;
const gname: ?[]const u8 = b.runAllowFail(&.{ "git", "config", "user.name" }, &gc, .ignore) catch null; const gname: ?[]const u8 = b.runAllowFail(&.{ "git", "config", "user.name" }, &gc, .ignore) catch null;
if (gname != null and gc == 0) { if (gname != null) {
const nm = std.mem.trim(u8, gname.?, " \t\r\n"); const nm = std.mem.trim(u8, gname.?, " \t\r\n");
if (nm.len != 0) { if (nm.len != 0) {
const gmail: ?[]const u8 = b.runAllowFail(&.{ "git", "config", "user.email" }, &gc, .ignore) catch null; const gmail: ?[]const u8 = b.runAllowFail(&.{ "git", "config", "user.email" }, &gc, .ignore) catch null;
if (gmail != null and gc == 0) { if (gmail != null) {
const em = std.mem.trim(u8, gmail.?, " \t\r\n"); const em = std.mem.trim(u8, gmail.?, " \t\r\n");
if (em.len != 0) break :blk b.fmt("{s} <{s}>", .{ nm, em }); if (em.len != 0) break :blk b.fmt("{s} <{s}>", .{ nm, em });
} }

8
src/tests/shell/testsuites/punkexe/tclshcmd.test

@ -339,12 +339,14 @@ puts "PRGOT:[string trim $d]"} pr_consume.tcl]
# -- piperepl launch-state contract (patched runtime kits) ------------------------------------- # -- piperepl launch-state contract (patched runtime kits) -------------------------------------
#added 2026-07-23 (agent) - piperepl ::tclsh launch-state contract via the tclsh subcommand (G-096/G-103 patched kits) #added 2026-07-23 (agent) - piperepl ::tclsh launch-state contract via the tclsh subcommand (G-096/G-103 patched kits)
test tclsh_pr_noarg_machinery {piped no-arg run publishes ::tclsh machinery: istty 0, dorepl 0, evalinput 0}\ test tclsh_pr_noarg_machinery {piped no-arg run publishes ::tclsh machinery: istty 0, dorepl 0, evalinput 0, reopened 0}\
-constraints pipereplkitavailable -setup $common -body { -constraints pipereplkitavailable -setup $common -body {
variable pipereplexe variable pipereplexe
set rd [punk_run $pipereplexe [list tclsh] "puts \[list PRSTATE \[info exists ::tclsh(istty)\] \$::tclsh(istty) \$::tclsh(dorepl) \$::tclsh(evalinput)\]\n"] #reopened: published 0 at gate-open startup since the 2026-07-24 patch rev
#(G-118 item 7); the console-reopen flip to 1 is console-harness territory
set rd [punk_run $pipereplexe [list tclsh] "puts \[list PRSTATE \[info exists ::tclsh(istty)\] \$::tclsh(istty) \$::tclsh(dorepl) \$::tclsh(evalinput) \[info exists ::tclsh(reopened)\] \$::tclsh(reopened)\]\n"]
lappend result [dict get $rd timedout] lappend result [dict get $rd timedout]
lappend result [expr {[string first "PRSTATE 1 0 0 0" [dict get $rd output]] >= 0}] lappend result [expr {[string first "PRSTATE 1 0 0 0 1 0" [dict get $rd output]] >= 0}]
lappend result [dict get $rd exitcode] lappend result [dict get $rd exitcode]
} -result [list 0 1 0] } -result [list 0 1 0]

Loading…
Cancel
Save