agentstategraph_reminders/
error.rs1use thiserror::Error;
4
5use crate::types::ReminderStatus;
6
7#[derive(Debug, Error)]
8pub enum ReminderError {
9 #[error("reminder not found: {0}")]
10 NotFound(String),
11
12 #[error("reminder {0} is already in a terminal state ({1:?}) and cannot be modified")]
13 AlreadyTerminal(String, ReminderStatus),
14
15 #[error("invalid status transition for reminder {id}: {from:?} → {to:?}")]
16 InvalidTransition {
17 id: String,
18 from: ReminderStatus,
19 to: ReminderStatus,
20 },
21
22 #[error("reminder {0} requires approval before execution (autonomous=false)")]
23 RequiresApproval(String),
24
25 #[error("storage error: {0}")]
26 Store(String),
27}