You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "findinpath (via GitHub)" <gi...@apache.org> on 2025/06/12 13:13:19 UTC

Re: [PR] Core: Use time-travel schema when resolving partition spec in scan [iceberg]

findinpath commented on code in PR #13301:
URL: https://github.com/apache/iceberg/pull/13301#discussion_r2142706082


##########
core/src/main/java/org/apache/iceberg/SnapshotScan.java:
##########
@@ -79,6 +79,22 @@ protected ScanMetrics scanMetrics() {
     return scanMetrics;
   }
 
+  protected Map<Integer, PartitionSpec> specs() {
+    Map<Integer, PartitionSpec> specs = table().specs();
+    // requires latest schema
+    if (!useSnapshotSchema() || snapshotId() == null) {
+      return specs;
+    }
+

Review Comment:
   can we have a test showcasing the functionality fixed by this contribution?



-- 
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: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org