iotaledger / iotaledger/product-core
Refactor error-handling
- Dominant language
- Rust
- Stars
- 0
- Forks
- 2
- Avg merge
- 1h 29m
- Merged PRs (30d)
- 3
Description
### Feature description
Each fallible operation should have its own error type tailored to model it.
Deprecate (or remove) the old `Error` type and refactor error-handling for each fallible operation our library provides.
Write errors that leverage `std::error::Error` functionalities and ensure they are as modular, correct, and informative as possible without exposing any unnecessary foreign type. See [Sabrina's blog post](https://sabrinajewson.org/blog/errors) for directions.
### Motivation
A single huge `Error` enum for the whole crate doesn't cut it and it hinders the composability of our library's code, besides making it almost impossible for our users to recover from those errors.
Contributor guide
Assessment
This issue has not been assessed yet.