fMeow / arangors

Easy to use rust driver for arangoDB
https://docs.rs/arangors
MIT License
128 stars 28 forks source link

Error Improvements #67

Closed ManevilleF closed 3 years ago

ManevilleF commented 3 years ago

Hello,

In arangors there are two error types:

I can make a Merge requests changes the error type of ArangoDB operations from ClientError to a ArangoError.

With the From<> implementation for ClientError this won't be breaking changes but it will at least allow more specific error handling.

fMeow commented 3 years ago

This is a way to convert from ArangoError to ClientError.

We can either explictly use ClientError::from(arango_error) or simple use a ? to let rust do the conversion for us.