amogh-jahagirdar commented on code in PR #11131:
URL: https://github.com/apache/iceberg/pull/11131#discussion_r1805018372


##########
core/src/main/java/org/apache/iceberg/ManifestFilterManager.java:
##########
@@ -162,11 +178,13 @@ void delete(F file) {
   void delete(CharSequence path) {
     Preconditions.checkNotNull(path, "Cannot delete file path: null");
     invalidateFilteredCache();
+    this.allDeletesReferenceManifests = false;
     deletePaths.add(path);
   }
 
   boolean containsDeletes() {
-    return !deletePaths.isEmpty()
+    return !manifestsReferencedForDeletes.isEmpty()

Review Comment:
   It's not strictly required since we currently always add to `deleteFiles` 
when deleting by the content file, I can remove it if you think it's not as 
readable to have it. 
   
   I think I'd prefer to keep it though because in case some future logic 
shifts around for whatever reason, containsDeletes() will just return the right 
value instead of us having to make sure we update this method.
   
   But I'm good either way, not super opinonated on it!



-- 
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-unsubscr...@iceberg.apache.org

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


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

Reply via email to