Anurag-S1ngh opened a new pull request, #19299: URL: https://github.com/apache/iceberg/pull/19299
## Summary - `rewrite_table_path` queued every position delete manifest entry for physical rewrite, including `DELETED` entries. After `rewrite_position_delete_files` followed by `expire_snapshots`, those files no longer exist and the rewrite failed with `FileNotFoundException`. - Queue only live entries that belong to the target snapshot set, matching the copy-plan condition. ## Changes - `RewriteTablePathUtil.writeDeleteFileEntry`: move the `toRewrite` addition inside the live-and-selected check for position deletes. - Add a test with one `DELETED` and one `ADDED` position delete entry, asserting only the live file is rewritten. ## Testing - `./gradlew :iceberg-core:test --tests "org.apache.iceberg.TestRewriteTablePathUtil"` passes. - The new test fails before the change with two files queued instead of one. - `spotlessApply` run for the module. Closes #16662 -- 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]
