fix(python): handle missing manifest partition summaries - #2886
Open
mattfaltyn wants to merge 2 commits into
Open
fix(python): handle missing manifest partition summaries#2886mattfaltyn wants to merge 2 commits into
mattfaltyn wants to merge 2 commits into
Conversation
mattfaltyn
marked this pull request as ready for review
July 24, 2026 07:02
Contributor
|
This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 1 week if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the dev@iceberg.apache.org list. Thank you for your contributions. |
dannycjones
reviewed
Aug 25, 2026
dannycjones
reviewed
Aug 25, 2026
dannycjones
left a comment
Contributor
There was a problem hiding this comment.
Thanks for the PR! I think we should consider changing the return type here
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
What changes are included in this PR?
The Python
ManifestFile.partitionsgetter now returnsNonewhen the optional core partition summaries are absent. Previously, the getter unconditionally unwrapped the optional value and triggered a Rust/PyO3 panic for valid manifest entries withpartitions: None.The optional return type preserves the distinction between absent summaries and a present empty list, avoids cloning the entire summaries vector before converting its entries, and a focused regression test covers the absent-summary case.
Are these changes tested?
Yes. The regression test constructs a valid
ManifestFilewithpartitions: Noneand verifies that the getter returnsNone.cargo test --locked -p pyiceberg_core_rust test_manifest_partitions_without_summaries -- --nocapturecargo fmt --all -- --checkcargo clippy --locked -p pyiceberg_core_rust --all-targets --all-features -- -D warnings