Replace Codex errors at bridge boundary

This commit is contained in:
Meta Vens 2026-05-19 15:38:31 +01:00
commit b54db5b54c
8 changed files with 84 additions and 60 deletions

View file

@ -0,0 +1,20 @@
use std::error::Error;
use std::fmt;
#[derive(Debug, Clone, PartialEq, Eq)]
pub enum EpiphanyBridgeError {
InvalidRequest(String),
Fatal(String),
}
pub type Result<T> = std::result::Result<T, EpiphanyBridgeError>;
impl fmt::Display for EpiphanyBridgeError {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
match self {
Self::InvalidRequest(message) | Self::Fatal(message) => f.write_str(message),
}
}
}
impl Error for EpiphanyBridgeError {}