JeonDaehong opened a new pull request, #3352:
URL: https://github.com/apache/iceberg-rust/pull/3352

   ## Which issue does this PR close?
   
   - Closes #3349.
   
   ## What changes are included in this PR?
   
   `Datum::to_human_string`, which `partition_to_path` uses through 
`Transform::to_human_string`, now matches iceberg-java for:
   
   - **`timestamp` / `timestamp_ns`**: `yyyy-MM-ddTHH:mm:ss`, with trailing 
zeros of the fraction trimmed (`.120000` -> `.12`, no fraction for whole 
seconds)
   - **`timestamptz` / `timestamptz_ns`**: the same, followed by `+00:00`
   - **`binary` / `fixed`**: standard Base64 with padding
   
   `Display for Datum` is unchanged, so this only affects partition paths and 
the `partitions.<path>` keys in the snapshot summary. Reads are not affected, 
since they take partition values from manifests. Tables already written by 
iceberg-rust with these partition types will get the new path format for new 
files.
   
   ## Are these changes tested?
   
   Yes. 
   - New unit tests in `transform.rs` cover timestamps (micro and nano, with 
and without zone, whole seconds, trimmed fractions, pre-epoch values) and 
binary/fixed (empty, padding cases).
   - A `partition.rs` test checks a full path. 
   - All expected values were produced by running iceberg-java's 
`Transform.toHumanString` / `PartitionSpec.partitionToPath` on `main`.
   
   `cargo test -p iceberg --lib` (1845 passed), `cargo clippy -p iceberg 
--all-targets` and `cargo fmt --check` are clean.
   
   ## AI Disclosure
   
   I used Claude Code to help trace the Rust code path and draft the 
implementation and tests. I generated the expected values by running 
iceberg-java myself, and I reviewed the code and ran the tests and lints above.


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

Reply via email to