szehon-ho commented on code in PR #17493:
URL: https://github.com/apache/iceberg/pull/17493#discussion_r3717396053
##########
core/src/main/java/org/apache/iceberg/ContentStatsBackedMap.java:
##########
@@ -165,7 +166,39 @@ private static <V> V statValue(FieldStats<?> fieldStats,
Kind kind) {
private static ByteBuffer bound(FieldStats<?> fieldStats, Object bound,
String boundFieldName) {
Type boundType = fieldStats.type().fieldType(boundFieldName);
+ if (boundType == null) {
+ return null;
+ }
+
+ if (boundType.isStructType()) {
Review Comment:
Nit: `isStructType()` works today because only geometry/geography use struct
bounds (`StatsUtil.geoLowerBound` / `geoUpperBound`). Worth a brief comment (or
a named helper) so a future type with struct bounds does not silently take this
path.
--
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]