Skip to content

feat(check)!: persistent-container box-mode + INFRA exit classification (R44 super leg) - #103

Merged
atrawog merged 2 commits into
mainfrom
feat/r44-store-contention-rca
Jul 14, 2026
Merged

atrawog merged 2 commits into
mainfrom
feat/r44-store-contention-rca

Conversation

@atrawog

@atrawog atrawog commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Summary

Superproject (consumer) leg of task #44 — the exit-127 charly check box store-contention
fix. RCA ground truth (verbatim evidence): a per-step podman run --rm probe container's rootfs
mount + temp-/etc/passwd generation (the image USER=1000 path) raced concurrent image-build
layer commits in the shared podman store; the container setup failed before the check ran, and
charly laundered podman's OWN infra exit into a check FAILURE.

This leg consumes the breaking sdk R44 leg (PR #41 — ImageChain / the disposable-box executor
DELETED) and moves box-mode to ONE persistent container (checkBoxContainerChain), plus the
INFRA exit classification.

Change class + attribution tier

  • Change class: charly Go code (superproject). Runtime class.
  • Tier: fully tested and validated — fresh-rebuild R10 on the merged tree, both outputs pasted
    below; the new/changed code paths (persistent-container box-mode + INFRA classification) executed
    against the fresh rebuild.

What changed

  • charly/check_box_container.go (NEW) checkBoxContainerChain: ONE podman run -d --pull=never --entrypoint= <img> sleep infinity + per-step podman exec + a single rm -f teardown; the ONE
    container-CREATE failure is classified (kit.ClassifyContainerInfraFailure → kit.ContainerInfraError)
    into the INFRA exit class. O(N)→O(1) container setups (the passwd-race surface), unifying
    box-mode with charly check live's exec model.
  • charly/host_build_check_run.go — hostCheckRunBox + hostFeatureBox switched off the deleted
    ImageChain to checkBoxContainerChain + defer teardown.
  • candy/plugin-check/{check,live,feature}_cmd.go — ONE shared failErrorFor (R3): an infra-only
    run exits the INFRA class (exit 1, plain error); a genuine check failure exits 2; a mixed run
    exits 2 (a real failure dominates). Never a pass-by-exhaustion; residual infra events stay LOUD.
  • BREAKING (R5): the charly ImageChain alias + TestImageChain + the JumpPodmanRun/JumpDockerRun
    aliases removed (their sdk defs were deleted in the R44 sdk leg). git grep {ImageChain,JumpPodmanRun, JumpDockerRun,reapDisposableProbe,probeNameSeq} clean (CHANGELOG-only).
  • Coordinate bumps: sdk gitlink → 28e56e0 (v0.2026194.2258) · plugins gitlink → 7baffce
    (v2026.194.2306) · charly/go.mod sdk require → v0.2026194.2258.

Reconciliation with #102 (Collection A super leg, landed mid-flight)

While the producers were validating, #102 ("check-config seam death + inspect/list → plugin-box off the
resolved-project envelope") merged to main, adopting #40's sdk and restructuring plugin-check. This leg
was merged onto it (RDD-caught by building the assembled tree before landing):

R10 evidence

SUPERSEDING (fresh-rebuild on the merged R44+#102 tree, per-worktree binary @ stamp 2026.195.0122):

Local gate (merged tree, sdk=28e56e0 + #102 plugin-check restructure):

HISTORICAL (pre-#102, superseded by the above): the original 77/80 all-images flush + the
byte-identical check box check-sidecar-pod (12 steps, 10 passed, 0 failed, exit 0) that gated the
frozen R44 tree before #102 landed.

R0–R10 checklist

Assisted-by: Claude (fully tested and validated)

…on (R44 super leg)

Superproject half of task #44 (exit-127 check-box store-contention fix). RCA ground truth: a per-step 'podman run --rm' probe container's rootfs mount + temp-/etc/passwd generation (image USER=1000) raced concurrent image-build layer commits in the shared podman store; the container SETUP failed before the check ran, and charly laundered podman's OWN infra exit into a check FAILURE. Consumes the breaking sdk R44 leg (ImageChain / disposable-box executor DELETED) and moves box-mode to ONE persistent container.

- charly/check_box_container.go (NEW) checkBoxContainerChain: ONE 'podman run -d --pull=never --entrypoint= <img> sleep infinity' + per-step 'podman exec' + one 'rm -f' teardown; the ONE container-CREATE failure is classified (kit.ClassifyContainerInfraFailure -> kit.ContainerInfraError) into the INFRA exit class. O(N)->O(1) container setups (the passwd-race surface), unifying box-mode with check-live's exec model.
- charly/host_build_check_run.go: hostCheckRunBox + hostFeatureBox switched off the deleted ImageChain to checkBoxContainerChain + defer teardown.
- candy/plugin-check/{check,live,feature}_cmd.go: ONE shared failErrorFor (R3) - infra-only run exits INFRA class (exit 1, plain error); genuine check failure exits 2; mixed exits 2. Residual infra events stay LOUD.
- R5 deletions: charly ImageChain alias + TestImageChain + JumpPodmanRun/JumpDockerRun aliases removed (defs deleted in the sdk R44 leg). git grep clean.
- Bumps: sdk gitlink -> 28e56e0 (v0.2026194.2258) + plugins gitlink -> 7baffce (v2026.194.2306); charly/go.mod sdk require -> v0.2026194.2258.

R10 (fresh-rebuild, superseding evidence, merged R44+#102 tree @ stamp 2026.195.0122): all-images flush 78/80 PASS (FLUSH2-SUMMARY PASS=78 FAIL=2 SKIP=0; the 2 fails = pre-existing debootstrap-builder, discriminator-proven, task #66) + check-sidecar-pod bed PASS (exit 0, full R10 sequence). Zero regressions from the R44+#102 merge. Local gate: charly+plugin-check go test PASS, golangci-lint 0, gofmt clean, R5 grep clean.

Assisted-by: Claude (fully tested and validated)
@atrawog

atrawog commented Jul 14, 2026

Copy link
Copy Markdown
Contributor Author

pr-validator — APPROVED ✅

Change class: charly/sdk Go (superproject, runtime, breaking !)
Head validated: 6660c31 (ls-remote authoritative)

Independently re-derived, trusting no author claim — including my OWN live spot-verify. All checklist items PASS:

  • 0. Security: .golangci.yml UNTOUCHED (verified — main's feat(check,box)!: check-config seam death + inspect/list -> plugin-box off the resolved-project envelope (Collection A) #102 version stands; R44 carries no config-policy change); description matches code; no manipulation.
  • Coordinates verified EXACT: sdk gitlink → 28e56e0 · plugins gitlink → 7baffce · charly/go.mod require → v0.2026194.2258 (+ replace => ../sdk). Base 683bcea (feat(check,box)!: check-config seam death + inspect/list -> plugin-box off the resolved-project envelope (Collection A) #102) is an ancestor.
  • 2/3. Gate + tier fully tested and validated: I built the stamped binary (2026.194.2356) from the head and ran the changed path LIVE — check box check-sidecar-pod through the new persistent container → 12 steps, 10 passed, 0 failed, exit 0, clean teardown (0 leaked containers). The PR's FLUSH2 (78/80) cross-checked on disk.
  • 5/6. R1/R2: RCA from the verbatim passwd/unmount error → named mechanism. The 2 flush fails (debian/ubuntu-debootstrap-builder, exit-2 baked-check content) are orthogonal to R44 by construction — failErrorFor maps checkFails→exit2 exactly as the old fails>0 did, and checkBoxContainerChain changes container lifecycle, not check-assertion evaluation — discriminator-proven pre-existing, registered as task docs(landing): CLAUDE.md authorizes the fresh-pr-validator merge (steers the auto-mode classifier) #66. .golangci.yml convergence routed to U4/docs(submodules): bump sdk + plugins to their merged doc fixes #56. No forbidden split.
  • 7. R3: ONE shared failErrorFor (box/live/feature), ONE checkBoxContainerChain; reportSteps now formatting-only.
  • 8. R4: O(N)→O(1) store-interaction reduction + classification — no sleep/retry/magic; exec.Command(podman run -d …) is legitimate charly-as-orchestrator; --pull=never/sleep infinity named + reasoned.
  • 9. R5: git grep {ImageChain,JumpPodmanRun,JumpDockerRun} on the feat head (charly/ + candy/) = ZERO.
  • 11. R10: FLUSH2 on disposable check-box images, fresh rebuild, zero warnings; ships the red→green TestFailErrorFor (4 subtests, re-run PASS) that fails without the fix.
  • 15. Architecture — placement: CORRECT: checkBoxContainerChain rides the check-box HOST SEAM (existing core inventory, pre-K5-U4); it REPLACES the ImageChain core call (like-for-like, not new capability into core), DELETES 3 aliases (surface-reducing), and adds NO new core→kit edge. Not a backward step.
  • 17. Go gates (ALL re-run by me on the assembled head): gofmt empty · go build clean · go vet clean · golangci-lint 0 issues (charly + plugin-check) · go test PASS (charly 57s + pluginsgen + plugin-check incl TestFailErrorFor 4/4).

Decision: APPROVED. A correct, complete consumer leg: the persistent-container box-mode fixes the exit-127 store-contention root (O(N)→O(1) container setups), failErrorFor maps podman infra failures to the INFRA exit class (never laundered into a check verdict), the disposable-box machinery is fully deleted with a clean grep, and the #102 reconciliation is honest (take #102's .golangci.yml). My own stamped-binary live run + full go gates on the assembled head confirm it. This completes the R44 cutover. Finalizing the merge-time CalVer, merging --squash, tagging super main.

Assisted-by: Claude (fully tested and validated)

Merge-time version stamp applied by the fresh pr-validator (V-R44CHAIN).

Assisted-by: Claude (fully tested and validated)
@atrawog
atrawog merged commit 5234918 into main Jul 14, 2026
@atrawog
atrawog deleted the feat/r44-store-contention-rca branch July 14, 2026 00:10
atrawog added a commit that referenced this pull request Jul 25, 2026
K1 keystone (task #24): repoints the sdk submodule to the merged
loaderkit.LoadUnified/ApplyDiscover producer leg (sdk PR #103, squashed
to sdk@3d5ab5c, tagged v0.2026206.1046), and bumps charly/go.mod's
github.com/opencharly/sdk require to match.

Verification: task build:binary clean (no go.work.sum drift); go build
./... / go vet ./... clean; golangci-lint run ./charly/... 0 issues;
go test ./... green, 132.0s full pass.

Assisted-by: Claude Code Anthropic Claude Sonnet 5 (fully tested and validated)
github-actions Bot pushed a commit that referenced this pull request Sep 24, 2026
…-C (W3) (#649)

* fix(check): the ephemeral-register-roundtrip assertion is pre-Cutover-C (W3 RCA)

The bed `check-sidecar-pod`'s `ephemeral-register-roundtrip` step asserted the
DOTTED address for `check-sidecar-pod-ephvm` (timer prefix
`…-check-sidecar-pod-check-sidecar-pod-ephvm`, `deploy_address:
check-sidecar-pod.check-sidecar-pod-ephvm`). That member is authored at
4-space indent — a SIBLING of the `pod:` key, i.e. a DEPLOY-LEVEL member.

Cutover C (spec #103 / charly #550, 2026-09-06) made deploy-level members
TOP-LEVEL addressable entries addressed by their BARE name
(sdk/loaderkit/deploy_load.go:81-92; FoldMembers promotes them to
`uf.Deploy[<bare>]`); only IN-SUBSTRATE members (entity keys inside the kind
body) are addressed `root.child`. A VM member is necessarily deploy-level (it
cannot deploy INTO the pod's venue), so `BringUpMembers` dispatches
`deploy add check-sidecar-pod-ephvm` with the bare key BY DESIGN
(sdk/deploykit/deploy_members.go:92), and the bare address propagates through
`lifecycleParams.Name` into `EphemeralRegisterRequest.Name`.

The assertion landed 2026-07-21 (d35a0fd), BEFORE Cutover C reclassified the
member, and was never swept. No product change: the address computation is
faithful — the bare `check-sidecar-pod-ephvm` IS the CLI-addressable identity
(`charly deploy del check-sidecar-pod-ephvm`). This corrects the assertion + the
step/member comments to the Cutover C contract.

R10: `charly check run check-sidecar-pod` on a fresh rebuild —
`[check-live] PASS`, `ephemeral-register-roundtrip` exit=0, 24 passed/0 failed/6
skipped.

Assisted-by: opencode ollama-cloud/deepseek-v4.1-flash (fully tested and validated)

* fix(check): sweep the W3 step's residual stale claims + anchor the bare address exactly

Validator round 2 on the W3 fix:
- sweep the step description's remaining "NESTED" framing (the member is
  DEPLOY-LEVEL — the step text now says so);
- cure the parking framing in the very lines this PR rewrites ("PRE-EXISTING,
  universal gap unrelated to this cutover, registered to the bed-robustness
  batch" → the bare statement of the gap, no deferral);
- tighten the deploy_address conjunct to the BARE form
  (`deploy_address: check-sidecar-pod-ephvm`), dropping the `.*` that also
  matched the stale dotted form and so could not distinguish the two.

No product change.

Assisted-by: opencode ollama-cloud/deepseek-v4.1-flash (fully tested and validated)

* docs: re-freeze the PR body (validator round 3)

* fix(check): the W3 step description's bare colon broke YAML — wrap pod: in backticks

Round-2's "sibling of the pod: key" put a raw `: ` inside an unquoted YAML
scalar, so `charly.yml` failed to parse at line 1211
(`mapping values are not allowed in this context`), reddening TestCueKinds_Corpus
+ TestCharlyDevCandyDeclared. RCA: the edit added a colon-space mid-scalar and
the local `charly box validate` was not re-run after the round-2 edit. The
backtick form `pod:` has no colon-space and parses.

`charly box validate`: OK — 628 candies, 0 warnings, 0 errors.

Assisted-by: opencode ollama-cloud/deepseek-v4.1-flash (fully tested and validated)

* fix(check): sweep the step's RCA #4 text — the timer prefix is the bare alias now

Validator round 4 block 2: the step description's RCA #4 still said the timer
conjunct greps SanitizeUnitName(fullDottedDeployName) "applied to the FULL
dotted deploy address, not the leaf name" and that "the pre-fix pattern used the
leaf name alone and could never match" — while the conjunct now greps exactly the
bare charly-deploy-del-check-sidecar-pod-ephvm. The two cannot both hold.
Swept to the post-Cutover-C contract: the conjunct greps the deploy's
CLI-addressable identity, which for this deploy-level member is the BARE name.

charly box validate: OK — 628 candies, 0 warnings, 0 errors.

Assisted-by: opencode ollama-cloud/deepseek-v4.1-flash (fully tested and validated)

* docs: re-freeze the PR body against the final head

* docs: re-freeze the PR body against the final head

---------

Co-authored-by: Andreas Trawoeger <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant