#[non_exhaustive]pub enum FsError {
NotFound(PathBuf),
NotPermitted(String),
TooLarge {
bytes: u64,
limit: u64,
},
Conflict(PathBuf),
Backend(BoxError),
}Expand description
Fs backend error.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NotFound(PathBuf)
File not found.
NotPermitted(String)
Operation not permitted: path out of bounds, binary file, client deny, insufficient permissions, etc. Currently uses a string placeholder; may become an enum in a later iteration.
TooLarge
File exceeds the size threshold.
Conflict(PathBuf)
File was externally modified during a read-modify-write cycle.
edit_file compares fingerprints via FsBackend::fingerprint before writing:
a mismatch raises Conflict, prompting the LLM to re-read and re-edit instead of
overwriting.
Backend(BoxError)
Underlying I/O or RPC failure.
Trait Implementations§
Source§impl Error for FsError
impl Error for FsError
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 !RefUnwindSafe for FsError
impl !UnwindSafe for FsError
impl Freeze for FsError
impl Send for FsError
impl Sync for FsError
impl Unpin for FsError
impl UnsafeUnpin for FsError
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