Expand description
Pure cloud-agent task-state rules: which states keep a task alive, which end it, which transitions deserve an alert, and how often a watcher polls. No requests and no GPUI, so dashboards and background watchers share them.
Structs§
- Poll
Backoff - The watcher’s poll delay:
POLL_INTERVALwhile requests succeed, doubling up toMAX_POLL_INTERVALafter an error or a rate limit.
Enums§
- Alert
Kind - What a monitored task’s change is worth telling the user about.
Constants§
- ACTIVE_
STATES - The documented states a task or session can report.
idlecounts as finished: the agent stopped without more work to do. - FINISHED_
STATES - MAX_
POLL_ INTERVAL - The slowest poll a watcher backs off to after errors or rate limits.
- POLL_
INTERVAL - How often a watcher asks GitHub about its active tasks.
Functions§
- alert_
for - The alert a state change earns, or
Nonewhen it earns none. Only a task that was active can alert, so a list refresh of old finished tasks is silent, and an unknown state never alerts. - is_
active - True while the task can still change on its own.
waiting_for_userstays active because the user can answer and the task continues. - is_
finished - True for the documented end states. An unknown future state is neither active nor finished, so a watcher keeps showing it without alerting.
- needs_
input