Jefffrey opened a new issue, #11197: URL: https://github.com/apache/arrow-rs/issues/11197
### Describe the bug https://github.com/apache/arrow-rs/blob/83ebd7248be4779700ab81dddd14d63c87fe5109/arrow-data/src/data.rs#L789-L791 it assumes a non-empty unionfields, but an empty union is valid ### To Reproduce ```rust #[test] fn test123() { let dt = DataType::Union(UnionFields::empty(), UnionMode::Dense); let ad = ArrayData::new_null(&dt, 1); } ``` this panics ### Expected behavior shouldnt panic ### Additional context _No response_ -- 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]
