/** * Unified Bugs System Types * * Matches Orchestrator's bugs.json schema while extending for Jira Mate use. * Source of truth: .orchestrator/config/orchestrator.json (bugs array) * Mirror: .jm-mate/bugs.json (optional, for contexts without Orchestrator) */ export type BugStatus = 'open' | 'in-progress' | 'fixed' | 'ignored'; export type BugSeverity = 'low' | 'medium' | 'high' | 'critical'; export type BugSource = 'orchestrator' | 'manual' | 'ai' | 'test'; /** * Unified bug record matching Orchestrator schema * Based on .orchestrator/config/orchestrator.json bugs array structure */ export interface JmBugRecord { id: string; projectKey: string; title: string; description?: string; severity?: BugSeverity; status: BugStatus; errorMessage?: string; affectedFiles?: string[]; files?: string[]; reproducible?: boolean; reproSteps?: string[]; relatedInstructions?: string[]; labels?: string[]; source?: BugSource; jiraKey?: string; githubIssueUrl?: string; createdAt: string; updatedAt: string; fixedAt?: string; } /** * Bugs file structure * Can be .orchestrator/config/orchestrator.json (bugs array) or .jm-mate/bugs.json */ export interface JmBugsFile { bugs: JmBugRecord[]; lastUpdated?: string; } /** * Orchestrator bugs.json structure (for reference) * This is the canonical format in .orchestrator/config/orchestrator.json */ export interface OrchestratorBugsFile { bugs: Array<{ id: string; title: string; description?: string; severity: string; status: string; errorMessage?: string; affectedFiles?: string[]; reproducible?: boolean; reproSteps?: string[]; relatedInstructions?: string[]; createdAt: string; }>; } /** * Project configuration with links * @deprecated Use JmMateProjectConfig from src/shared/ticketMateTypes.ts instead */ export interface JmMateProjectConfig { projectKey: string; jiraBaseUrl: string; repoUrl?: string; repoName?: string; replitUrl?: string; replitSlug?: string; } export type { JmMateProjectConfig as JmMateProjectConfigShared } from '../../shared/ticketMateTypes'; /** * Bug metrics for a project */ export interface BugMetrics { total: number; open: number; inProgress: number; fixed: number; ignored: number; bySeverity: { critical: number; high: number; medium: number; low: number; }; fixedLast7Days: number; averageTimeToFix: number | null; oldestOpenBug: number | null; topFiles: Array<{ file: string; count: number; }>; } //# sourceMappingURL=types.d.ts.map