Skip to content

GitHub App clean restart request resumes old solving state and sync branch #1129

@Serhan-Asad

Description

@Serhan-Asad

Summary

After stopping the #1120 run because it used Gemini instead of the intended Opus model, a clean restart was requested on the issue. The GitHub App did select the Opus executor, but it resumed the old solving state and launched pdd sync on the previous change/issue-1120 branch instead of starting a clean full pdd-issue autonomous solving flow from the current issue requirements.

Evidence

  • Source issue: Add /pdd budget control comments for GitHub App runs #1120
  • Previous generated PR: feat: PDD enhancement for #1120 #1126, closed after the Gemini run was stopped.
  • Restart comment on Add /pdd budget control comments for GitHub App runs #1120 requested: “Restarting cleanly with Opus. Previous Gemini-generated artifacts/PR feat: PDD enhancement for #1120 #1126 were stopped and closed; ignore that run. Please run the full pdd-issue autonomous solving flow from the current issue requirements using the Opus model for all PDD App/executor work.”
  • Bot response after labels were re-applied said: “Resuming Autonomous Solving / Continuing from the current state...”
  • Bot reported: Model: claude-opus-4-7, Base Branch: change/issue-1120.
  • The next job was pdd sync, not a fresh full pdd-issue change flow.
  • New job ID: 2spWUoLEcsUoSyUrWFKX.
  • Firestore fields showed label: sync, base_branch: change/issue-1120.
  • Logs showed the job launched via pdd-executor-job-opus, so model routing improved, but clean restart semantics did not.

Expected behavior

When a user explicitly requests a clean restart and says to ignore previous generated artifacts/PRs, PDD should not resume persisted solving state or continue from the old generated branch. It should start a fresh full pdd-issue flow from the target base branch and current issue requirements.

Actual behavior

PDD resumed persisted state and launched a sync job on the old change/issue-1120 branch, which may reuse Gemini-generated artifacts from the stopped run.

Impact

  • Clean restart requests are not reliable.
  • Stopped/untrusted generated artifacts can leak into the restarted run.
  • Users cannot safely recover from a wrong-model run by asking for a clean Opus restart on the same issue.

Acceptance criteria

  • Provide an explicit clean restart path for GitHub App issue workflows.
  • Clean restart clears or ignores persisted solving state for that issue.
  • Clean restart starts from the intended base branch, not the previous generated branch.
  • Clean restart runs the full requested command (pdd-issue) rather than the interrupted follow-up sync command.
  • The startup comment clearly says whether the run is resuming or clean-starting, and names the model, base branch, and command.
  • Tests cover re-labeling after a stopped run with a clean-restart request.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions