ump45nose commented on PR #7228:
URL: 
https://github.com/apache/datafusion-comet/pull/7228#issuecomment-6894939296

   @andygrove thanks, good catch. Fixed in `d6671716`.
   
   - `jvm_exception` now looks through `Context` and `Shared` for an `External` 
`SparkError` (or `SparkErrorWithContext`) before the file-read classification, 
via a small `wrapped_external_spark_exception` helper. A bare `External` still 
takes the existing top-level arm. This also covers `ParquetTimestampOverflow` 
and any other `SparkError` the scan attaches.
   - New unit test `external_cannot_read_file_survives_context_and_shared` in 
`errors.rs`: `External(CannotReadFile)` bare, in `Context`, in `Shared`, and in 
`Shared(Context(..))` all classify as a Spark exception whose JSON carries 
`CannotReadFile` and the file path. It fails without the change (the wrapped 
cases fall to the generic exception) and passes with it.
   
   Local: the `errors::tests` classification tests pass (15) and `cargo clippy 
-p datafusion-comet-jni-bridge --all-targets -- -D warnings` and `cargo fmt 
--check` are clean. I have not added the JVM join-build-side test yet: there is 
no JVM on the machine I used for this change, so I could not run it. I can add 
one if you think the unit test is not enough.
   
   (AI-assisted change and reply.)
   


-- 
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: [email protected]

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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to