You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "pvary (via GitHub)" <gi...@apache.org> on 2026/09/24 09:18:02 UTC

[PR] Flink: Fix flaky TestFlinkIcebergSinkV2 > testDeleteStats() [iceberg]

pvary opened a new pull request, #18241:
URL: https://github.com/apache/iceberg/pull/18241

   Fixes #18239


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


Re: [PR] Flink: Fix flaky TestFlinkIcebergSinkV2 > testDeleteStats() [iceberg]

Posted by "mxm (via GitHub)" <gi...@apache.org>.
mxm merged PR #18241:
URL: https://github.com/apache/iceberg/pull/18241


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


Re: [PR] Flink: Fix flaky TestFlinkIcebergSinkV2 > testDeleteStats() [iceberg]

Posted by "pvary (via GitHub)" <gi...@apache.org>.
pvary commented on code in PR #18241:
URL: https://github.com/apache/iceberg/pull/18241#discussion_r4091935171


##########
flink/v1.20/flink/src/test/java/org/apache/iceberg/flink/sink/TestFlinkIcebergSinkV2.java:
##########
@@ -245,12 +247,14 @@ public void testDeleteStats() throws Exception {
         expectedRecords,
         SnapshotRef.MAIN_BRANCH);
 
-    SnapshotChanges changes = SnapshotChanges.builderFor(table).build();
+    // The committer may append an empty snapshot after the change log commit
+    Snapshot snapshot = Iterables.getOnlyElement(findValidSnapshots());
+    SnapshotChanges changes = SnapshotChanges.builderFor(table).snapshot(snapshot).build();
     DeleteFile deleteFile = changes.addedDeleteFiles().iterator().next();
     String fromStat =
         new String(
             deleteFile.lowerBounds().get(MetadataColumns.DELETE_FILE_PATH.fieldId()).array());
     DataFile dataFile = changes.addedDataFiles().iterator().next();
-    assumeThat(fromStat).isEqualTo(dataFile.location());
+    assertThat(fromStat).isEqualTo(dataFile.location());

Review Comment:
   Unrelated typo fix



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


Re: [PR] Flink: Fix flaky TestFlinkIcebergSinkV2 > testDeleteStats() [iceberg]

Posted by "pvary (via GitHub)" <gi...@apache.org>.
pvary commented on code in PR #18241:
URL: https://github.com/apache/iceberg/pull/18241#discussion_r4091959419


##########
flink/v1.20/flink/src/test/java/org/apache/iceberg/flink/sink/TestFlinkIcebergSinkV2.java:
##########
@@ -245,12 +247,14 @@ public void testDeleteStats() throws Exception {
         expectedRecords,
         SnapshotRef.MAIN_BRANCH);
 
-    SnapshotChanges changes = SnapshotChanges.builderFor(table).build();
+    // The committer may append an empty snapshot after the change log commit
+    Snapshot snapshot = Iterables.getOnlyElement(findValidSnapshots());
+    SnapshotChanges changes = SnapshotChanges.builderFor(table).snapshot(snapshot).build();

Review Comment:
   Long wait caused `flink.max-continuous-empty-commits` to trigger and create a new empty commit on the top of the one we want to check. `findValidSnapshots()` finds the commits with manifest - so it finds the last commit with changes.



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