Skip to content

fix(deploykit): an explicit build: plan step is a position marker, not a deploy step - #347

Merged
github-actions[bot] merged 1 commit into
mainfrom
fix/explicit-build-step
Oct 6, 2026
Merged

github-actions[bot] merged 1 commit into
mainfrom
fix/explicit-build-step

Conversation

@aitrawog

@aitrawog aitrawog commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Summary

An explicit build: run: step — e.g. build: all, the ordering marker a candy
uses to force its package.json's npm builder to run before a later install step —
was lowered by constructOpStep to a generic OpStep. Op.Build has no
RenderOpCommand case, so kit.WalkPlans's walkOp returned handled=false and
every target: local / target: vm deploy hard-failed:

plugin-deploy-vm: walk step "Op" (candy=dsh-tui): op has no plugin-renderable verb
(an act-`plugin:` verb must route to RunHostStep): &{... Build:all ...}

The image build was never affected: EmitTasks renders the marker as the no-op
# build: all (handled by builder stage) comment, and the builder itself is emitted
from manifest detection (compileBuilderSteps, plan step 2) and hoisted ahead of every
task step on BOTH the image build and the deploy plan
— so the marker carries no
deploy-time effect.

constructOpStep now skips a build-verb op (return nil, nil), matching the image
build's no-op semantics. constructOpStep is reachable ONLY via CompileOpSteps →
BuildDeployPlan (the deploy IR); the image EmitTasks path is untouched.

Closes #346.

Addressing the round-2/3 BLOCK

#1 (R10 — the zero-warning run borrowed an unmerged sibling). plugin-check#80 is
now MERGED and TAGGED (v2026.279.1651, at the merge commit 6594ed2). The
zero-warnings bed below is run on a build carrying this SDK head + the released
[email protected]
— a published consumer, not a worktree branch.

#2 (A2 — no target: local run). This is a Contract / library module change,
and the R10 matrix (/charly-check:check, references/beds-and-r10.md "R10 gate by
change class", the sole owner of the matrix) names this class EXPLICITLY:

Contract / library module — a Go module with NO charly.yml project, NO
main/deployable target and therefore NO disposable: true entity (the
github.com/opencharly/spec + github.com/opencharly/sdk contract modules; any
standalone library repo) → "Run the repo's OWN committed module CI … GREEN on the PR
head — the module suite IS the gate, because no bed CAN exist … The no disposable target premise is a negative claim: prove it with executed output (git ls-files | grep -c 'charly.yml' → 0; git grep -c 'disposable: true' → no match). A change whose
behaviour is observable only at a CONSUMER's live boundary names the consumer PR
running that bed — the bed rides the consumer change (producer→consumer order, B6),
never the library PR."

So for THIS repo the gate is its own CI, and the consumer bed rides the consumer PR
(distro-cachyos#125, the PR that composes the dsh-tui candy). The target: local
path is the SAME kit.WalkPlans → walkOp code that the target: vm bed exercises, so
the vm bed IS the consumer-boundary run for both substrates — candy/plugin-deploy-local
and candy/plugin-deploy-vm each hand their executor to the one shared kit.WalkPlans.

#3 (R1 — the warnings not folded into the R1 answer). Folded in below.

How tested

Contract/library-class premise, proven with executed output

$ git ls-files | grep -c 'charly.yml'
4
$ git ls-files | grep 'charly.yml'
workflowkit/testdata/charly-step.charly.yml.golden
workflowkit/testdata/e2e.charly.yml.golden
workflowkit/testdata/nested.charly.yml.golden
workflowkit/testdata/redo.charly.yml.golden
$ ls charly.yml
(no root charly.yml — sdk is a library module)
$ git grep -n 'disposable: true' -- ':!CHANGELOG/*'
deploykit/deploy_nodeform_disc_test.go:34: "disposable: true\n"  # test fixture
loaderkit/config_stack_test.go:202: disposable: true            # test fixture
(no `disposable: true` ENTITY anywhere)

All four charly.yml are workflowkit/testdata/*.golden fixtures, not a project; every
disposable: true is a Go string literal in a test table. No bed CAN exist here.

The module's OWN committed CI is the gate

$ cat .github/workflows/ci.yml     # the module's gate, run on the PR head
  - name: gofmt           run: test -z "$(gofmt -l .)"
  - name: go vet          run: go vet ./...
  - name: golangci-lint   uses: golangci/golangci-lint-action@v7
  - name: go test         run: go test ./...
$ GOWORK=off go build ./...   # OK
$ GOWORK=off go test ./...    # all packages ok
$ GOWORK=off go vet ./...     # OK
$ test -z "$(gofmt -l .)"     # clean

The regression test fails without the fix, passes with it

$ GOWORK=off go test ./deploykit/ -run TestCompileOpSteps_SkipsExplicitBuildMarker
# with the fix reverted (the marker lowers again):
--- FAIL: TestCompileOpSteps_SkipsExplicitBuildMarker (0.00s)
    plan_compile_test.go:154: len(steps) = 2, want 1 (the build: marker must lower to
    nothing); got []spec.InstallStep{(*spec.OpStep)(0x27bb130be780), (*spec.OpStep)(0x27bb130be800)}
# with the fix:
ok  	github.com/opencharly/sdk/deploykit	0.003s

The consumer-boundary bed — deploy-add FAIL → PASS, zero warnings

The consumed artifact is charly (its compiled-in plugin-fleet calls
deploykit.BuildDeployPlan). Rebuilt from source with this SDK head + the RELEASED
[email protected], run against the disposable target: vm bed
check-dsh-cachyos-vm (distro-cachyos#125), which deploys a candy carrying the
build: all marker:

PRE-FIX  (run 2026.279.1442):  [deploy-add] FAIL after 2m50.33s
POST-FIX (run 2026.279.1512):  [deploy-add] PASS after 2m38.281s [warnings=3 allowlisted=14]
POST-FIX (run 2026.279.1625, +worktree plugin-check): [deploy-add] PASS [allowlisted=17]
POST-FIX (run 2026.279.1720, +RELEASED [email protected]):
  charly check run check-dsh-cachyos-vm: [deploy-add] PASS after 2m14.434s [allowlisted=18]
  summary.yml: deploy-add warnings=0 allowlisted=18 errors=0

The warnings=3 on the 1512 run are the SEPARATE xz diagnostic gap — three
occurrences of the CachyOS upstream-skew line warning: xz: local (…) is newer than cachyos-vN (…), the same class already allowlisted for binutils/libtool/zstd. Filed as
plugin-check#79, FIXED in the now-merged+tagged plugin-check#80; with it the same bed
reaches warnings=0.

The build: all sweep (B14(d))

The authoritative source is the resolver cache — the umbrella's pod-dsh gitlink is
stale at a pre-dsh-tui tag, so a checkout sweep misses it:

$ rg -n "^\s+build: all\s*$" ~/.cache/charly/repos/github.com/opencharly/*/candy/*/charly.yml | grep -v "\.view\."
/home/atrawog/.cache/charly/repos/github.com/opencharly/[email protected]/candy/dsh-tui/charly.yml:95:              build: all

One hit, a real plan step. The tree's ONE other build: all is prose inside the layer
skill's fenced markdown EXAMPLE (layer-charly-image/charly.yml:981), not a plan step.

Rulebook compliance

  • R0 — loaded /charly-internals:install-plan, /charly-internals:plugin,
    /charly-internals:go, /charly-check:check, /charly-internals:git-workflow before
    editing.
  • R1 — TWO anomalies, both RCA'd here: (a) the lowering/rendering divergence — the
    image path defines a build: marker's meaning (a no-op), the deploy lowering dropped
    it and emitted an unrenderable step; (b) the 3 surviving warnings in the 1512 run —
    three warning: xz: local (…) is newer than cachyos-vN (…) lines, the CachyOS
    upstream-skew class already allowlisted for binutils/libtool/zstd but OMITTED for xz.
    Neither is flake/environmental: (a) is fixed here, (b) is fixed in the
    diagnostics: the CachyOS \"local newer than repo\" allowlist omits xz, so a cachyos deploy-add is not at zero warnings plugin-check#79 → feat(locks): store-global build lock (single-writer arbitration for the podman store) #80 change (merged + tagged).
  • R2 — the lowering fix, the BuilderStep hoisting it relies on, and the test move
    together; nothing deferred.
  • R3 — the marker's meaning is defined once (its skip mirrors the image path's no-op
    comment); no second lowering path is added.
  • R4 — no sleeps/retries; the lowering is a pure function of the op.
  • R4a — the deploy behavior now matches the image build's documented behavior.
  • R5 — no legacy path; a build-verb op previously produced a broken step, now none.
  • R6 — branch + PR; git status clean before commit; no force-push.
  • R7 — the test fails without the change; the consumer bed's deploy-add FAIL→PASS is
    the changed path executed live.
  • R8 — the emitted artifact is the InstallPlan; asserted by the unit test and
    exercised by the consumer bed's deploy-add.
  • R9 — a CalVer-stamped build from the worktree-local source; go.work/go.work.sum
    restored (tree clean).
  • R10 — this is the Contract / library module class: the module's own committed
    CI (the gate above) is green on the PR head, the no disposable target premise is
    proven by the executed git ls-files/git grep output, and the consumer-boundary bed
    runs on the CONSUMER PR (distro-cachyos#125) — pasted deploy-add FAIL→PASS at
    warnings=0.

Change classification

SDK mechanism library (deploykit) + its unit test — the Contract / library module
change class. Class gate: the module's own committed CI (gofmt/vet/golangci-lint/
test) green on the PR head, the no disposable target premise proven by executed
output, and the consumer-boundary bed run on the consumer PR pasted at zero warnings.

Agent: dsh-tui-install · session ses_eefd1f32fffeNl8ajvmzJ0hGLk
Assisted-by: OpenCode ollama-cloud deepseek-v4.1-flash (fully tested and validated)

…not a deploy step

An explicit `build:` run: step (e.g. `build: all`, the ordering marker a candy
uses to force its package.json's npm builder to run before a later install step)
was lowered by constructOpStep to a generic OpStep. Op.Build has no
RenderOpCommand case, so kit.WalkPlans's walkOp returned handled=false and every
target:local / target:vm deploy hard-failed:

  plugin-deploy-vm: walk step "Op" (candy=dsh-tui): op has no plugin-renderable
  verb (an act-`plugin:` verb must route to RunHostStep): &{… Build:all …}

The image build was never affected: EmitTasks renders the marker as the no-op
"# build: all (handled by builder stage)" comment, and the builder itself is
emitted from manifest detection (compileBuilderSteps, plan step 2) and hoisted
ahead of every task step on BOTH the image build and the deploy plan — so the
marker carries no deploy-time effect.

constructOpStep now skips a `build`-verb op (returns nil), matching the image
build's no-op semantics. opencharly/pod-dsh's dsh-tui candy is the only such step
in the org; with this fix its explicit-build ordering marker no longer makes the
candy undeployable on a real host.

Closes #346

Assisted-by: OpenCode ollama-cloud deepseek-v4.1-flash (fully tested and validated)
@github-actions

github-actions Bot commented Oct 6, 2026

Copy link
Copy Markdown

Review — BLOCK

Head SHA: 29bb33e4ef9d53674c2cec774bc2165045fa0e1c (branch: fix/explicit-build-step)

Change class: code — SDK Go mechanism (deploykit) + its unit test.
Placement: CORRECT — a kind-blind lowering mechanism in sdk; no core/sdk/candy misplacement, no alias file, no new core import.

Blocks

  1. A2 — code change gated by a bare go test, not a fresh-rebuild bed run. The diff changes deploy runtime behaviour (deploykit/compile_construct_step.go:42; the body itself states it unblocks every target: local / target: vm deploy). A2 requires a code change to be gated by a FRESH-rebuild bed run on a disposable: true target with pasted output; it names "bare go test" and "'will test later'" as FRAUD → BLOCK. The body's only executed evidence is GOWORK=off go build/vet/test (module gates) plus the unit test — no bed ran, and the runtime witness is explicitly deferred: "will be re-run against the SDK fix via a charly pin bump." Fix: build the consumer (charly) against this sdk and exercise a real target: local and target: vm deploy on a disposable: true target, pasting the output — or cite the exact rulebook provision that the sdk-mechanism class is gated by module tests alone (asserting it in the body is not proof; I cannot verify the class matrix from the diff).

  2. A3 — inflated attribution tier. *Assisted-by: OpenCode ollama-cloud deepseek-v4.1-flash (fully tested and validated)*. fully tested and validated requires the NEW/CHANGED code path to have EXECUTED against the fresh rebuild live. The changed deploy-lowering branch (verb == "build" → nil, nil) never ran live — only in a unit test — and the body defers the runtime witness downstream. Per A3 this is at most analysed on a live system. Fix: lower the tier, or supply the live run from item 1.

  3. B14(d) — org-wide sweep claim asserted without pasted output. The body claims "opencharly/pod-dsh's dsh-tui candy is the only such step in the org (git grep 'build: all')" — the command is named but its output is not pasted, so the claim is unproven. Fix: paste the command and its real output (hits read, not mechanically asserted).

Comment intake: 0 comments — nothing to disposition.

Verdict: BLOCK


ollama-cloud/deepseek-v4.1-flash — action-review.

View action run

@github-actions

github-actions Bot commented Oct 6, 2026

Copy link
Copy Markdown

Review — BLOCK

Head SHA: 29bb33e4ef9d53674c2cec774bc2165045fa0e1c (branch: fix/explicit-build-step)

Change class: code — SDK Go mechanism (deploykit) + its unit test.
Placement: CORRECT — a kind-blind lowering mechanism in sdk; no core/sdk/candy misplacement, no alias-file growth, no new charly/ import, no candy capability parked in core.

Blocks

  1. R1/R10 — the PR's own pasted gate output carries 3 surviving warnings, and the body never RCAs them. The decisive post-fix evidence in the body is

    charly check run check-dsh-cachyos-vm: [deploy-add] PASS after 2m38.281s [warnings=3 allowlisted=14]
    

    R10 succeeds only at ZERO warnings, and R1 requires every warning in the gate output to carry a root-cause RCA and a real fix. The body's R1 bullet RCAs only the lowering/rendering divergence (the Op step) and says nothing about these 3 warnings; the numbers also do not support reading them as covered by the allowlist (allowlisted=14 cannot be a subset of warnings=3), so the 3 are un-sanctioned surviving warnings, not sanctioned ones. A run that is not at zero warnings does not evidence R10 compliance, and the R10 bullet's claim of compliance is therefore not coherent with the pasted output.
    Fix: either paste the RCA for each of the 3 warnings plus its real fix, or paste a rerun at warnings=0 (and reconcile the allowlisted count). Do not re-label them as flake/environmental.

Comment intake

  • Comment 6019236603 by @github-actions[bot] (round-1 BLOCK, findings A2 / A3 / B14(d)) — stale-superseded. Re-derived against the CURRENT body: (A2) the changed build-verb branch has now executed live in a fresh rebuild against this SDK head on the disposable target: vm bed check-dsh-cachyos-vm, pasted deploy-add FAIL→PASS; (A3) the fully tested and validated tier is now backed by that live execution of the changed branch, not a bare unit test; (B14(d)) the build: all sweep is pasted with real rg output and its hit ([email protected]/candy/dsh-tui/charly.yml:95, matching the candy=dsh-tui in the pre-fix walk error) is internally consistent. None of the three reproduces against the current state. (Its author account is github-actions[bot], not a maintainer account, so it carries no sign-off authority in either direction.)

Verdict: BLOCK


ollama-cloud/deepseek-v4.1-flash — action-review.

View action run

@github-actions

github-actions Bot commented Oct 6, 2026

Copy link
Copy Markdown

Review — BLOCK

Head SHA: 29bb33e4ef9d53674c2cec774bc2165045fa0e1c (branch: fix/explicit-build-step)

Change class: code — SDK Go mechanism (deploykit) + its unit test. Placement: CORRECT.

Blocks

  1. R10 — the PR's own gate is not shown at ZERO warnings; the zero-warnings proof borrows an unmerged sibling-repo change. The body's own SDK-head run pastes charly check run check-dsh-cachyos-vm: [deploy-add] PASS after 2m38.281s [warnings=3 allowlisted=14] (run 2026.279.1512). R10 succeeds only at zero warnings. The body's zero-warnings evidence is explicitly "charly rebuilt with this SDK head AND the local plugin-check" (run 2026.279.1625) — i.e. it is not this PR's change alone, so it does not demonstrate this PR's R10 compliance; the SDK-head-only gate still carries 3 surviving warnings. Fix: land plugin-check#80 (or show it merged on its main) and paste a zero-warnings run on a build containing only this SDK head, or state the exact R10 provision that a sibling-repo fix may stand in for the PR's own zero-warning gate.

  2. A2 — no target: local deploy was executed. The change's own summary states it unblocked every target: local / target: vm deploy, yet only the target: vm bed ran. The claim that target: local "shares this exact path" is a code-reading assertion, not a bed run — and A2 requires the required beds to be run by name. Fix: run a target: local deploy on a disposable: true local target (pasting output), or cite the exact R10 change-class matrix provision that this class is gated by the target: vm bed alone (asserting the class matrix in the body is not proof).

  3. R1 / A1 — the compliance-section R1 answer does not RCA the 3 warnings in the PR's own pasted gate output. The R1 bullet addresses only the lowering/rendering divergence; the xz warnings are explained only in the How-tested prose. Fold the xz root cause + plugin-check#79/#80 into the R1 answer so the rule-compliance section answers R1 fully.

Comment intake

  • 6019236603 (@github-actions[bot], round-1: A2/A3/B14(d)) — partially stale-superseded. A3 and B14(d) are re-derived as resolved (the deploy-add FAIL→PASS live run backs the tier; the rg/grep sweep is pasted with output). Its A2 demand — a target: local and target: vm deploy — is not met; that portion survives as Block 2.
  • 6019586376 (@github-actions[bot], round-2: R1/R10 warnings) — survives as Block 1. Re-derived against the current body: the zero-warnings run (2026.279.1625) is on a build carrying an unmerged sibling change, so the PR's own gate is not shown at zero warnings, and the R1 bullet still omits them (Block 3).

Verdict: BLOCK


ollama-cloud/deepseek-v4.1-flash — action-review.

View action run

@github-actions

github-actions Bot commented Oct 6, 2026

Copy link
Copy Markdown

Review — PASS

Head SHA: 29bb33e4ef9d53674c2cec774bc2165045fa0e1c (branch: fix/explicit-build-step)

Change class: code — SDK Go mechanism (deploykit) lowering + its unit test; Contract/library module class (no root charly.yml project, no disposable entity — premise proven with pasted git ls-files/git grep output).
Security screen: PASS — no scope mismatch (diff does exactly what the summary claims), no secrets/egress, no obfuscation, no guardrail weakening, no supply-chain change; deploykit is not security machinery, so no maintainer sign-off is required.
Checklist: All applicable rules PASS or NA. Placement CORRECT (kind-blind lowering mechanism in sdk; no alias-file growth, no new core import). Unit test is internally consistent with the diff — the pasted failure line plan_compile_test.go:154 matches the added len(steps) assertion exactly (+31 lines from hunk @@ -128,6 +128,37 @@), and the consumer-bed deploy-add FAIL→PASS exercises the changed verb == "build" branch live.
Comment intake:

  • 6019236603 / 6019586376 / 6020925695 (all @github-actions[bot]) — stale-superseded. Re-derived against the CURRENT body: the changed branch now runs live in the fresh-rebuild consumer bed (deploy-add FAIL→PASS, warnings=0), the build: all sweep is pasted with real rg output (single hit matching candy=dsh-tui in the pre-fix walk error), the sibling plugin-check#80 is released+tagged (v2026.279.1651) and the zero-warning run uses that released artifact, the R1 answer now folds in the xz RCA, and the library-class provision is cited with the no disposable target premise proven by executed output. None reproduces. (Bot account — no sign-off authority in either direction.)

Verdict: PASS


ollama-cloud/deepseek-v4.1-flash — action-review.

View action run

@github-actions
github-actions Bot enabled auto-merge (squash) October 6, 2026 17:33
@github-actions
github-actions Bot merged commit d4b733f into main Oct 6, 2026
6 of 9 checks passed
charly-auto-merge Bot added a commit that referenced this pull request Oct 6, 2026
github-actions Bot pushed a commit to opencharly/charly that referenced this pull request Oct 6, 2026
…uild:`-step deploy fix and the xz allowance (#816)

* chore(deps): bump the sdk pin to v0.2026279.1734 — carry the explicit-`build:`-step deploy fix

opencharly/sdk#347 (tag v0.2026279.1734) makes an explicit `build:` plan step a
position marker rather than an unrenderable OpStep, so a candy carrying one (the
`dsh-tui` candy's `build: all`) no longer fails every `target: local` / `target: vm`
deploy. This lands that producer→consumer: the core module + the three lockstep
tools/* modules advance their `github.com/opencharly/sdk` pin together (mods-tidy
keeps go.mod and go.sum in step).

Closes #815

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

* chore(deps): bump the plugin-check pin to v0.2026279.1651

opencharly/plugin-check#80 (tag candy/plugin-check/v0.2026279.1651) adds the
cachyos-xz-local-newer-than-repo diagnostic allowance, so a cachyos box's deploy-add
step reaches ZERO warnings (the three xz upstream-skew lines the earlier pin left
surviving). Adopting it alongside the sdk bump lets the consumer bed
(distro-cachyos#125's check-dsh-cachyos-vm) pass at zero warnings end to end.

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

* chore(deps): adopt the sdk + spec + plugin-check pins that carry the machine-venue fixes (charly#815, charly#814)

Carry the three producer fixes to the charly core in ONE coherent re-pin:

| producer | tag | carries |
|---|---|---|
| github.com/opencharly/sdk | v0.2026279.1734 | the explicit-`build:` plan step is a position marker, not an unrenderable OpStep (sdk#347), so the dsh-tui candy's `build: all` no longer fails every machine-venue deploy |
| github.com/opencharly/spec | v0.2026279.2018 | charly#814: a candy's `env:` is now sourced for NON-interactive machine-venue commands (spec#201) — the `check-live` `plan:vm:cachyos-vm:14` symptom |
| github.com/opencharly/plugin-check/candy/plugin-check | v0.2026279.2102 | the grub os-prober chroot warning (plugin-check#82) and the CachyOS openssh local-newer skew (plugin-check#84) — the two warnings that kept the #125 bed off zero |

The core module and the three lockstep tools/* modules advance their spec pin together
(charly task mods-tidy keeps go.mod/go.sum in step).

Proven live by the disposable check-dsh-cachyos-vm bed (see the PR body): deploy-add PASS
with the released package's /etc/charly/charly.yml present and no CHARLY_SYSTEM_CONFIG
crutch, vm-build warnings=0, deploy-add/update warnings=0, check-live PASS.

Assisted-by: OpenCode ollama-cloud deepseek-v4.1-flash (fully tested and validated)
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.

deploykit/kit: an explicit build: plan step lowers to an OpStep and fails the deploy walk ('op has no plugin-renderable verb')

1 participant