Repository navigation
feat(schema): carry the StepContract plugin_paths flag onto the wire (#1131) - #505
Merged
Merged
Conversation
A `class:step` plugin's StepContract is DECLARED by the plugin and ACTED ON by the host, so every field has to survive the capability build. `PluginPaths` (opencharly/charly#1131) is the opt-in that makes the host inject the connected plugin set into a step's input; without it in this conversion, a plugin that declares it would be invisible to the very code the flag exists for. The test drives the real `BuildCapabilitiesWithRequires` path and round-trips the result through protobuf, so it fails if the field is dropped here, and it asserts the contract's other fields did not drift with it. Adopts `github.com/opencharly/spec v0.2026317.1755` (opencharly/spec#308, merged and tagged), which is where the field is defined. Refs opencharly/charly#1131 Agent: charly-plugins Assisted-by: DeepSeek Harness deepseek-v4.1-flash (fully tested and validated)
Review — PASSHead SHA: Security screen: PASS (diff matches the stated one-field conversion; no secrets, no scope creep, no guardrail or supply-chain weakening — the Verdict: PASS ollama-cloud/deepseek-v4.1-flash — action-review. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A
class:stepplugin'sStepContractis DECLARED by the plugin and acted on by the host: the host is what readsScope,Venue,GateandEmitsoff the declared capability. So every field has to survive the capability build, or a plugin declares a capability nobody can see.PluginPaths— the opt-in added byopencharly/spec#308foropencharly/charly#1131— is the one that makes the host inject the connected plugin set into this step's input. Dropping it in this conversion is not a cosmetic loss: the plugin would declare the flag, the host would never receive it, and the step would go back to guessing where its plugin binaries are.This PR is that one conversion plus its proof:
schema.go—BuildCapabilitiesWithRequirescarriesPluginPathsintopb.StepContract, next toEmits, for the same reason: the host acts on it.step_contract_test.go(new) — drives the realBuildCapabilitiesWithRequirespath and round-trips the result through protobuf, so it fails if the field is dropped and also pins that the contract's other fields did not drift with it.go.mod/go.sum— adoptgithub.com/opencharly/spec v0.2026317.1755(spec#308, merged and tagged), which is where the field is defined.Head
fa4eb69c381e786f34a2ec426e78cebde249196aHow tested
Change class: Contract / library module. This repo ships no
disposable: truetarget, so no bed CAN exist here; per the R10 matrix for that class the gate is the repo's own committed CI green on the committed tree, genuinely EXECUTING the changed path. Every run below is on the tree that is pushed.The
GOTOOLCHAIN=go1.26.8on the lint is this repo's own documented pin (go.moddeclaresgo 1.26.8): golangci-lint v2.13.2's embedded type-checker reads export-data version 4, while a newer local toolchain writes version 5 and the lint then fails in an unrelated package withexport data version 5 is greater than maximum supported version 4. Under the declared toolchain the run is clean.The test executes the changed path, and dies without it:
Mutation proof —
PluginPaths: c.StepContract.PluginPathsremoved from the conversion, then restored (the tree is clean at the head above):The "no disposable target" premise, executed on the head (the class gate requires it proven, not asserted):
Where the behaviour is observable at a CONSUMER's live boundary — named here because the bed rides the consumer change, never a library PR:
opencharly/plugin-deploy-firecracker'scheck-plugin-tree-vm(a disposablevm:bed) is the bed that carries this flag end to end, and it is run by that plugin's own PR after this one is released.opencharly/plugin-firecracker#11andopencharly/layer-fireactions-runner#2are the two consumer PRs their beds unblock.Rulebook compliance
git-workflow,go,go-quality,plugin,check,disposable,strict-policy,root-cause-analyzer, plus this repo's ownsdk/AGENTS.md, whose "schema and wire types are NOT here — bump therequire" rule is exactly the shape of this PR.gofmt,vetandgolangci-lintare green with zero findings, so nothing needed an RCA or a filing. The one environment mismatch encountered (the newer-toolchain export-data error) is this repo's own documented condition, cured by running the lint under the toolchaingo.moddeclares — pasted above.BuildCapabilitiesWithRequires); the flag and the wire field come fromspec, so there is no second spelling of the contract in this repo.deploykit/loaderkit/kitstay untouched — the mechanism packages acquire no copy of the capability build.spec.git statusread before any git action; the change is committed oncharly-plugins/leg-bofforigin/main(e44f0ce); no force-push, no amend, no submodule touched.pb.StepContract— is validated at its own boundary by a protobuf marshal/unmarshal round trip inside the same test, not by an in-memory field read.charlyand plugin consumers carry their own R9 proof.disposable: truetarget exists here. The live-boundary bed rides the consumer PR named under How tested.Change classification
requirebump).PluginPathsfalse is the proto3 zero value). Rollback isgit revert, which returns the module to specv0.2026317.703.specis merged and tagged (v0.2026317.1755);charlyadopts the same tag before it populates or injects the field; the plugin and its bed come after that.Agent: charly-plugins
Assisted-by: DeepSeek Harness deepseek-v4.1-flash (fully tested and validated)