90degs2infty opened a new issue, #16805: URL: https://github.com/apache/datafusion/issues/16805
### Describe the bug Some of `DataFusionError`'s variants leak the inner type to the user. E.g. [`DataFusionError::ObjectStore` simply wraps `object_store::Error`](https://docs.rs/datafusion/latest/datafusion/error/enum.DataFusionError.html#variant.ObjectStore) and propagates it to the user. Please consider re-designing `DataFusionError` for at least two reasons: 1. To handle `DataFusionError::ObjectStore` the user is forced to add the otherwise transitive dependency `object_store` to their own dependencies. 2. `object_store` becomes part of `datafusion`'s public API. Whenever there is a breaking change in `object_store::Error` and `datafusion` updates `object_store` internally, this implicitly becomes a breaking change in `datafusion`'s API as well. This also applies to other variants of `DataFusionError`. ### To Reproduce _No response_ ### Expected behavior _No response_ ### Additional context See e.g. [mmapped.blog](https://mmapped.blog/posts/12-rust-error-handling) or [d34dl0ck.me](https://d34dl0ck.me/rust-bites-designing-error-types-in-rust-libraries/index.html) for some discussion of error types including inner type leakage. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org