import { CustomError } from "@baqhub/sdk";
import { Program } from "../index.js";
interface ProgramErrorOptions {
    code?: string;
    exitCode?: number;
}
export declare class ProgramError extends CustomError {
    message: string;
    options: ProgramErrorOptions;
    constructor(message: string, options?: ProgramErrorOptions);
}
export declare function handleErrors(program: Program, worker: () => Promise<unknown>, genericError: string): Promise<void>;
export {};
