https://slatedb.io logo
is there currently a way to check
# general
r
is there currently a way to check whether an operation failed because it was fenced ? i believe it should map to
ErrorKind::Permission
but there isn't actually a way to get the kind from an error at the moment
c
Ah, good find. We should add a
with_source
call in errors.rs for htis
Mind opening a GH issue? I can put it into the 0.8.3 release
Copy code
+            SlateDBError::Fenced => Error::permission(msg).with_source(Box::new(err)),
That should allow you to check the source
Ah I see it's slightly more complex since the with_source is used for public-facing errors and the fence error isn't public. We can still fix this, though. In the meantime
permission
is only used for fencing, so you can treat any permission error as fenced for now
2 Views