Skip to content

fix(roadmap): Fix-checks repairs failures its plan causes #6116

Closed

Description

@dan-petty

Problem

The fix-checks job (mode on) stopped on both of its runs since 0.169.3 with Failed check log is outside plan scope (src/devops_cli/roadmap/steps/fix_checks.py:446), so it graded 0 of 2 in 6 h. In both cases the plan's own change caused the failure, in a file that the plan does not list:

Tier 1 did not resolve the generated files, and the scope check refused the model repair.

Expected behavior

  • A failure in a file that is outside the plan is in scope when the plan's change causes it: a caller of a changed function or class, a snapshot or generated document of a changed command or tool, or a test of a changed module. The job repairs it, and the PR comment names the extra files.
  • Tier 1 writes generated files again with the project commands (devops docs generate, the snapshot update), with no model request.
  • A failure that the change does not cause (main skew, an expired ignore) stays out of scope, and the job says so.
  • After the fix, the fix-checks grade over 6 h is at least 80%.

Related

Proposed design

Problem statement

The fix-checks job stops when a check fails in a file that the plan does not list, even when the plan's change causes the failure. It grades 0 of 2 in 6 h. The job must repair such failures, regenerate generated files in Tier 1, and report the extra files.

Acceptance criteria

Requirement: Caller failure is in scope

The fix-checks job SHALL include a failure in a caller of a changed function or class in the plan scope.

Scenario: Caller test of a changed function

  • WHEN a scope test supplies changed symbol _run_pr_review_workflow and a failure in tests/git/test_review_worktree_regression.py::test_run_pr_review_workflow_partial_context
  • THEN the scope check returns in scope and lists tests/git/test_review_worktree_regression.py as an extra file.

Requirement: Test of a changed module is in scope

The fix-checks job SHALL include a failure in a test of a changed module in the plan scope.

Scenario: Test of a changed roadmap module

  • WHEN a scope test supplies changed module src/devops_cli/roadmap/steps/fix_checks.py and a failure in a test under tests/roadmap/ that imports that module
  • THEN the scope check returns in scope and lists the test file as an extra file.

Requirement: Snapshot failure is in scope

The fix-checks job SHALL include a failure in a snapshot of a changed command or tool in the plan scope.

Scenario: Snapshot test of a changed MCP tool

  • WHEN a scope test supplies a changed MCP tool and a failure in tests/ai/mcp/test_mcp_tool_listing.py::test_the_tool_listing_matches_the_snapshot
  • THEN the scope check returns in scope and lists the snapshot test as an extra file.

Requirement: Generated document failure is in scope

The fix-checks job SHALL include a failure in a generated document of a changed command or tool in the plan scope.

Scenario: Docs row of a changed command

  • WHEN a scope test supplies a changed command and a failure in the docs row that names docs/CLI_REFERENCE.md
  • THEN the scope check returns in scope and lists docs/CLI_REFERENCE.md as an extra file.

Requirement: Unrelated failure stays out of scope

The fix-checks job SHALL leave a failure out of scope when the plan's changed files and symbols do not reach the failing file.

Scenario: Main skew failure

  • WHEN a scope test supplies a failure in a file that no changed symbol, snapshot or generated document reaches
  • THEN the scope check returns out of scope and states that the change does not cause the failure.

Requirement: Tier 1 regenerates generated files and snapshots

Tier 1 of the fix-checks job MUST run uv run devops docs generate and the snapshot update command before any model request.

Scenario: Tier 1 command list

  • WHEN a unit test builds the Tier 1 command list for a docs or snapshot failure
  • THEN the list contains uv run devops docs generate and uv run pytest tests/ai/mcp/test_mcp_tool_listing.py --snapshot-update.

Requirement: PR comment names extra files

The fix-checks job SHALL name each extra file that it repairs in the PR comment.

Scenario: Comment for a repaired out-of-plan file

  • WHEN a unit test builds the PR comment for a repair that touched tests/git/test_review_worktree_regression.py
  • THEN the comment body contains that path.

Requirement: Fix-checks grade meets the floor

The fix-checks job SHALL reach a grade of at least 80% over a 6 h window after the fix.

Scenario: Grade report

  • WHEN uv run devops roadmap eval grades runs over the 6 h window after the fix
  • THEN it reports fix-checks at 80% or more.

Existing Tool Considered

No alternatives check has run. No open, maintained tool or library covers the need: this is the internal scope and repair logic of devops-cli's fix-checks roadmap step. The change builds on src/devops_cli/roadmap/steps/fix_checks.py and src/devops_cli/roadmap/steps/fix_checks_repair.py. Written cost: about 250k tokens to build the first version, about 50k tokens per later change to keep and fix it, and about 2 elapsed days for the first version.

Key questions

  • How does the fix-checks job decide that an out-of-plan failure is caused by the plan's change?: Collect the changed symbols and files from the plan diff. Put a failure in scope in three cases. The failing test imports or calls a changed symbol. The failure is a snapshot or a generated document of a changed command or tool. The failing test is a test of a changed module. Do not ask the model to decide scope. (best practice) [sources: src/devops_cli/roadmap/steps/fix_checks.py:446, tests/git/test_review_worktree_regression.py:305, tests/ai/mcp/test_mcp_tool_listing.py, docs/adr/0005-review-findings-come-from-tools-not-models.md]
    • Chosen: Deterministic symbol and artifact mapping. It uses checked facts from the diff and the test imports, as ADR 0005 requires for findings.
    • Rejected: Model decides scope. ADR 0005 keeps models out of finding state and scope decisions.
    • Rejected: Treat every failure as in scope. The issue keeps main skew and expired ignores out of scope.
  • Which commands does Tier 1 run to regenerate generated files and snapshots?: Run uv run devops docs generate for generated documents. Run uv run pytest tests/ai/mcp/test_mcp_tool_listing.py --snapshot-update for the MCP tool listing snapshot. Run both before any model request. (best practice) [sources: .agents/skills/devops-pr-ci/SKILL.md:21, tests/ai/mcp/test_mcp_tool_listing.py]
    • Chosen: Run the project commands. The project documents these commands and the test names its snapshot update command.
    • Rejected: Ask the model to edit generated files. Generated documents stay in git and the pull request regenerates them; a model edit is not the generator output.
    • Rejected: Add a generic snapshot update for all tests. It is wider than the failure and can hide unrelated snapshot changes.
  • Which failures stay out of scope?: A failure stays out of scope when the plan's changed files and symbols do not reach the failing file or test. Main skew and an expired ignore stay out of scope. The job reports that the change does not cause the failure. (best practice) [sources: src/devops_cli/roadmap/steps/fix_checks.py:446]
    • Chosen: Keep unrelated failures out of scope. The issue states that main skew and an expired ignore stay out of scope.
    • Rejected: Repair every failure. It would repair failures that the plan does not cause and hide skew.
  • How is the fix-checks grade measured?: Use uv run devops roadmap eval grades over a 6 h window. The command prints the job grade from the result line of each attempt. [sources: CONTEXT.md]

Fit

Fits in one pull request.

Suspected block

None.

Dependencies

None.

Activity

  1. added
    type/bug
    source/agent
    scope/roadmap
    on Nov 17, 2026
  2. dan-petty commented on Nov 17, 2026

    @dan-petty
    OwnerAuthor
    • Priority: P0-Critical. The fix-checks job is a CI job that stopped on both runs and graded 0 of 2, causing CI to fail.
    • Related: fix(roadmap): the fix-checks command passes no fixer to the step #5971, which asks for a different change. Both work on the fix-checks step scope_checker, but #5971 fixed the wiring of fixers while the candidate fixes the scope logic being too restrictive for plan-caused failures.
  3. added
    status/new
    effort/medium
    value/high
    priority/p0-critical
    owner/agent
    on Nov 17, 2026
  4. devops-cli-service commented on Nov 17, 2026

    @devops-cli-service
    Contributor

    Waiting for the alternatives check to run. The next refine round looks at the item again after the check records a verdict.

  5. added
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Nov 17, 2026
  6. removed
    status/in-review
    owner/agent
    on Nov 17, 2026
  7. devops-cli-service commented on Nov 17, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-17 08:08 UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort/mediumpriority/p0-criticalscope/roadmapsource/agenttype/bugvalue/high

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions