dhruv-15-03 opened a new issue, #3820: URL: https://github.com/apache/parquet-java/issues/3820
### Describe the bug, including details regarding any error messages, version, and platform. In `TestParquetMetadataConverter.testBinaryStatsWithTruncation`, the helper creates `new ParquetMetadataConverter(truncateLen)` but then calls `metadataConverter.toParquetStatistics(stats)`. That method is static and delegates to `DEFAULT_STATISTICS_TRUNCATE_LENGTH` (`Integer.MAX_VALUE`), so the requested length never reaches conversion. The existing assertions do not detect this: unchanged under-limit bounds satisfy the non-strict ordering checks, while oversized inputs are expected to have no bounds, matching the unintended default path. The test therefore does not exercise the finite truncation it describes. This remains present at master `4b37c193e2f796d553a20cc57ec9835ceaa1c95c`. For a deterministic example, minimum `a` repeated 60 times and maximum `b` repeated 70 times with length 1 should produce `min_value="a"` and `max_value="c"` through the explicit overload. The current helper uses the default overload and leaves those bounds untruncated. The proposed correction is test-only: call `toParquetStatistics(stats, truncateLen)`, use deterministic exact-byte assertions, and cover the strict 4095-byte accepted/4096-byte omitted combined-size boundary before and after truncation. Constructor validation and current null-count omission behavior remain unchanged. #3819 addresses null-count serialization in production; this issue concerns a separate gap in truncation-test coverage and does not propose changing that behavior. ### Component(s) Core (`parquet-hadoop`) -- 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]
