stevenzwu commented on code in PR #17523:
URL: https://github.com/apache/iceberg/pull/17523#discussion_r3726011429


##########
core/src/main/java/org/apache/iceberg/SnapshotsTable.java:
##########
@@ -94,13 +97,16 @@ public CloseableIterable<FileScanTask> planFiles() {
     }
   }
 
-  private static StaticDataTask.Row snapshotToRow(Snapshot snap) {
+  private static StaticDataTask.Row snapshotToRow(Snapshot snap, int 
formatVersion) {
+    boolean adaptive = formatVersion >= 
TableMetadata.MIN_FORMAT_VERSION_ADAPTIVE_MANIFEST_TREE;

Review Comment:
   good catch. this is a bug. I have some change locally that is not extracted 
properly in this PR. I intended to add this new API to the `Snapshot` interface.
   ```
     default int formatVersion() {
       return ManifestFile.LEGACY_FORMAT_VERSION;
     }
   ```
   
   I should have checked `snap.formatVersion() != 
ManifestFile.LEGACY_FORMAT_VERSION`. I should also add a test coverage for this 
scenario.



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