Repository navigation
fix: what an operation's run() works through, the house hands it — a plugin's only entity by default, and judged when the code lands - #148
Merged
rodrigoteamx merged 5 commits intoOct 8, 2026
Conversation
…plugin's only entity by default, and judged when the code lands (greenhouse evidence/1154)
This was referenced Oct 8, 2026
…t keeps a secret)
rodrigoteamx
added a commit
that referenced
this pull request
Oct 8, 2026
rodrigoteamx
added a commit
that referenced
this pull request
Oct 8, 2026
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.
Found in the reference run: stage I went red with the real resident, and one of its two causes is this.
What happened
The resident scaffolded four operations of a plugin with one entity, naming the entity in none, and wrote three
run()againstMilpa\Data\RepositoryInterface. Every judge passed — syntax, namespace, static conformance — the trials were promoted, the house booted. The battery's first call answered: «Service "Milpa\Data\RepositoryInterface" is not registered in the container».Reproduced without a model in a lab house, on devtools 0.44.0: the same walk lands green and the call fails the same way. The operation's own contract says its state lives in the store of its plugin's entity; its
run()could not reach it.Why
RepositoryInterfaceis registered by nobody, and should not be: there is one repository per entity, under the idmake entitygives it. What hands it torun()is the entry that lists the operation in its plugin'soperations().make what=operationwrote that entry with the entity only whenentity=was given; without it, the entry resolved by class and the scaffold said nothing about state. And nothing asked, when a body landed, whether its entry could hand it what it takes — the house only found out at the first call.The house already has this rule for a controller a route names (it is built through the container before it lands). An operation the catalogue offers had no such judge.
What changes
The property: what an operation's
run()works through, the house hands it — judged when the code lands, not at its first call.run()receives, without being named. With several, none is guessed: the scaffold says there are several and thatentity=names one. With none, nothing is wired, as before.implementandeditask the booted house. For a class that is an operation the house offers, the entry that lists it is asked for each thingrun()takes — the house's own act, in the same child process that already builds controllers, without runningrun(). If it cannot hand one, the body does not land and the original survives byte for byte.{find, replace}of the entry — the whole entry, because the resolver alone is the same in every one — then the sameimplementagain. For anything else nobody registered: its type, registered inboot().run()works through went unjudged.makecontract and the governed-authoring skill say how an operation reaches a repository.What it does not do
run(): whatrun()takes is found by type, so one entry hands one. The scaffold does not guess between entities and the refusal names them.DeclaredOperation::from()returns; a test pins that shape against the installed milpa/command, so a change there goes red here.Checked