pub enum SnapshotError {
Io(Error),
InvalidFormat(String),
Corrupted,
Backend(String),
ArtifactInvalid(String),
}Expand description
Errors from snapshot operations.
Uses thiserror to match crate::KvError; unlike KvError (which is
Clone and so flattens its causes to strings), snapshot errors are observed
by a single caller, so Io keeps its #[source] chain via #[from].
Variants§
Io(Error)
InvalidFormat(String)
Corrupted
Backend(String)
A pluggable SnapshotStore backend (e.g. the fjall on-disk store)
reported an error. Kept backend-agnostic — no backend type leaks into this
enum’s signature — so enabling a backend feature does not change the public
error surface.
ArtifactInvalid(String)
An export artifact failed validation: malformed/mismatched manifest, checksum mismatch, version-policy rejection, unavailable destination, or a post-import cursor that disagrees with the manifest.
Distinct from InvalidFormat (a store-file
problem — “my local fold is broken”) because the recovery is different: an
invalid artifact means “fetch another artifact or fall back to a full
scan”, never “repair the local store”.
Trait Implementations§
Source§impl Debug for SnapshotError
impl Debug for SnapshotError
Source§impl Display for SnapshotError
impl Display for SnapshotError
Source§impl Error for SnapshotError
impl Error for SnapshotError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()