Skip to content

Add transition after plan success #70

Description

@monkut

Context

cli.py:228-232 — Only prepare and develop trigger issue transitions. When plan completes successfully, no label swap or project board update occurs. The issue remains in the same state it was after prepare.

This is related to the action:plan label addition (see sibling issue), but can be implemented independently using existing labels.

Proposal

Add a plan transition in cli.py:

if action == AgentAction.PLAN and return_code == 0:
    transition_issue_to_development(issue_url)

Where the transition:

  • Swaps action:planaction:develop (or just adds action:develop if action:plan doesn't exist yet)
  • Moves project board status to "ready" or "todo"

Acceptance Criteria

  • On successful plan action (return code 0), askcc transitions the issue labels so that action:develop is present and any action:plan label is removed. If neither label is present initially, action:develop is added.
  • The transition uses the existing _swap_issue_labels helper pattern (consistent with the developaction:review transition), not a new ad-hoc implementation.
  • On successful plan action, the issue's project board status is transitioned using the existing _transition_project_fields helper (same pattern used by prepare/develop). If the issue is not in any project, the step is skipped cleanly.
  • Failing plan runs (non-zero return code) do NOT trigger any label or project transitions.
  • Unit tests cover: success path transitions labels, success path invokes project transition, failure path performs no transitions, and the no-project case is handled without error.
  • uv run pytest, uv run ruff check, and uv run pyright all pass.
  • No changes to the prepare or develop transition behavior.

Dependencies

None. Uses existing action:develop label and existing transition helpers.

Rationale

Without a transition after plan, there's no automated signal that planning is complete and the issue is ready for development. The workflow gap means issues can sit untracked between plan and develop.

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions