lyne7-sc opened a new issue, #3583: URL: https://github.com/apache/iceberg-rust/issues/3583
### Apache Iceberg Rust version main at beba39c8d62810fa101740bb2dbb03ab0d8f07ac ### Describe the bug `FanoutWriter` and `ClusteredWriter` identify partitions only by their values. Different partition specs can produce equal partition values, causing rows to share a writer initialized for the wrong spec. `ClusteredWriter` can also reject a distinct partition when another spec's partition with equal values has already been closed. ### To Reproduce Create a schema with integer columns `a` and `b`, and two partition specs: - Spec 0: identity partitioning on `a`. - Spec 1: identity partitioning on `b`. Write `(a=1, b=2)` with spec 0 and partition value `[1]`, then `(a=2, b=1)` with spec 1 and partition value `[1]`. Both writers reuse the first writer, placing the second row in a file labeled with spec 0 even though its `a` value is 2. For the clustered writer, first switch from spec 0 partition `[1]` to spec 0 partition `[2]`, then write spec 1 partition `[1]`. It incorrectly reports that the partition was previously closed. ### Expected behavior Identify partitions by both spec ID and partition values. Distinct specs should use separate writers even when their partition values are equal. The clustered writer should reject reopening only the same spec-and-value partition. ### Willingness to contribute I can contribute a fix for this bug independently -- 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]
