fix: unstrand ward from cli-guard, and honor the burndown block (2 of 3 doctor failures) #1121

Merged
coilyco-ops merged 2 commits from fix/migrate-off-cli-guard-dispatch into main 2026-07-12 00:29:20 +00:00
Member

Unblocks the dev-base image. Takes ward doctor against the aos bundle from 3 failures to 1. aos is canonical; ward adapts to it.

1. fix(deps) - own the issue types, move to cli-guard v0.94.0

cli-guard removed cli/dispatch (05e8b78, 2026-07-09) and added singular guardfile role nodes to fleetconfig the next day (f6063aa). ward still imported the removed package, so it was stranded on a pre-removal pseudo-version and could not reach the fleetconfig fix. No cli-guard version carries both.

cli-guard parses a reference (pkg/issueref) and has no concept of an issue. The issue, and which forge it resolves against, are ward's domain, so Platform / IssueRef / Issue now live in cmd/ward; ParseIssueRef delegates the short, bare, and Forgejo-URL forms to issueref.Parse and matches GitHub first (issueref does not know it).

The removed package was the only compile error across the whole 0.85 -> 0.94 range.

-> FAIL fleet: role "engineer" body: unknown node "guardfile" becomes PASS fleet.

2. feat(smart-defaults) - honor the burndown block (ward#1105)

aos authors a block ward had no concept of, so doctor failed the whole bundle on repos body: unknown node "burndown".

burndown default=#true {
    repo "coilyco-flight-deck/infrastructure" #false
}

default sets the posture, each repo overrides it, and the director honors it where it expands an --org into repo slugs - so an excluded repo is dropped from the scope, not parsed and silently ignored.

Two things worth calling out:

  • An absent burndown block excludes nothing. The zero value of a bool is false, so falling through to the default would have silently drained the director's entire scope on every bundle predating the block. My first cut had exactly that bug; the existing suite caught it. A burndownConfigured flag fixes it and a test pins it.
  • Booleans must be the KDL v2 spelling (#true / #false). A bare true lexes as an identifier and fails the document - the same bug that took the aos bundle down (aos#471) - so the parser rejects non-bools rather than coercing.

Verification

All inside agentic-os:latest:

  • go build / go vet - clean
  • go test ./... - exit 0
  • golangci-lint run ./... - 0 issues
  • new burndown tests: default, inverted default, absent block, bare-boolean rejection, unknown node, duplicate, missing default

What is left before the image publishes

ward doctor is down to two, and both need a call from Kai (see ward#1120):

  1. agent-reservation-ttl 1h must exceed role "engineer" execution-time-limit 90m - newly surfaced, it was hidden behind the burndown parse error. aos sets the 1h TTL; ward's embedded engineer preset sets the 90m limit. One of the two has to move.
  2. guardfile base-url "git.example.com/api/v1" still looks like a placeholder - ops.forgejo.kdl is the baked default embedded into ward's release, so its example values are correct (ward must not ship coilyco config). doctor is checking the pre-meld layer instead of the melded surface. Do not rewire ward.bundle.kdl or meld real values into ops.forgejo.kdl - either would embed the deployment into the product.
Unblocks the dev-base image. Takes `ward doctor` against the aos bundle from **3 failures to 1**. aos is canonical; ward adapts to it. ## 1. `fix(deps)` - own the issue types, move to cli-guard v0.94.0 cli-guard removed `cli/dispatch` (`05e8b78`, **2026-07-09**) and added singular `guardfile` role nodes to fleetconfig the **next day** (`f6063aa`). ward still imported the removed package, so it was stranded on a pre-removal pseudo-version and could not reach the fleetconfig fix. **No cli-guard version carries both.** cli-guard parses a **reference** (`pkg/issueref`) and has no concept of an **issue**. The issue, and which forge it resolves against, are ward's domain, so `Platform` / `IssueRef` / `Issue` now live in `cmd/ward`; `ParseIssueRef` delegates the short, bare, and Forgejo-URL forms to `issueref.Parse` and matches GitHub first (issueref does not know it). The removed package was the **only** compile error across the whole 0.85 -> 0.94 range. -> `FAIL fleet: role "engineer" body: unknown node "guardfile"` becomes **`PASS fleet`**. ## 2. `feat(smart-defaults)` - honor the burndown block (ward#1105) aos authors a block ward had no concept of, so doctor failed the whole bundle on `repos body: unknown node "burndown"`. ```kdl burndown default=#true { repo "coilyco-flight-deck/infrastructure" #false } ``` `default` sets the posture, each `repo` overrides it, and the **director honors it** where it expands an `--org` into repo slugs - so an excluded repo is dropped from the scope, not parsed and silently ignored. Two things worth calling out: * **An absent burndown block excludes nothing.** The zero value of a bool is `false`, so falling through to the default would have silently drained the director's entire scope on every bundle predating the block. My first cut had exactly that bug; the existing suite caught it. A `burndownConfigured` flag fixes it and a test pins it. * Booleans must be the **KDL v2** spelling (`#true` / `#false`). A bare `true` lexes as an identifier and fails the document - the same bug that took the aos bundle down (aos#471) - so the parser rejects non-bools rather than coercing. ## Verification All inside `agentic-os:latest`: * `go build` / `go vet` - clean * `go test ./...` - **exit 0** * `golangci-lint run ./...` - **0 issues** * new burndown tests: default, inverted default, absent block, bare-boolean rejection, unknown node, duplicate, missing default ## What is left before the image publishes `ward doctor` is down to two, and **both need a call from Kai** (see ward#1120): 1. `agent-reservation-ttl 1h must exceed role "engineer" execution-time-limit 90m` - newly surfaced, it was hidden behind the burndown parse error. aos sets the 1h TTL; ward's embedded engineer preset sets the 90m limit. One of the two has to move. 2. `guardfile base-url "git.example.com/api/v1" still looks like a placeholder` - `ops.forgejo.kdl` is the **baked default embedded into ward's release**, so its example values are *correct* (ward must not ship coilyco config). doctor is checking the pre-meld layer instead of the melded surface. **Do not** rewire `ward.bundle.kdl` or meld real values into `ops.forgejo.kdl` - either would embed the deployment into the product.
fix(deps): own the issue types so ward can move to cli-guard v0.94.0
All checks were successful
test / test (pull_request) Successful in 30s
4c8d9d0bc8
cli-guard removed cli/dispatch as a legacy subsystem (05e8b78, 2026-07-09)
and added singular `guardfile` role nodes to fleetconfig the next day
(f6063aa). ward still imported the removed package, so it was stranded on a
pre-removal pseudo-version and could not reach the fleetconfig fix. No
cli-guard version carries both. That stranding is what fails `ward doctor`
against the aos bundle, which gates the dev-base image build (aos#452).

cli-guard parses a reference (an argument shape, pkg/issueref) and has no
concept of an issue. The issue itself, and which forge it resolves against,
are ward domain, so Platform, IssueRef, and Issue now live in cmd/ward, and
ParseIssueRef delegates the short, bare, and Forgejo-URL forms to cli-guard
issueref.Parse. GitHub is matched first because issueref.Parse does not know
it.

Bumping cli-guard to v0.94.0 breaks nothing else: the removed package was the
only compile error across the whole 0.85 to 0.94 range.

ward doctor against aos main goes from `FAIL fleet: role "engineer" body:
unknown node "guardfile"` to `PASS fleet`. Two doctor failures remain before
the image can publish (burndown, ward#1105, and the ops base-url placeholder
check), tracked in ward#1120.

Refs ward#1120, aos#452.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
coilyco-ops changed title from fix(deps): own the issue types so ward can move to cli-guard v0.94.0 to fix: unstrand ward from cli-guard, and honor the burndown block (2 of 3 doctor failures) 2026-07-12 00:20:26 +00:00
feat(smart-defaults): honor the burndown repo-exclusion block in repos.kdl
All checks were successful
test / test (pull_request) Successful in 35s
4f7adc196e
aos authors a burndown block that ward had no concept of, so `ward doctor`
failed the whole bundle with `repos body: unknown node "burndown"`, which
gates the dev-base image build. aos is canonical, so ward learns the node.

    burndown default=#true {
        repo "coilyco-flight-deck/infrastructure" #false
    }

`default` sets the fleet-wide posture and each `repo` overrides it. The
director honors it where it expands an --org into repo slugs, so an excluded
repo is dropped from the burndown scope with a note on stderr rather than
being parsed and silently ignored.

An absent burndown block excludes nothing. The zero value of a bool is false,
so falling through to the default would have silently drained the director's
entire scope on every bundle that predates the block. A burndownConfigured
flag keeps that from happening, and a test pins it.

Booleans must be the KDL v2 spelling (#true / #false). A bare true / false
lexes as an identifier and fails the document, which is exactly the bug that
took the aos bundle down (aos#471), so the parser rejects anything that is not
a real bool rather than coercing it.

Refs ward#1105, ward#1120, aos#452.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign in to join this conversation.
No description provided.