Add rig-tier entry point for the cairn-librarian formula#44
Merged
Conversation
…refs crn-6ef7) TestLibrarianRigFormulaHasRigTierDefaults and TestLibrarianRigFormulaHasSameStepsAsLibrarian assert that a new mol-cairn-librarian-rig.formula.toml exists with phase="vapor", vars.tier.default="rig", vars.rig.default="cairn", and steps identical to mol-cairn-librarian.formula.toml. Both fail RED: the file doesn't exist yet.
Cooldown/condition order dispatch carries vars=nil -- an order's [params] only validate presence, they cannot supply values (only webhook/manual dispatch carry vars). Under vars=nil, mol-cairn-librarian falls back to its own defaults (tier="global"), the fleet-wide mayor-owned singleton sweep, which is the wrong owner for a cairn-rig cooldown order. mol-cairn-librarian-rig is a thin wrapper: identical steps, but var defaults fixed to tier="rig", rig="cairn". bd's formula system has no alias/extends mechanism, so this is a full structural duplicate rather than a reference; formulas_test.go's TestLibrarianRigFormulaHasSameStepsAsLibrarian guards the two files from drifting apart. Consumer: packs/cairn-loop-orders/orders/cairn-librarian-rig-cooldown.toml (gc-management repo, pack-author territory) -- pointing that order's formula= at this file and flipping enabled=true is explicitly out of scope here; see that pack's own README activation checklist.
Records the 7-criterion gate evaluation for the new mol-cairn-librarian-rig formula, including the bounded self-rebase required to clear divergence from main after the sibling deploy (crn-ju4o) squash-merged ahead of it.
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
Adds
mol-cairn-librarian-rig, a thin rig-tier wrapper around the existingmol-cairn-librarianformula. It has identical steps to the base formula,but its variable defaults are fixed to
tier="rig",rig="cairn"insteadof the base's fleet-wide
tier="global"default.This exists because cooldown/condition-triggered order dispatch always
carries
vars=nil— an order's[params]only validate that a variable ispresent, they can't supply a value (only webhook/manual dispatch can).
Under
vars=nil,mol-cairn-librarianwould fall back to its owntier="global"default, which is the fleet-wide, mayor-owned singletonsweep — the wrong owner for a cairn-rig cooldown order. This new formula
supplies rig-tier defaults instead, so a bare
bd mol pour mol-cairn-librarian-rig(no--varflags) already resolves to the correcttier/rig.
bd's formula system has no alias/extends/include mechanism, so this is afull structural duplicate of the base formula's steps rather than a
reference to it. A new test (
TestLibrarianRigFormulaHasSameStepsAsLibrarian)guards the two formulas from drifting apart.
Wiring an actual order to use this formula (flipping a pack's
formula=pointer) is a separate, out-of-scope change that lives in a different repo.
Test plan
go build ./...gofmt -l .(clean)go vet ./...golangci-lint run ./...(0 issues)go test ./... -race -count=1(all packages pass)TestLibrarianRigFormulaHasRigTierDefaultsandTestLibrarianRigFormulaHasSameStepsAsLibrarianpassmake formulaslinks the new formula cleanly;bd formula show mol-cairn-librarian-rigparses and renders correctly