Skip to main content

deliver_cron_prompt

Function deliver_cron_prompt 

Source
pub(crate) fn deliver_cron_prompt(
    workspace: &Arc<Workspace>,
    cron: &CronEntry,
    missed: bool,
) -> CronFireOutcome
Expand description

Deliver a due cron’s prompt into its OWNER’s session as a plain user turn AND echo it as a cron block. team_role None routes to the project lead, Some(label) to that worker. A live owner gets a Command::Prompt; an asleep-but-existing owner is woken by dispatching Command::SpawnProject (which resumes the lead and, through the lead’s respawn, the worker), the prompt buffered by (project, team_role) and drained on the owner’s connect. An owner that no longer exists (a gone project, or a worker label with no persisted row) yields TargetGone.