Repository navigation
Description
Problem
The planner has a group kind behavior that is test-first, and a kind other that has one repeatable verify command and no test-first form. A plan for a manifest with a unit test cannot be written in the form that the review asks for. Two plans met this on 2026-11-02, and each agent wrote the tasks by hand:
- docs(openspec): plan #2950 Add alternatives coverage metrics and alert #3173 (plan for feat(telemetry): Add alternatives coverage metrics and alert #2950): an alert rule plus
promtoolcases, and a dashboard panel plus a query pin. - docs(openspec): plan #2919 stuck-item age metrics and alert #3171 (plan for feat(telemetry): stuck-item age metrics and one alert for the roadmap #2919): the same two shapes.
Proposed change
Add a group kind (for example manifest) whose first task is the failing case or pin and whose verify command fails on the base. The kind is chosen when a path under k8s/, a rule file, a dashboard file or a test fixture is in creates or changes. check_proposal checks that the first task names a file that holds a test or a case, and that the verify command is uv run devops ci test <mirror-path> or a named promtool command that exists in tools.lock.
Acceptance criteria
- A test shows that a manifest group with the case first and a failing verify passes
form_problems. - A test shows that a manifest group with the implementation first is refused.
- The planner prompt names the kind, and the test(roadmap): check the planner prompt against its rules #3210 prompt-vs-rules test passes.
- The golden set has one replay case from docs(openspec): plan #2950 Add alternatives coverage metrics and alert #3173 or docs(openspec): plan #2919 stuck-item age metrics and alert #3171.
Proposed design
Problem statement
The stage planner has no test-first kind for a manifest, a rule file, a dashboard file or a case file. A plan for an alert rule with promtool cases or a dashboard panel with a query pin uses the kind other, which has one repeatable command and no failing-case task. Two agents wrote such tasks by hand on 2026-11-02, and the review refused the form. The change adds the kind manifest, a check of its case-first form and of its verify command, the prompt text, and one replay case.
Acceptance criteria
Requirement: manifest kind in the schema
The stage group schema SHALL accept a group of kind manifest that has a test, an implementation and a verify, and no process.
Scenario: a manifest group validates
- WHEN a group has
kind: manifest, atestthat namesk8s/apps/api/rules_test.yamlin a code span, animplementation, andverify: uv run devops ci test k8s/apps/api - THEN
StageGroup.model_validatereturns a group whosekindismanifestand whoseprocessisNone
Requirement: manifest case first accepted
The stage form check SHALL accept a manifest group whose test names a case path that the group creates.
Scenario: case first with a manifest verify
- WHEN a
manifestgroup listsk8s/apps/api/rules_test.yamlinchangesandcreates, itstestnames that path in a code span, and itsverifyisuv run devops ci test k8s/apps/api - THEN
form_problemsreturns no problem for the group
Requirement: manifest implementation first refused
The stage group schema MUST refuse a manifest group that has no test.
Scenario: no case task
- WHEN a
manifestgroup hastest: nulland holds the implementation task only - THEN the validation error names the kind
manifestand the missingtest
Requirement: case path forces the manifest kind
The stage form check MUST refuse a group of kind other that creates a case path, and MUST name the kind manifest in the problem.
Scenario: an other group creates a promtool case
- WHEN an
othergroup listsk8s/apps/api/rules_test.yamlinchangesandcreates - THEN
form_problemsreturns one problem that namesotherandmanifest
Requirement: manifest verify form
The stage form check MUST refuse a manifest verify command that is not uv run devops ci test followed by a path of the group.
Scenario: a devops command that runs no case
- WHEN a
manifestgroup givesuv run devops ci mutate k8s/apps/apias its verify command - THEN
form_problemsreturns one problem that names the command and theci testform
Requirement: planner prompt names the manifest kind
The planner prompt SHALL name the manifest kind, its first-task rule and its verify rule.
Scenario: prompt and rules agree
- WHEN the prompt-vs-rules test reads the prompt and the names of
GroupKind - THEN the test finds
manifestin both and passes
Requirement: golden replay case from a hand-written plan
The golden set MUST hold one replay case from #3173 whose manifest group creates no case path.
Scenario: the new case replays
- WHEN the replay runs on the whole golden set
- THEN the report lists the new case as caught by the
pathsgate and the replay exits 0
Existing Tool Considered
No alternatives check has run for this issue. No open, maintained tool covers the need: the rule is a project-internal form of the devops-cli stage plan, and the planner, the kind table and the replay are devops-cli code. The change builds its own code. The written cost is about 70k tokens to build, for about 300 changed lines and 7 tests. The cost to keep and fix it is about 15k tokens a year, when the k8s/ layout or the shell policy changes. The elapsed time is about 1 working day, in one pull request.
Key questions
- Which name and value does the new group kind take?: The kind is
manifest, added toGroupKind. It names the artifact that the group changes, asbehaviornames a behavior. (best practice) [sources: src/devops_cli/roadmap/stage_change.py, tests/roadmap/test_roadmap_stage_kind.py]- Chosen:
manifest. It names the artifact that the group changes, asbehaviornames a behavior. - Rejected:
test-first. It names the form, not the artifact, so a second test-first form needs a new kind name. - Rejected:
k8s. It is too narrow: a dashboard file or a rule file is no Kubernetes manifest.
- Chosen:
- Which fields does a
manifestgroup carry?: The fields ofbehavior.testholds the case task,implementationholds the work,verifyholds the command, andprocessis absent.group_textrenders the case task first withfails on the base, then the implementation. (best practice) [sources: src/devops_cli/roadmap/stage_change.py, tests/roadmap/test_roadmap_stage_kind.py]- Chosen: reuse
testandverify.group_textalready renders atestfirst withfails on the base, so the kind needs no new render rule. - Rejected: a new
casefield. The prompt, the schema andgroup_textwould carry two names for one task. - Rejected: the
processfield.processrenders a manual check and no failing command.
- Chosen: reuse
- Where do the rules of the new kind live?: The shape is a pydantic rule of
StageGroup: amanifestgroup has atestand averify, and noprocess. The case path rule and the verify form rule are checks ofform_problemsinsrc/devops_cli/roadmap/stage_form.py, whichcheck_proposalcalls. (best practice) [sources: src/devops_cli/roadmap/stage_change.py, src/devops_cli/roadmap/stage_form.py, openspec/changes/archive/2026-10-30-2772-stage-group-files/design.md]- Chosen: the schema for the shape,
form_problemsfor the paths. The shape joins the rules ofbehaviorandother, and the path rules join the path rules ofform_problems. - Rejected: the schema only. A case path rule names the problem in the text of the reply, and the existing path rules live in
form_problems. - Rejected:
form_problemsonly. A missingtestwould reach the check as a null field, and the client already returns a schema violation in one retry.
- Chosen: the schema for the shape,
- What makes the first task of a
manifestgroup a case task?: Thetesttext names, in a code span, a path that is in the group'screatesand ends with_test.yaml,_test.yml,_test.jsonor.test.json, or sits under atestdata/folder. A Python test module is no case path, so abehaviorgroup is never forced tomanifest. (best practice) [sources: src/devops_cli/roadmap/stage_form.py, openspec/changes/archive/2026-11-01-3010-stage-refuses-missing-paths/design.md, tests/roadmap/test_roadmap_stage_form.py]- Chosen: a case path in
creates, named in the test text. The first task creates the case, so the check reads the task and the group, and it needs no tree. - Rejected: a path under
tests/. Every Python test module would count, and abehaviorgroup would break. - Rejected: a file that exists at the base. The case is new, so the file is absent.
- Chosen: a case path in
- Which verify commands does a
manifestgroup accept?:uv run devops ci testfollowed by one path of the group or its folder. The check refuses every other command, and the problem names theci testform. Apromtoolcommand is out of this change and goes to a new issue. (best practice) [sources: src/devops_cli/roadmap/stage_form.py, src/devops_cli/roadmap/implement_shell_policy.py, docs/TESTING.md]- Chosen:
uv run devops ci testonly. The step runs the command, and the command takes a path of the group. - Rejected: any
uv run devopscommand. The group could run a command that covers no case. - Rejected: a
promtoolcommand pinned by a tools lock. The repository holds no tools lock file, and the step's shell runs nopromtool. The part is deferred.
- Chosen:
- Which file pins a tool that the step runs?: No tools lock file exists at the staging commit. The runner image holds the tools that
RUNNER_TOOLSnames insrc/devops_cli/roadmap/runner_tools.py, and the step's shell runs only the programs ofSHELL_PROGRAMSinsrc/devops_cli/roadmap/implement_shell_policy.py, which holds nopromtool. [sources: src/devops_cli/roadmap/runner_tools.py, src/devops_cli/roadmap/implement_shell_policy.py, docs/adr/0005-review-findings-come-from-tools-not-models.md] - Does the check run the verify command?: No.
form_problemsis a pure function of the reply. The step shows the failure on the base when it runs the first task, and the replay reads no code and no git. (best practice) [sources: openspec/changes/archive/2026-11-01-3010-stage-refuses-missing-paths/design.md, src/devops_cli/roadmap/stage_form.py, docs/ROADMAP_WORKFLOW.md:275]- Chosen: a pure check. The stage job has no sandbox, and the replay reads no code and no git.
- Rejected: run the command in the stage job. The stage job has no sandbox and no mirror of the repository.
- Which test compares the prompt with the kinds, and what must change there?:
tests/roadmap/test_roadmap_stage_prompt_rules.pyreads the kinds fromGroupKind. Its regex matches exactly two names, so it must read the names as a list.tests/roadmap/test_roadmap_stage_kind.pypins the schema messageInput should be 'behavior' or 'other', so that text must name three kinds. [sources: tests/roadmap/test_roadmap_stage_prompt_rules.py, tests/roadmap/test_roadmap_stage_kind.py] - Which plan supplies the replay case?: The plan of docs(openspec): plan #2950 Add alternatives coverage metrics and alert #3173. The case holds a
manifestgroup that names no case path increates, so the new check catches it asverify_formunder thepathsgate. (best practice) [sources: tests/roadmap/test_roadmap_stage_eval_run.py, docs/ROADMAP_WORKFLOW.md:275]- Chosen: docs(openspec): plan #2950 Add alternatives coverage metrics and alert #3173. It holds an alert rule with
promtoolcases and a dashboard panel with a query pin, the two shapes of the kind. - Rejected: docs(openspec): plan #2919 stuck-item age metrics and alert #3171. It holds the same two shapes, so one case covers the kind.
- Rejected: a new plan. The case must come from a plan that an agent wrote before the kind existed.
- Chosen: docs(openspec): plan #2950 Add alternatives coverage metrics and alert #3173. It holds an alert rule with
- Does the change need the replay score before and after?: Yes. The pull request states the score of one named model on the whole golden set before and after the change, because it changes the stage prompt and a check of
check_proposal. [sources: docs/ROADMAP_WORKFLOW.md:276] - Does the new kind replace
other?: No.otherkeeps one task with averifyor aprocessand no test-first form. Only a group that creates a case path must takemanifest. (best practice) [sources: src/devops_cli/roadmap/stage_change.py, tests/roadmap/test_roadmap_stage_kind.py]- Chosen: keep both kinds. Many
othergroups change a manifest with no test, and the manifest form needs a case. - Rejected: replace
other. It would refuse every group with no test.
- Chosen: keep both kinds. Many
Fit
Fits in one pull request.
Suspected block
None.
Dependencies
None.
Alternatives check of 2026-11-06: none.
Tool: none found.
Activity
devops-cli-service commentedon Nov 2, 2026
Intake placed this item to the backlog: intake puts every new item in the backlog. A person plans the milestones.
featprefix of the title gives the type.(roadmap)scope of the title gives the scope.Two plans already required hand-written tasks, but no user-facing break or security risk is present.It removes a recurring manual workaround for manifest and alert-rule plans.Requires a new kind, check_proposal rules, prompt update, tests, and a golden replay case.Both deal with test-first forms in the stage plan, but the candidate adds a new group kind while #3042 enforces fail-to-pass execution for the existing behavior kind.devops-cli-service commentedon Nov 2, 2026
Status set to Ready at 8b47ae2 (see proposed design in issue body).
devops-cli-service commentedon Nov 2, 2026
The stage job returned the item to New. The premise of the issue does not hold at the staging commit, so the job planned no change and opened no pull request.
Evidence:
The path
tools.lockis no file of the staging commit. No commit in the history deleted or renamed it.13 remaining items
devops-cli-service commentedon Nov 7, 2026
The runner Job devops-cli-runner-20261107-131652-e1ae ended: succeeded.
Image digest: sha256:ff3526a65853e025ecb4c2c4ca2f78c6e582c29342b762db525e35b57ab5443c
The last lines of its log:
feat(roadmap): Add a test-first manifest kind to the stage plan
feat(roadmap): Add a test-first manifest kind to the stage plan
feat(roadmap): Add a test-first manifest kind to the stage plan
feat(roadmap): Add a test-first manifest kind to the stage plan
feat(roadmap): add a test-first manifest kind to the stage plan
devops-cli-service commentedon Nov 7, 2026
Released in v0.84.0: https://github.com/dan-petty/devops-cli/releases/tag/v0.84.0
devops-cli-service commentedon Nov 7, 2026
Live since 2026-11-07 22:00 UTC