pub enum Error {
FileRead {
path: PathBuf,
source: Error,
},
FileWrite {
path: PathBuf,
source: Error,
},
InvalidFrontmatter {
path: PathBuf,
message: String,
},
YamlParse {
path: PathBuf,
source: Error,
},
MissingField {
path: PathBuf,
field: &'static str,
},
TemplateRender {
source: Error,
},
NoAdrsFound {
path: PathBuf,
},
ValidationFailed(usize),
InvalidFilename(String),
GlobPattern(String),
DateParse {
path: PathBuf,
message: String,
},
JsonSerialize(String),
}Expand description
Error type for all ADRScope operations.
Variants§
FileRead
Failed to read an ADR file from the filesystem.
Fields
FileWrite
Failed to write output to the filesystem.
InvalidFrontmatter
Invalid YAML frontmatter in an ADR file.
Fields
YamlParse
YAML parsing failed.
MissingField
Missing required frontmatter field.
Fields
TemplateRender
Template rendering failed.
Fields
§
source: ErrorThe underlying askama error.
NoAdrsFound
No ADR files found in the specified directory.
ValidationFailed(usize)
Validation failed with one or more errors.
InvalidFilename(String)
Invalid ADR filename format.
GlobPattern(String)
Glob pattern error.
DateParse
Date parsing error.
Fields
JsonSerialize(String)
JSON serialization error.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for Error
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more