rdblue commented on code in PR #18108:
URL: https://github.com/apache/iceberg/pull/18108#discussion_r4149619156


##########
core/src/main/java/org/apache/iceberg/TrackedFileStruct.java:
##########
@@ -142,7 +145,8 @@ private TrackedFileStruct(TrackedFileStruct toCopy, 
Set<Integer> statsIds) {
     this.recordCount = toCopy.recordCount;
     this.fileSizeInBytes = toCopy.fileSizeInBytes;
     this.specId = toCopy.specId;
-    this.partitionData = toCopy.partitionData != null ? 
toCopy.partitionData.copy() : null;
+    this.partitionData = copyOf(toCopy.partitionData);

Review Comment:
   > the getter method on the copied file will return the stored union tuple 
(for writes)
   
   I think this is the behavior for reuse at read time, not for writes. Writes 
will wrap the value returned by `partition()` with a projection back to the 
current union spec type.



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