import type { WorkflowProof } from "../types.js"; import { type WorkspaceLifecycleProjection } from "./lifecycle.js"; import type { WorkspaceCompatibilityExecutionEvidence, WorkspaceIsolation, WorkspaceProviderRef } from "./types.js"; export type WorkflowWorkspaceSelection = "shared" | "compatibility" | "isolated"; export type WorkflowWorkspaceVerification = "not_applicable" | "pending" | "ok" | "blocked" | "lost"; export interface WorkflowWorkspaceStatus { schema_version: 1; run_id: string; run_name: string; work_item_id?: string; started_at: string; selection: WorkflowWorkspaceSelection; requested_isolation: "shared" | WorkspaceIsolation; effective_isolation: "shared" | WorkspaceIsolation; provider?: WorkspaceProviderRef; compatibility?: { reason: WorkspaceCompatibilityExecutionEvidence["selection_reason"]; unsupported: WorkspaceCompatibilityExecutionEvidence["unsupported"]; unknowns: WorkspaceCompatibilityExecutionEvidence["unknowns"]; }; allocation?: { binding_id: string; workspace_id: string; workspace_root: string; active_root: string; created_at: string; }; lifecycle: WorkspaceLifecycleProjection; verification: { status: WorkflowWorkspaceVerification; workflow_status?: WorkflowProof["run"]["status"]; attested_at?: string; drift: string[]; unsupported: Array<{ code: string; message: string; }>; unknowns: Array<{ code: string; message: string; }>; }; integration: { state: WorkspaceLifecycleProjection["integration_state"]; changed_paths: string[]; target_ref?: string; target_commit?: string; receipt_id?: string; }; cleanup: { state: "not_requested" | "pending" | "released" | "preserved_dirty" | "blocked"; attempts: number; reason?: string; receipt_id?: string; }; repository: { dirty_paths: string[]; conflicts: string[]; operations_in_progress: string[]; }; integrity: { status: "verified"; proof_sha256?: string; provider_event_chain_sha256: string | null; }; } export type WorkflowWorkspaceInspection = { ok: true; value: WorkflowWorkspaceStatus; } | { ok: false; run_id: string; error: string; }; /** * Read one workflow's workspace state from validated durable authority. * * Corrupt, contradictory, or foreign records throw instead of being projected * as healthy. Use inspectWorkflowWorkspace when a UI needs a typed error row. */ export declare function readWorkflowWorkspaceStatus(coordRoot: string, runId: string): WorkflowWorkspaceStatus; export declare function inspectWorkflowWorkspace(coordRoot: string, runId: string): WorkflowWorkspaceInspection; export declare function listWorkflowWorkspaceInspections(coordRoot: string): WorkflowWorkspaceInspection[]; export declare function renderWorkflowWorkspaceStatus(status: WorkflowWorkspaceStatus): string; //# sourceMappingURL=inspect.d.ts.map