Repository navigation
test: model an observing kube method in the external-verb dispatch fixture (#1117) - #1120
Conversation
…xture (#1117) The fixture's canonical out-of-process verb request modelled `{"method": "apply"}` for the `kube:` verb, and the two assertions reading `PluginInput["method"]` followed it. `apply` and `delete` — and the `manifest` field that existed only to carry them — were deleted from the verb in opencharly/plugin-kube#33 (DESIGN.md §23 D-VERB-1: a verb observes and never changes state), so the served `#KubeInput` refuses all three and the fixture modelled a payload no author could write. It now models `nodes`, the natural observing method, and both assertions follow it. One test fixture, three lines: no product code, no schema, no authored config, no pin. Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (fully tested and validated)
Review — PASSHead SHA: Security screen: PASS — no injection, secrets, scope mismatch, or weakened guardrail; diff is exactly the +3/−3 test-fixture change the body describes. Verdict: PASS ollama-cloud/deepseek-v4.1-flash — action-review. |
Summary
charly's external-verb dispatch fixture modelled{"method": "apply"}for thekube:verb, and two assertions on the decoded input followed it.applyanddelete— and themanifestfield that existed only to carry them — were deleted from the verb in plugin-kube#33 (squashd19e95d1cad420f152a1e983430d437269b9f8d3, tagv2026.315.0153, closing plugin-kube#32), because DESIGN.md §23 D-VERB-1 says a verb observes and never changes state. The served#KubeInputnow admits 12 method values — 11 observations plus the plugin-internalk3s-post-provision— and refuses all three retired identifiers, so the fixture's payload was a shape no author could write and the plugin would reject at load:That is
TODO.md12.7's "D-VERB-1: a verb observes" surviving in a place nobody sweeps — the same class as marketplace#611, where the corpus still publishescheck-k8s'sapply/deleterows because its ref trails the producer it projects: a retired API kept alive by an example nobody re-read. The fixture now modelsnodes, the natural observing replacement, and both assertions follow it. Closes charly#1117.Head
9c95a79395c4860e0c9384bab2fe01d4968c1c2c— 1 file, +3 −3:charly/external_verb_dispatch_test.go#Opmodels{"method": "nodes"}, and its assertion plus diagnostic expectnodesNothing else moves: the test still never dispatches to the real plugin (its
fakeExternalVerbis a Provider double), so the claim under test — the full#Opcrosses to an out-of-process provider asparams_json— is untouched. That is exactly why the stale word cost no red test, and why the example had to be corrected by reading rather than by a failure.How tested
The change class is one Go test fixture, so the owning gate is this repo's own
.github/workflows/ci.ymlGo job —go test ./charly/..., gofmt, golangci-lint — run on the committed tree, beside thego vetand R9 build thatcharly/AGENTS.mdmakes part of the core gate.1. The fixture runs, and a planted break fails on the ASSERTION
The plant reverts only the fixture's input word to the deleted
applyand leaves the assertion atnodes— the half-done edit a future reader would make. It goes red insidet.Fatalfat line 58, not at the compiler, and it is restored from the commit itself (git show HEAD:<path>), so the second hash and the emptygit statusare the proof that the tree is byte-identical to what is pushed.Restore, byte-identical:
2. The deleted vocabulary is gone from the
kube:context — a calibrated, claim-keyed sweepScope is every tracked file that names the kube verb,
CHANGELOG/excluded (history may name a retired word; R5 asks for no live occurrence). Three site-forms can carry a kube method word — a map literal, an assertion on the decoded input, and a diagnostic that names it — so each is its own predicate, and each is calibrated by a known-live method word in the same place, because a grep that returns zero without a positive control is not evidence.Before the change, on
origin/main— three sites, all in the fixture:After the change, on the committed tree — the same three predicates plus the kube-step census, every command with its own exit status:
Reading it:
P1/P3/P4return nothing while their control arms print 1, 2 and 1 matching lines (the fixture's own newnodeswording, plus the appium fixture'sstatus), so the predicate demonstrably sees a method word when one is there. The kube-step census walkscharly.yml: 42 lines open akube:step — 36 block-form (whosemethod:children number 36, every one a live word) and 6 inline-form (every one live) — against 0 deleted words in either form, over 136 extracted block-body lines.P5finds nomanifestmodifier among those bodies against 11 survivingnamespace:modifiers in the same bodies, so the extraction is not vacuous. Thekube: {method: <word>}flow-map form is covered by the same key-form predicate and is likewise zero for the deleted words.The sibling census — every Go fixture in this repo that models a verb's
PluginInput— is the same question asked of the other verbs:So the answer to "did the same retired vocabulary survive anywhere else in
charly?" is 0 further occurrences in this repo: the fixture's three sites were the whole set, and the ten sibling sites (the eight verb wordswl,cdp,dbus,vnc,record,spice,libvirt,appium;wlandappiumeach carry a second site) namestatus,screenshot,listorinfo— none of which is a deleted kube method, so the sweep finds none of them.3. Siblings outside this repo, and why they are not edited here
The same three sites are alive in two other repos' vendored
charlycheckout:plugin-herdrandpod-herdrboth pin thecharlygitlink ateda33c00da9fd40a17787d0d590f07ad9475e435, whosecharly/external_verb_dispatch_test.gois the pre-fix file. Those are pins in other repos, so they are filed, not edited (below):Both pins name the same commit, so one issue (
plugin-herdr#16) carries both; the fix there is each repo's owncharly task syncplus a PR.4. The owning gate, on the committed tree
gofmtlists nothing,go vetis silent, the module-wide test run is green for both packages (the affectedgithub.com/opencharly/charly/charlypackage included), the lint reports0 issues, and the worktree-local CalVer build answers./bin/charly version— so the pushed tree is the tree that was gated.One environment note, and its root fix. The first lint run on this host failed, in a package the diff does not touch, with every finding a
typecheckwhose text is an export-data version the bundled importer cannot decode:That is a build-environment incompatibility, not a finding: this host's
goisgo1.27.3-X:nodwarf5(a patched build, and whatcommand -v goresolves to), so the packages are compiled with a toolchain newer than the export format the lint binary's importer supports, and no code is analysed at all.ci.ymlinstalls Go fromgo-version-file: charly/go.mod(go 1.26.8) and builds the linter with it, so the mismatch is unreachable there. Reproducing CI's declared toolchain locally (GOTOOLCHAIN=go1.26.8) makes the same lint answer0 issues— the invocation pasted in the gate block above.Rulebook compliance
/charly-internals:git-workflow,/charly-kubernetes:check-k8s,/charly-internals:goand/charly-internals:cutover-policybefore the first edit, after reading the umbrellaAGENTS.mdandcharly/AGENTS.md(git -C charly show origin/main:AGENTS.md). Thekube:-verb row is whycheck-k8sis among them: it states the method surface this fixture models.methodto be followed directly by:/=, so the Go map key"method": "apply"(with its closing quote) did not match and the sweep under-reported one of the three sites; the positive control is what exposed it, sincenodesfailed to match in the same position. Mechanism: a predicate keyed on the value's spelling without allowing the key's closing quote. Missed control: the first run had no control arm. Root fix: three literal site-form predicates (P1/P3/P4), each with a live-word control beside it, and the before/after runs pasted above. (b) The lint/toolchain mismatch: its output, mechanism, missed control and root fix are in section 4, and the re-run is green. One finding is filed rather than fixed here:plugin-herdr#16.charlythat models a kube method value is this fixture, and the vocabulary's canonical home is plugin-kube's served#KubeInput, which this body names rather than restates. No second list, alias or compatibility path.CHANGELOGtracked files that name the kube verb, with the three pre-fix sites, both kube-step forms and every live-word control pasted with its exit status. Surviving mentions ofapply/delete/manifestin this repo areCHANGELOG/history and the English words in prose, not kube method words..worktrees/dsh-1117/charly, branched off a freshorigin/main(72292a76919ab9d92099cc5a9289e662a35767b6);git statuswas empty before the edit and is empty after the restore; the commit stages the one literal path (git add -- ':(literal)charly/external_verb_dispatch_test.go'), and no amend-after-push, rebase, force-push ormainpush was used.external_verb_dispatch_test.go:58with exit 1 — at.Fatalfmessage, not a compile error — then the tree was restored byte-identical (sha256 unchanged,cmpexit 0,git statusempty). A fixture that could not fail would have passed that plant.fakeExternalVerb) that is the subject under test — whether the full#Opcrosses asparams_json— not a mock standing in for a live cluster, and the real plugin is never dispatched../scripts/bootstrap-charly.sh) and./bin/charly versionprinted2026.315.1737(section 4); nopackaging:dependency and no gitlink changed..github/workflows/ci.ymlGo job —go test ./charly/..., gofmt, golangci-lint — run on the committed tree (section 4). Nodisposable: truetarget is affected: the diff touches no runtime path, no schema, no authored config and no emitted artifact, so there is no bed a test fixture could turn red.Change classification
Test-only: one Go test fixture. No product code, no schema, no authored config, no emitted artifact, no gitlink or pin.
Breaking change + rollback: none — the fixture's payload moves from a method the plugin no longer serves to one it does, and no consumer-visible surface changes; the rollback is
git revertof this single commit, which restores the previous fixture text and nothing else.Filed issues
charlycheckout inplugin-herdrandpod-herdr(both pinned ateda33c00da9fd40a17787d0d590f07ad9475e435) still carries the pre-fix fixture; the fix is each repo's own pin advance after this lands, not an edit here. Filed rather than fixed because it lives in another repo's gitlink, and this change must not touch a pin.Agent: dsh-1117 (charly session b70509b7-f600-435a-bd9b-a8d99ad1c14e)
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (fully tested and validated)