Skip to content

fix(roadmap): a new-branch run reuses a closed draft #6687

Closed

Description

@dan-petty

Problem

A review of #6670 (implement on the phases, merged at adacda9) found these defects on main. Each was shown with real git and the GitHub fakes:

  1. A new-branch run reuses a closed draft. publish_implement takes implement.pr from the record when state.pull is None, but prepare clears that mark only when the run has a pull (implement_phases.py about line 330). Job 1 opens draft docs: update agent instructions for PR updating, release targeting, and non-merge policy #5 and stops. A person deletes the branch, which closes docs: update agent instructions for PR updating, release targeting, and non-merge policy #5. Job 2 then writes its title, body and comments to the closed docs: update agent instructions for PR updating, release targeting, and non-merge policy #5 and opens no draft for the branch that it pushed.
  2. A publish that dies after the draft opens deletes the branch on the next run. If the Job ends between POST /pulls and the implement.pr mark, the next publish posts the draft again. GitHub refuses it (422), and _open_draft deletes the branch.
  3. A return that dies after the withdraw blocks the item on the next run. The next publish runs _withdraw again. The delete push fails, because the branch is gone, so the item stops Blocked when it should be New.
  4. An issue title with a closing keyword reaches the PR title. _title checks the plan summary with closing_keyword_in, but not the fallback issue title. The squash commit on main then closes the other issue. The Semantic PR title check does not stop it.
  5. Stale text. The dry-run plan of devops roadmap implement lacks the branch delete of a refused draft, the git calls before the withdraw push, and the fetch of the lease. Several texts still describe the old flow: SECURITY.md:54, the process_hardening.py and worktree_add.py docstrings, stop_clear.py:12, the settings.py description of continuations, pull-request/spec.md and the runner spec line on the home folder.

Expected

  • prepare always writes the PR mark (the pull of the run, or none).
  • _open_draft finds an open draft for the head before it posts one.
  • The withdraw is recorded as soon as it is done.
  • A fallback title with a closing keyword stops the publish, as the plan summary does.
  • The texts describe the phases.

Related

Source

Source: #6670

Activity

  1. dan-petty commented on Nov 21, 2026

    @dan-petty
    OwnerAuthor
    • Priority: P2-Medium. A functional bug in the roadmap workflow with no service outage or CI failure. The regression commit adacda9 does not set P0: the author has no write access, and no caller attached it as evidence. A person can set P0 with the label priority/p0-critical.
    • Related: feat(roadmap): end the implement Job at the draft pull request #6559, which asks for a different change. Both concern the implement Job draft-PR flow; #6559 delivers the feature, the candidate fixes defects found in that delivery.
  2. added
    type/bug
    source/agent
    scope/roadmap
    status/new
    value/medium
    effort/medium
    priority/p2-medium
    owner/agent
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Nov 21, 2026
  3. removed
    status/in-review
    owner/agent
    on Nov 21, 2026
  4. devops-cli-service commented on Nov 21, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-21 23:18 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/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