mhatipog opened a new issue, #19159:
URL: https://github.com/apache/iceberg/issues/19159

   `StrictMetricsEvaluator` currently treats a nested `isNaN` predicate as 
matching every row when the NaN count equals the value count, even if those 
counts do not cover the whole file.
   
   For example, consider an optional struct `parent` with a required double 
`value`, and two rows: `{parent: {value: NaN}}` and `{parent: null}`. Legacy 
ORC metrics can report record count 2, child value count 1, null count 0, and 
NaN count 1. The row evaluator rejects the second row, but the strict metrics 
evaluator returns true. Consequently a metadata delete can remove the entire 
file instead of rejecting a partial match.
   
   Expected: strict evaluation returns false unless the nested NaN count proves 
coverage of every row. Files with complete all-NaN metrics should remain 
eligible for metadata deletion.
   
   Reproduced with synthetic file metrics in `TestStrictMetricsEvaluator` and 
`TestDeleteFiles` (format versions 1–3, main and a named branch). All seven new 
regression cases fail on the unmodified evaluator and pass with the fix. The 
targeted API/core suites pass (163 tests, 16 skipped), as do Spotless checks. 
Related to #19064, but this addresses strict NaN evaluation rather than 
inclusive null pruning.


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

Reply via email to