pub enum DummyError {
Load(String),
Embed(String),
Other(String),
}Expand description
Reference implementation: the shape of error a real backend would ship. Concrete backend crates define their own.
Variants§
Load(String)
The model could not be loaded (missing/corrupt weights).
Embed(String)
Embedding a batch failed (e.g. tokenisation).
Other(String)
Anything else, escape hatch.
Trait Implementations§
Source§impl Debug for DummyError
impl Debug for DummyError
Source§impl Display for DummyError
impl Display for DummyError
Source§impl Error for DummyError
impl Error for DummyError
1.30.0 · 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 DummyError
impl RefUnwindSafe for DummyError
impl Send for DummyError
impl Sync for DummyError
impl Unpin for DummyError
impl UnsafeUnpin for DummyError
impl UnwindSafe for DummyError
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