Skip to content

fix(roadmap): fix-plan compares the revision with a review of the head #5150

Closed

Description

@dan-petty

Problem Description

The step fix-plan (#5061) compares the open findings of two different model reviews, so its result unchanged or revised does not show whether the revision is better than the plan of the head.

  • before is the count of the open findings that the last plan comment lists (comment_open_findings(plan_comment(...)) in src/devops_cli/roadmap/steps/fix_plan.py). The stage job wrote that comment when it staged the plan, with an earlier release, at an earlier commit of the default branch.
  • after is the count of the open findings of the last review of the revision, by the current verification pass at the latest default branch (_Planner.revise in src/devops_cli/roadmap/stage/stage.py: before = list(findings), and the review of the head runs only when the comment lists no open finding).
  • _settle then pushes only when after < before. A review of a model names other findings in each run, so the two counts do not measure the same plan with the same review.

The first live attempt, on #4980 of item #2530 (Kubernetes Job devops/fix-plan-validate-4980, release 0.119.0, 2026-11-12T15:52Z to 16:48Z), ended unchanged: 1 open finding(s) before the repair, 2 after it. The 1 came from the stage comment of 2026-11-12T08:34Z (release 0.117.x). The 2 came from the third review of the attempt.

The plan of the head did not change between the two counts. One review of that plan (head 89b5e650822f) with the verification model of the Service (deepseek-v4.1-flash-1017), the code of 0.119.0 and the default branch of the Job (22176a02be18) found 2 open findings, not 1:

  • false_premise at specs: devops pr check-readiness also calls read_draft, which reads pulls/{number}/files for an implement pull request. This is the defect that the stage comment lists as criterion_dropped.
  • verify_form at group 3: the group changes monitor_pr, whose tests are in tests/commands/test_pr.py, but its verification runs only tests/github/test_github_pr_monitor.py. The stage comment does not list this finding, so the first repair of the step did not get it.

So two reviews of the same plan with the same model and prompt gave 1 and 2 open findings, and the attempt compared 2 with the stale 1. Measured against this review of the head, the revision (2) is not better, but it is not worse. The verification prompt and the open types did not change between the two releases (only the return rule of #5067 and the rounds of #5090), so the difference is the sample of the review and the commit, not a new verifier.

Reproduction Steps

  1. Stage a plan whose stage comment lists 1 open finding.
  2. Let the verification pass find 2 open findings in the plan of the head and 1 in the revision.
  3. Run devops roadmap step fix-plan --pull <n> --confirm.
  4. The step reports unchanged (1 before, 1 after) and pushes nothing, but the revision has fewer open findings than the head under the same review.

Expected vs Actual Behavior

Expected: the step reviews the plan of the head with the current verification pass at the latest default branch, and compares the last review of the revision with that review. The planner gets the open findings of the comment and of that review. A head plan with no open finding in that review loses the label with no plan call, as the stage job does in a later round. The result line shows both counts: the findings of the comment and those of the review of the head.

Actual: before is the count of the stale comment, and the comparison mixes two reviews.

Logs, Traces, or Terminal Output

The Tempo trace aa2875702bd3ac1a86127683a8e86a4d (service roadmap-fix-plan-validation) holds 9 agent runs whose tokens add up to the reported 15,933,306: 3 reviews 9,800,342 (62%), 3 repair plan runs 4,479,335 (28%) and 3 gate returns 1,653,629 (10%). About 96% of the input tokens were cache reads. The gate refusals of the Job were citation, paths and trace, 1 each. The review adds one review run to an attempt that has a comment (about 3.3M tokens and 8 minutes on #4980), and saves every plan run when the head has no open finding.

Existing Tool Considered

No tool applies: the defect is in the comparison rule of the step. The fix reuses _Planner._review, the same call that the step makes when no comment lists a finding.

Activity

  1. added
    source/agent
    type/bug
    scope/roadmap
    status/new
    value/medium
    effort/medium
    on Nov 12, 2026
  2. dan-petty commented on Nov 12, 2026

    @dan-petty
    OwnerAuthor
  3. added
    priority/p2-medium
    owner/agent
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Nov 12, 2026
  4. removed
    status/in-review
    owner/agent
    on Nov 12, 2026
  5. devops-cli-service commented on Nov 12, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-12 17:54 UTC

  6. added a commit that references this issue on Nov 13, 2026
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/p2-mediumscope/roadmapsource/agenttype/bugvalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions