/** * #329: a task blocked with org_task_block used to sleep until its deadline. * Nothing external reaches a blocked task — a background command's * completion, a Monitor event and npm propagation all live (at most) in the * role's own process stream, which idle-cycling may already have ended — so a * block set "until 11:00Z" on a four-minute install idled for half an hour. * * Every block is now re-checked: its assignee is woken on a bounded interval * and asked whether what it was waiting for has happened, until the deadline * (unblockExpired) or a close. The schedule lives on the task row * (`recheckAt` / `recheckEveryMs`), so it survives process cycling and * checkpoint resume; a tick that runs late — the daemon was down across the * due time — fires once, then resumes the interval from now. */ import type { RunningOrg } from './daemon.js'; import type { OrgTask } from './task-dag.js'; import { MAX_BLOCK_RECHECK_MINUTES } from './types.js'; export { MAX_BLOCK_RECHECK_MINUTES }; export declare const DEFAULT_BLOCK_RECHECK_MINUTES = 5; /** Floor for a role's own recheckAfterMinutes: a wake is a model turn. */ export declare const MIN_BLOCK_RECHECK_MINUTES = 1; /** The re-check interval for one block: the role's own request (clamped to * [MIN, MAX]) if it made one, else run_config.block_recheck_minutes (bounded * by the schema), else the default. */ export declare function blockRecheckMs(orgMinutes?: number, requestedMinutes?: number): number; /** Wake the assignee of every blocked task whose re-check is due, and move * its next re-check one interval on. Called on every idle-watchdog tick, * next to the block-expiry resume. Returns the tasks it woke. */ export declare function wakeDueBlockRechecks(running: Pick, now: number): OrgTask[]; //# sourceMappingURL=block-recheck.d.ts.map