jorgecarleitao opened a new pull request #8481:
URL: https://github.com/apache/arrow/pull/8481


   This PR:
   
   * Renamed `ExecutionError` to `DataFusionError`
   * Renamed `DataFusionError::ParserError` to `DataFusionError::SQL`
   * Renamed `DataFusionError::InternalError` to `DataFusionError::Internal`
   * Renamed `DataFusionError::ExecutionError` to `DataFusionError::Execution`
   * Adds a new error variant `DataFusionError::Plan` that is used during 
planning
   * Removes `DataFusionError::InvalidColumn` that was not being used.
   * Removes `DataFusionError::General`, replacing them by the appropriate 
errors
   * Improves the message of `DataFusionError::Internal` to incentivize users 
to file a bug report when it happens
   * Extended the documentation of every variant
   
   The design behind this PR is that the error variants should correspond to 
what happened:
   
   * `Internal`: a Datafusion's internal invariant was violated (e.g. downcast 
failed) => file a bug report
   * `Plan`: planning was incorrect
   * `NotImplemented`: something is not implemented and we know about it. 
Ideally, we should have an associated JIRA issue
   * `Execution`: an error during execution. We should avoid raising these, but 
sometimes it is impossible.
   * `IoError`: stuff related with reading and writing
   
   I went through every error that we return in `DataFusion` and verified that 
it is assigned correctly to one of these variants.
   
   I am a bit uncertain about the `ParquetError` and `ArrowError`. IMO 
`ArrowError` should be mapped to `DataFusionError::Execution`, as it only 
happens during execution, and `ParquetError` should be mapped to an `IoError`.
   
   I also think that we should split `NotImplemented` in two: `NotImplemented` 
and `NotSupported` as e.g. `float16` is something that we will likely never 
support, while "modulus" is just not implemented yet.


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to