alamb opened a new issue, #6093: URL: https://github.com/apache/arrow-rs/issues/6093
**Is your feature request related to a problem or challenge? Please describe what you are trying to do.** The fact that Paruqet metadata statistics requires checking before access is confusing and error prone, for example https://github.com/apache/arrow-rs/pull/6092 **Describe the solution you'd like** Change the API so it doesn't panic if used incorrectly **Describe alternatives you've considered** I propose removing these methods: * https://docs.rs/parquet/latest/parquet/file/statistics/enum.Statistics.html#method.has_min_max_set * https://docs.rs/parquet/latest/parquet/file/statistics/struct.ValueStatistics.html#method.has_min_max_set And changing the corresponding accessors like `min()` and `max()` to return `Option<&T>` rather than `&T` Today: ```rust impl Statistics { ... // panics if `has_min_max_set` is returns false pub fn min(&self) -> &T ... } ``` Proposal: ```rust impl Statistics { ... // Returns None if statistics not set pub fn min(&self) -> Option<&T> ... } ``` **Additional context** -- 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]
