In general, we use DataFusionError everywhere in the sedona crates, except for the few crates that don't involve DataFusion (e.g., sedona-geometry, sedona-raster). Sedona raster rather awkwardly uses ArrowError, because that is the error type it more directly uses most of the time. It's fairly common for sedona-geometry's error to be used in kernels, where there is a lot of .map_err()s instead of ?s.
We can consolidate errors to a crate sedona-error that has features arrow and datafusion, which, when enabled, add error variants and From<> implementations for ArrowError and DataFusionError. This will hopefully make the error handling between crates a bit more unified and reduce the number of dedicated error classes we need.
In general, we use
DataFusionErroreverywhere in the sedona crates, except for the few crates that don't involve DataFusion (e.g., sedona-geometry, sedona-raster). Sedona raster rather awkwardly uses ArrowError, because that is the error type it more directly uses most of the time. It's fairly common for sedona-geometry's error to be used in kernels, where there is a lot of.map_err()s instead of?s.We can consolidate errors to a crate
sedona-errorthat has featuresarrowanddatafusion, which, when enabled, add error variants andFrom<>implementations for ArrowError and DataFusionError. This will hopefully make the error handling between crates a bit more unified and reduce the number of dedicated error classes we need.