kurtbuilds / ormlite

An ORM in Rust for developers that love SQL.
https://crates.io/crates/ormlite
MIT License
216 stars 11 forks source link

Consider using #[error(transparent)] #8

Closed heroin-moose closed 2 years ago

heroin-moose commented 2 years ago

Currently enum Error uses {0} to show the source error message. However, when printing with AnyHow {:#} format this results in duplicated error message:

sqlx error: foobar: foobar

It seems that #[error(transparent)] is a better choice for nested errors.