Fix partition transform align with java - #3022
Open
Kurtiscwright wants to merge 2 commits into
Open
Conversation
blackmwk
reviewed
Aug 19, 2026
blackmwk
left a comment
Contributor
There was a problem hiding this comment.
Thanks @Kurtiscwright for this pr!
| // to format the ordinal. Day needs no arm: its result type is `date`, so | ||
| // the datum already renders as a calendar date. Any literal that is not an | ||
| // `int` falls through to the existing behaviour. | ||
| if let Literal::Primitive(PrimitiveLiteral::Int(ordinal)) = value { |
Contributor
There was a problem hiding this comment.
I prefer to move this under line 181 so that it's more consistent.
| } | ||
|
|
||
| #[test] | ||
| fn test_human_year() { |
Contributor
There was a problem hiding this comment.
I'm not a big fan of adding tests for private fn, I prefer to test against pub fun, e.g. to_human_string. Ideally, we could add doc to to_human_string which includes runnable codes to demonstrate the result.
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?
Moved transform to using from EPOCH time on Year, Month, and Hour (Day already aligns with Java).
Are these changes tested?
Added new unit tests to validate these changes
AI Disclosure
Use Claude to write unit tests and comments