import type { TaskFileData, TaskFailure } from './schema.js'; import type { TaskInfo, TaskResult, TaskListItem, TaskState } from './types.js'; import type { TaskStatus } from './schema.js'; import { type ExceedTaskOptions } from './taskExceedService.js'; import type { RunResumeSource } from '../../core/workflow/run/run-meta.js'; import { type AutoRequeueResult, type TaskRetryOptions } from './taskRetryService.js'; export type { TaskInfo, TaskResult, TaskListItem, TaskState }; export interface TaskRunnerOptions { onWarning?: (warning: string) => void; } export declare class TaskRunner { private readonly projectDir; private readonly store; private readonly tasksFile; private readonly lifecycle; private readonly query; private readonly deletion; private readonly exceed; private readonly retry; constructor(projectDir: string, options?: TaskRunnerOptions); ensureDirs(): void; getTasksFilePath(): string; addTask(content: string, options?: Omit & { content_file?: string; task_dir?: string; worktree_path?: string; slug?: string; summary?: string; }): TaskInfo; listTasks(): TaskInfo[]; claimNextTasks(count: number): TaskInfo[]; failInterruptedRunningTasks(): number; completeTask(result: TaskResult): string; failTask(result: TaskResult): string; forceFailRunningTask(taskName: string, failure: TaskFailure): string; updateRunningTaskExecution(taskName: string, execution: { runSlug: string; worktreePath?: string; branch?: string; }): TaskInfo; prFailTask(result: TaskResult, prError: string): string; listPendingTaskItems(): TaskListItem[]; listAllTaskItems(): TaskListItem[]; listTaskStateItems(): TaskState[]; listFailedTasks(): TaskListItem[]; listExceededTasks(): TaskListItem[]; requeueFailedTask(taskRef: string, startStep?: string, retryNote?: string): string; autoRequeueFailedTask(taskRef: string, options: { maxAttempts: number; }): AutoRequeueResult; requeueTask(taskRef: string, allowedStatuses: readonly TaskStatus[], options?: TaskRetryOptions): string; startReExecution(taskRef: string, allowedStatuses: readonly TaskStatus[], resumeMode: RunResumeSource['resumeMode'], options?: TaskRetryOptions): TaskInfo; deleteTask(name: string, kind: 'pending' | 'failed' | 'completed' | 'exceeded' | 'pr_failed'): void; exceedTask(taskName: string, options: ExceedTaskOptions): void; requeueExceededTask(taskName: string): void; } //# sourceMappingURL=runner.d.ts.map