laskoviymishka commented on code in PR #1128:
URL: https://github.com/apache/iceberg-go/pull/1128#discussion_r3302956288
##########
table/scanner.go:
##########
@@ -657,6 +668,10 @@ func (scan *Scan) PlanFiles(ctx context.Context)
([]FileScanTask, error) {
scan.snapshotID = &snapshot.SnapshotID
scan.asOfTimestamp = nil
}
+ if err := scan.validateRowFilter(); err != nil {
Review Comment:
I'd think hard about this placement. Java's `SnapshotScan.planFiles` returns
`CloseableIterable.empty()` when the snapshot is nil, PyIceberg's
`scan_plan_helper` returns `iter([])`, and iceberg-rust does the same — none of
them bind the filter on the empty-table path. After this PR we're the only
client that hard-errors there.
The fix to the gap is real, but I'd either gate this on `scan.Snapshot() !=
nil && len(manifestList) > 0` (so we only validate when we'd actually have used
the filter), or make the divergence an explicit, documented choice rather than
a side effect of validation placement. wdyt?
--
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]