mikamikasuki opened a new pull request, #11391:
URL: https://github.com/apache/arrow-rs/pull/11391

   # Which issue does this PR close?
   
   - Closes #11388
   
   # Rationale for this change
   
   An imported C stream with a missing required callback currently makes 
`ArrowArrayStreamReader::try_new` or `next` panic. Re-exporting that reader can 
let the panic cross the `extern "C"` callback boundary and abort the process.
   
   # What changes are included in this PR?
   
   Return `ArrowError::CDataInterface` when `get_schema` or `get_next` is 
absent, and add a regression test for each callback.
   
   # Are these changes tested?
   
   Both regressions fail on upstream main 
`103ebe7548db35c37e8ff35fcb02438bcd182fa7` with `Option::unwrap` panics and 
pass with this change. The `arrow-array` FFI test suite passes (790 passed, 1 
ignored; 205 doctests passed, 2 ignored). Package Clippy with warnings denied, 
stable formatting, and diff checks pass.
   
   # Are there any significant user-facing changes?
   
   Malformed C streams now produce a C Data interface error instead of 
panicking.
   
   AI assistance was used to develop the callback checks and regression tests; 
I reviewed the changes and verified the focused and full `arrow-array` tests.


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

Reply via email to