Repository navigation
Description
Problem
Two kinds of neighbour are not in the planner's context, and both gave a blocker in the plan reviews of 2026-11-02.
- The failure taxonomy (feat(roadmap): classify a failure and name its class in the stop #3195). A plan that changes retry, review or stop behavior must say how a failure is classed. Evidence: docs(openspec): plan #3060 plan model tier ladder for retries #3225 (the plan advances a ladder on "a provider error", which
failure.py:74-75maps toretry; the XML 400 that motivates it is class parser), docs(openspec): plan #2916 One function decides draft readiness #3170 (a new failure phrase falls intoci_infrawith actionretryby default), docs(openspec): plan #3049 Plan the review gate before the ready mark #3183 (three review stop phrases all giveci_infra/retry, which cannot clear a finding). - The capabilities of the runner pod. A plan whose feature needs a tool or privilege that the runner image or pod lacks is not caught. Evidence: docs(openspec): plan #3049 Plan the review gate before the ready mark #3183 (plan feat(roadmap): Run
devops reviewon the diff before marking PR ready #3049) asks the implement job to rundevops reviewbefore the ready mark. The runner image installs only git, ca-certificates, curl and jq (Dockerfile:53-58), andNOT_IN_RUNNERinrunner_tools.pylists bwrap, semgrep, gitleaks, osv-scanner, kube-linter and trivy (all True). The review prints "The review tools did not run" and exits 1. The pod drops all capabilities and uses the RuntimeDefault seccomp profile (feat(roadmap): run the implement agent shell in a real sandbox #2695). Refine set the item Ready with "Dependencies: None" although feat(roadmap): the implement agent can use the project's development tools #3041 and feat(roadmap): run the implement agent shell in a real sandbox #2695 are open.
Proposed change
When the plan cites retry, review, stop, tier or failure words, add failure.py (class table and rules) to the context. When the plan cites a command or a tool name, add the runner capability facts: the image tools, NOT_IN_RUNNER, and the pod security settings, each read from the repository (not copied). The prompt tells the planner to state both in ## Feasibility, and the gate refuses a plan whose Feasibility names no runner capability for a plan that adds a command to the Job.
Acceptance criteria
- A test shows that a plan that cites
retrygets the class table in its context. - A test shows that a plan that adds
devops reviewto the Job getsNOT_IN_RUNNERand the image tool list, and is refused without a Feasibility line that names them. - The facts are derived from
failure.py,runner_tools.pyand the Dockerfile at the staged commit (a test fails if a source moves). - A replay case from docs(openspec): plan #3049 Plan the review gate before the ready mark #3183 or docs(openspec): plan #3060 plan model tier ladder for retries #3225 is in the golden set.
Related: #3195, #3238, #3246, #3253.
Proposed design
Problem statement
The planner lacks the failure classes and the runner capabilities that a plan depends on. Plans can add commands that the runner image cannot run, and reviews then block them. The change adds repository-derived facts to the staging context and a gate that checks the Feasibility section.
Acceptance criteria
Requirement: Failure taxonomy in staging context
Staging context SHALL include the failure class table and action rules from failure.py when the plan cites retry, review, stop, tier or failure.
Scenario: Retry plan gets class table
- WHEN A staging run gets a plan that cites
retry. - THEN The planner context contains the class table and
ACTION_BY_CLASSrules read fromfailure.pyat the staged commit.
Requirement: Runner capability facts in staging context
Staging context SHALL include the runner image tools, NOT_IN_RUNNER entries and pod security settings when the plan cites a command or tool name.
Scenario: Review command gets runner facts
- WHEN A staging run gets a plan that adds
devops reviewto the Job. - THEN The planner context contains the image tool list, the
NOT_IN_RUNNERentry for each review tool and the pod security settings.
Requirement: Repository-derived facts
The context builder MUST read the failure classes, runner tools and pod security settings from repository files at the staged commit. It MUST NOT copy them into a static prompt.
Scenario: Source move fails the test
- WHEN A test moves or renames
failure.py,runner_tools.pyor the pod security manifest. - THEN The context builder test fails and names the moved source.
Requirement: Planner Feasibility instruction
The planner prompt SHALL tell the planner to state each needed failure class and runner capability in ## Feasibility.
Scenario: Prompt names Feasibility
- WHEN The staging prompt includes failure or runner capability facts.
- THEN The prompt contains the instruction to state those facts in
## Feasibility.
Requirement: Gate refuses unsupported Job command
The staging gate SHALL refuse a plan that adds a command to the Job when its ## Feasibility section names no runner capability for that command.
Scenario: Unsupported Job command is refused
- WHEN A plan adds
devops reviewto the Job and its Feasibility section names no review tool fromNOT_IN_RUNNER. - THEN The gate returns a refusal that names
devops reviewand the missing runner capability.
Requirement: Gate refuses unsupported verify program
The staging gate SHALL refuse a plan whose task verify runs a NOT_IN_RUNNER program without a ## Feasibility line that names its runner capability.
Scenario: Helm verify is refused
- WHEN A plan has a task verify that runs
helm templateand its Feasibility section names no runner capability forhelm. - THEN The gate returns a refusal that names
helmand the missing runner capability.
Requirement: Docker verify is refused
The staging gate SHALL refuse a medium-effort plan whose task verify runs docker without a ## Feasibility line that names its runner capability.
Scenario: Medium-effort Docker verify is refused
- WHEN A medium-effort plan has a task verify that runs
docker buildand its Feasibility section names no runner capability fordocker. - THEN The gate returns a refusal that names
dockerand the missing runner capability.
Requirement: Replay case in golden set
The golden set MUST include one replay case from #3183 or #3225 that exercises the failure taxonomy and runner capability context.
Scenario: Replay case runs offline
- WHEN The golden-set test runs the docs(openspec): plan #3049 Plan the review gate before the ready mark #3183 or docs(openspec): plan #3060 plan model tier ladder for retries #3225 replay case.
- THEN The case passes with the expected context facts and the expected gate result.
Existing Tool Considered
No alternatives check has run. No open, maintained tool covers this repository-specific need. The change builds its own code. The written cost is about 40,000 tokens to build, keep and fix it, and 2 elapsed days.
Key questions
- Which failure facts go into the staging context, and how does the builder source them?: Include the class table and
ACTION_BY_CLASSrules fromsrc/devops_cli/roadmap/failure.pyat the staged commit. Read them from the file. Do not copy them into the prompt. (best practice) [sources: src/devops_cli/roadmap/failure.py:74, docs/ROADMAP_WORKFLOW.md:134, docs/ROADMAP_WORKFLOW.md:149]- Chosen: Read
failure.pyat the staged commit. This keeps the class table and actions aligned with the code that classifies stops. - Rejected: Copy a static class table into the prompt. This drifts when
failure.pychanges and fails the source-move test. - Rejected: Always include the full file. This spends context on plans that do not touch failure behavior.
- Chosen: Read
- Which runner capability facts go into the staging context, and how does the builder source them?: Include the image tools from the Dockerfile and
RUNNER_TOOLS, theNOT_IN_RUNNERentries and the pod security settings. Read each from its repository file at the staged commit. (best practice) [sources: src/devops_cli/roadmap/runner_tools.py:186, src/devops_cli/roadmap/runner_tools.py:193, k8s/README.md:643, tests/roadmap/test_roadmap_runner_tools.py]- Chosen: Read Dockerfile,
runner_tools.pyand the pod manifest. This keeps capability facts aligned with the image, the exclusion table and the pod settings. - Rejected: Copy a capability list into the prompt. This drifts when the image or pod settings change.
- Rejected: Use only
NOT_IN_RUNNER. This misses image tools and pod security settings that a plan can depend on.
- Chosen: Read Dockerfile,
- What triggers the failure taxonomy and runner capability context?: Include the failure taxonomy when the item text or plan draft cites retry, review, stop, tier or failure words. Include runner capability facts when the same text cites a command or tool name. Keep both out otherwise. (best practice) [sources: src/devops_cli/roadmap/failure.py, src/devops_cli/roadmap/runner_tools.py, docs/ROADMAP_WORKFLOW.md:134]
- Chosen: Keyword-triggered context. This adds the facts only to plans that depend on them and keeps the token budget.
- Rejected: Always include both fact sets. This spends context on every plan and raises token cost.
- Rejected: Let the planner request facts. The planner does not know what it lacks before it writes the plan.
- How does the gate detect commands and verify programs that need runner capabilities?: Parse the plan's Job command lines and task verify lines. Check the first program word against
NOT_IN_RUNNERand the image tool list. Require the## Feasibilitysection to name the matching capability. (best practice) [sources: CONTEXT.md, src/devops_cli/roadmap/runner_tools.py:186, src/devops_cli/roadmap/runner_tools.py:193, tests/roadmap/test_roadmap_implement_shell_refusal.py]- Chosen: Parse task and Job command lines. This matches the first-word rule of the step shell and catches both Job commands and task verifies.
- Rejected: Search the whole plan for tool names. This raises false refusals when a plan mentions a tool in prose or a citation.
- Rejected: Require a structured command manifest. This adds a new plan format that existing changes do not use.
- Does the gate cover a task verify whose program is in
NOT_IN_RUNNER, or only commands added to the Job?: Cover both. A task verify that runshelm templateordockermust be refused when its Feasibility line names no runner capability. The implement step runs the verify. (best practice) [sources: src/devops_cli/roadmap/runner_tools.py:186, src/devops_cli/roadmap/runner_tools.py:193, tests/roadmap/test_roadmap_runner_tools.py]- Chosen: Cover Job commands and task verify programs. The reply gives
helmanddockerverify cases that the current gate misses. - Rejected: Cover Job commands only. This leaves the
helmanddockerverify cases uncaught.
- Chosen: Cover Job commands and task verify programs. The reply gives
- Should the gate apply to plans of every effort, or only to low-effort items that the Service takes today?: Apply the gate to every staged plan. The Service filter is separate from staging. Revisit only if a person widens
effort=lowinimplement.py. (best practice) [sources: src/devops_cli/roadmap/implement.py:105]- Chosen: Check every staged plan. Staging runs before the Service filter, so the gate protects every plan and does not depend on effort.
- Rejected: Check only low-effort plans. This lets a medium- or high-effort plan keep an impossible command, and the filter can change.
- Does the change add a new label for a refused plan?: No. Use the existing
owner/*claim labels and give the reason in the refusal comment. (best practice) [sources: CONTEXT.md]- Chosen: Use existing
owner/*labels. The labels already leave an item out and carry the reason, so no new label family is needed. - Rejected: Add a new refusal label. This adds a label family and state that the existing claim labels already express.
- Chosen: Use existing
- What format does the required Feasibility section use?: Require a
## Feasibilitysection with one line for each command or verify program that needs a runner capability. Each line names the program, its source in the image orNOT_IN_RUNNER, and the pod setting that applies. (best practice) [sources: src/devops_cli/roadmap/runner_tools.py:186, k8s/README.md:643]- Chosen: One line for each capability need. This gives the gate a precise fact to check and keeps the section short.
- Rejected: A free-form Feasibility paragraph. The gate cannot check that the needed capability is named.
- Rejected: A full copy of the runner tables. This bloats the plan and duplicates facts that the context already holds.
- Which replay case goes into the golden set?: Use the docs(openspec): plan #3049 Plan the review gate before the ready mark #3183 plan feat(roadmap): Run
devops reviewon the diff before marking PR ready #3049 case that addsdevops reviewto the implement Job. Add the fix(k8s): name the Loki deployment mode Monolithic #2441helmverify case if the golden set has room. (best practice) [sources: src/devops_cli/roadmap/runner_tools.py:186]- Chosen: docs(openspec): plan #3049 Plan the review gate before the ready mark #3183 / feat(roadmap): Run
devops reviewon the diff before marking PR ready #3049devops reviewcase. It is the motivating case and exercises both context and gate. - Rejected: docs(openspec): plan #3060 plan model tier ladder for retries #3225 provider error case. It exercises failure classification but not the runner capability gate.
- Rejected: Both cases. This adds cost; the issue requires one replay case.
- Chosen: docs(openspec): plan #3049 Plan the review gate before the ready mark #3183 / feat(roadmap): Run
Fit
Fits in one pull request.
Suspected block
None.
Dependencies
None.
Alternatives check of 2026-11-06: rejected.
Rejected by ADR 0010. A newer fact can change an ADR.
Tool: Fission-AI/OpenSpec (https://github.com/Fission-AI/OpenSpec), MIT, last activity 2026-11-05, maintained.
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.It fixes a class of plan-review blockers but does not block the system or expose a security risk.It prevents a recurring category of plan failures but the system still functions without it.It requires modifying context assembly, adding a gate check, deriving facts from three source files, and writing four acceptance tests.Both extend the stage context with additional data, but #3012 adds callers and tests of cited symbols while the candidate adds the failure class table and runner capability facts.devops-cli-service commentedon Nov 2, 2026
Refine cannot set this item to Ready at 760f2cb until a person answers the questions below. Reply in a comment or edit the body, and the next refine round looks at the item again.
dan-petty commentedon Nov 4, 2026
Evaluation of 2026-11-04. Add one case to the gate of this item.
The gate covers a plan that adds a command to the Job. It must also cover a task verify whose program is in
NOT_IN_RUNNER. Example: task 1.1 ofopenspec/changes/2441-loki-values-name-the-monolithic-deployment/tasks.mdhas a verification that runshelm template, andNOT_IN_RUNNERlistshelm(src/devops_cli/roadmap/runner_tools.py:186). #2441 has low effort, so the implement job takes it, and the step refused that line on 2026-11-03.A second case of the same class: task 1.5 of the plan of #2554 needs a host with a local engine, and
NOT_IN_RUNNERlistsdocker(runner_tools.py:193).The Service takes only
effort=lowitems (src/devops_cli/roadmap/implement.py:105), so a plan with such a need at medium or high effort does not reach a Job today. Check those plans again if a person widens the filter. No new label is necessary for this: theowner/*claim labels already leave an item out, with the reason.devops-cli-service commentedon Nov 5, 2026
Status set to Ready at e447ea2 (see proposed design in issue body).
devops-cli-service commentedon Nov 6, 2026
Alternatives check: rejected
Rejected by ADR 0010. A newer fact can change an ADR.
Tool: Fission-AI/OpenSpec (https://github.com/Fission-AI/OpenSpec)
Covers:
## Feasibilitysection would sit.Lacks:
ACTION_BY_CLASSrules fromfailure.py, so a plan that changes retry/review/stop behavior gets no class facts.NOT_IN_RUNNERentries and the pod security settings are not known to it.validate --strictreads no proposal prose, so it cannot refuse a plan whose Feasibility line names no runner capability for a Job command or a task verify program.feasibilityartifact, so extending it to carry this fact set is not an available route; the repository derives the facts and enforces the section with its own test and gate.Searches run:
Sources:
Checked on 2026-11-06. A person decides what this means for the item. The check changes no label and closes no issue.
[-]feat(roadmap): the stage context holds the failure classes and the runner capabilities that a plan depends on[/-][+]feat(roadmap): Add failure classes and runner facts to stage context[/+]dan-petty commentedon Nov 6, 2026
The job shortened the title of this item. The summary had 94 characters, and the limit is 60. The type and the scope stay.
feat(roadmap): the stage context holds the failure classes and the runner capabilities that a plan depends onfeat(roadmap): Add failure classes and runner facts to stage contextdevops-cli-service commentedon Nov 9, 2026
Released in v0.98.0: https://github.com/dan-petty/devops-cli/releases/tag/v0.98.0
devops-cli-service commentedon Nov 9, 2026
Live since 2026-11-09 03:15 UTC
fix(roadmap): the alternatives check reads the tools in use (#5062)