P1: Remove first-class deployment semantics from cli-guard; preserve generic stepflow #190

Closed
opened 2026-07-05 21:47:55 +00:00 by coilysiren · 3 comments
Owner

Decision

This is a P1 removal, not an open-ended design exercise. cli-guard must stop exposing deployment policy as first-class engine behavior. The generic machinery underneath it remains valuable and must be preserved.

This issue does not delete stepflow. Keep the reusable core: ordered step execution, explicit data/output threading, deterministic planning, and fail-closed resolution of every concrete call. Whether that generic package is extracted later is separate from this urgent cleanup.

Remove from the cli-guard model

  • Compensation / Compensate and automatic reverse-order rollback.
  • Canary, polling windows, and DegradedWhen / HealthyWhen deployment verdicts.
  • Guardfile syntax, resolved action state, dry-run/describe output, documentation, and tests that present those as native cli-guard concepts.
  • Any control path where the guard decides service health or chooses to roll a deployment back.

These policies may be authored later as ordinary pipeline steps or owned by infrastructure scripts. cli-guard should authorize each concrete call, not understand why a caller considers it a health probe or rollback.

Current source evidence

Current main still carries the domain model end to end:

  • http/guardfile/guardfile.go parses Compensation and Canary.
  • http/specverb/action_call.go resolves them and calls stepflow.Run with a canary.
  • pkg/stepflow/stepflow.go owns the reverse compensation stack, health polling, and deployment verdict loop.
  • http/specverb/describe.go advertises rollback and canary behavior as part of the generated product surface.

The original Ward Eco hardcoded-script consumer described in the earlier issue text is no longer present on current Ward main. Treat that as historical motivation, not as a migration dependency for this patch.

Acceptance

  • Generic multi-step sequencing and value threading continue to work and retain focused tests.
  • cli-guard contains no first-class canary, health/degraded verdict, compensation, or automatic rollback API or execution path.
  • Legacy guardfiles using removed deployment nodes fail closed with a clear diagnostic rather than being silently ignored.
  • Dry-run, describe/help, Go API docs, examples, and generated documentation no longer advertise the removed semantics.
  • Repository-wide tests and generation/drift checks pass.
  • Before removal, search current consumers and record any live compatibility impact on the issue; do not resurrect the stale Ward Eco path as a blocker.

Boundary

Preserve stepflow as a generic sequencing primitive. Do not replace this work with a broad package extraction or a new deployment framework. The P1 outcome is the smaller trustworthy cli-guard boundary.

Parent product context: cli-guard#239.

## Decision This is a **P1 removal**, not an open-ended design exercise. cli-guard must stop exposing deployment policy as first-class engine behavior. The generic machinery underneath it remains valuable and must be preserved. This issue does **not** delete stepflow. Keep the reusable core: ordered step execution, explicit data/output threading, deterministic planning, and fail-closed resolution of every concrete call. Whether that generic package is extracted later is separate from this urgent cleanup. ## Remove from the cli-guard model - `Compensation` / `Compensate` and automatic reverse-order rollback. - `Canary`, polling windows, and `DegradedWhen` / `HealthyWhen` deployment verdicts. - Guardfile syntax, resolved action state, dry-run/describe output, documentation, and tests that present those as native cli-guard concepts. - Any control path where the guard decides service health or chooses to roll a deployment back. These policies may be authored later as ordinary pipeline steps or owned by infrastructure scripts. cli-guard should authorize each concrete call, not understand why a caller considers it a health probe or rollback. ## Current source evidence Current main still carries the domain model end to end: - `http/guardfile/guardfile.go` parses `Compensation` and `Canary`. - `http/specverb/action_call.go` resolves them and calls `stepflow.Run` with a canary. - `pkg/stepflow/stepflow.go` owns the reverse compensation stack, health polling, and deployment verdict loop. - `http/specverb/describe.go` advertises rollback and canary behavior as part of the generated product surface. The original Ward Eco hardcoded-script consumer described in the earlier issue text is no longer present on current Ward main. Treat that as historical motivation, not as a migration dependency for this patch. ## Acceptance - Generic multi-step sequencing and value threading continue to work and retain focused tests. - cli-guard contains no first-class canary, health/degraded verdict, compensation, or automatic rollback API or execution path. - Legacy guardfiles using removed deployment nodes fail closed with a clear diagnostic rather than being silently ignored. - Dry-run, describe/help, Go API docs, examples, and generated documentation no longer advertise the removed semantics. - Repository-wide tests and generation/drift checks pass. - Before removal, search current consumers and record any live compatibility impact on the issue; do not resurrect the stale Ward Eco path as a blocker. ## Boundary Preserve stepflow as a generic sequencing primitive. Do not replace this work with a broad package extraction or a new deployment framework. The P1 outcome is the smaller trustworthy cli-guard boundary. Parent product context: cli-guard#239.
coilyco-ops changed title from cli-guard grew an ops-orchestration engine (stepflow health/canary/rollback) it should not own; eco-server spec reaches infra by hardcoded host path to P1: Remove first-class deployment semantics from cli-guard; preserve generic stepflow 2026-07-23 05:54:23 +00:00
Member

Compatibility check: Forgejo repository search found only Ward as a live in-forge consumer. Ward main pins cli-guard v0.103.0 in go.mod; its tracked tree has no Guardfile/KDL consumer configuration, so this removal has no observed live Guardfile migration impact. Downstream Go callers using the removed exported deployment API will need to move that policy into their own pipeline steps.

Compatibility check: Forgejo repository search found only Ward as a live in-forge consumer. Ward main pins cli-guard v0.103.0 in go.mod; its tracked tree has no Guardfile/KDL consumer configuration, so this removal has no observed live Guardfile migration impact. Downstream Go callers using the removed exported deployment API will need to move that policy into their own pipeline steps.
Member

WARDED_WORKFLOW: coilyco-flight-deck/cli-guard#241

details

Review gate: intentionally skipped (temporary Ward default pending brokered QA).

workflow: pull-request-and-merge; review summary: intentionally skipped (temporary Ward default pending brokered QA)

Felt: focused boundary cleanup; the shared sequence core stayed small and direct.

Confidence: high — PR #241 merged after green test, lint, and secrets checks.

Surprise: local MkDocs was unavailable, while repository documentation-link checks passed.

Follow-up: consumers that relied on the removed exported deployment API should own that policy in their pipeline steps.

WARDED_WORKFLOW: https://forgejo.coilysiren.me/coilyco-flight-deck/cli-guard/pulls/241 <details><summary>details</summary> Review gate: intentionally skipped (temporary Ward default pending brokered QA). workflow: pull-request-and-merge; review summary: intentionally skipped (temporary Ward default pending brokered QA) Felt: focused boundary cleanup; the shared sequence core stayed small and direct. Confidence: high — PR #241 merged after green test, lint, and secrets checks. Surprise: local MkDocs was unavailable, while repository documentation-link checks passed. Follow-up: consumers that relied on the removed exported deployment API should own that policy in their pipeline steps. </details>
Member

WARDED_WORKFLOW: reservation-released

release details

Run finished with WARDED_WORKFLOW: https://forgejo.coilysiren.me/coilyco-flight-deck/cli-guard/pulls/241.

ward container reap released container engineer-codex-cli-guard-190 (--harness codex): the terminal outcome supersedes the reservation, so a later redispatch no longer needs --override-reservation.

Outcome summary: coilyco-flight-deck/cli-guard#241

— Codex, via ward agent

<!-- ward-agent-reservation-released --> WARDED_WORKFLOW: reservation-released <details><summary>release details</summary> Run finished with `WARDED_WORKFLOW: https://forgejo.coilysiren.me/coilyco-flight-deck/cli-guard/pulls/241`. `ward container reap` released container `engineer-codex-cli-guard-190` (`--harness codex`): the terminal outcome supersedes the reservation, so a later redispatch no longer needs `--override-reservation`. **Outcome summary:** https://forgejo.coilysiren.me/coilyco-flight-deck/cli-guard/pulls/241 </details> <!-- ward-agent-signature --> — Codex, via `ward agent`
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
coilyco-flight-deck/umbra#190
No description provided.