/** * run-issue runs all stages of an issue in declared order — the top of the * pure orchestration backbone. Each stage commits its work in the shared * worktree; run-issue records each stage's handoff commit and surfaces the * LAST one as the issue's final handoff token (the SHA an approval/PR gate * would act on). * * Sequential and fail-fast: if a stage throws (an errored step), the issue * stops and later stages do not run. Pure orchestration over run-stage, so it * is unit-tested against fakes. Progress events (stage lifecycle, done, halted) * are emitted through the optional ProgressPort in deps. */ import { type Stage, type StageResult, type RetryPolicy } from "./run-stage.ts"; import type { RunStepDeps } from "./run-step.ts"; export interface Issue { issue: string; stages: Stage[]; } export interface IssueResult { stages: StageResult[]; /** The last stage's handoff commit — the issue's final handoff token, if any. */ commit?: string; } export declare function runIssue(deps: RunStepDeps, issue: Issue, retry?: RetryPolicy): Promise;