Skip to content

Conversation

@carloea2
Copy link
Contributor

@carloea2 carloea2 commented Dec 28, 2025

What changes were proposed in this PR?

  • Added support in parseTimestamp(fieldValue: Any) for additional java.time input types:

    • LocalDateTimeTimestamp.valueOf(ldt)
    • InstantTimestamp.from(inst)
    • OffsetDateTimeTimestamp.from(odt.toInstant)
    • ZonedDateTimeTimestamp.from(zdt.toInstant)
    • LocalDateTimestamp.valueOf(ld.atStartOfDay())

Any related issues, documentation, discussions?

How was this PR tested?

  • Added unit tests covering the new java.time cases for timestamp parsing:

    • Positive cases for LocalDateTime, Instant, OffsetDateTime, ZonedDateTime, and LocalDate
    • Negative case verifying unsupported/invalid inputs throw AttributeTypeException

Was this PR authored or co-authored using generative AI tooling?

No

@carloea2 carloea2 changed the title v1 fix: Support more java.time inputs in timestamp parsing Dec 28, 2025
@chenlica chenlica requested a review from bobbai00 December 28, 2025 20:18
@chenlica
Copy link
Contributor

@bobbai00 Please review this PR.

@bobbai00 bobbai00 changed the title fix: Support more java.time inputs in timestamp parsing fix: support more java.time inputs in timestamp parsing Dec 28, 2025
Copy link
Contributor

@bobbai00 bobbai00 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Left few minor comments

@carloea2
Copy link
Contributor Author

Thanks. Done.

@chenlica
Copy link
Contributor

@bobbai00 Can we merge this PR now?

@carloea2
Copy link
Contributor Author

@chenlica can you approve the workflows to run?

@chenlica
Copy link
Contributor

@carloea2 There is a failed check. Please look into it.

@carloea2
Copy link
Contributor Author

It should be fine now..

@carloea2
Copy link
Contributor Author

@chenlica Done.

@chenlica chenlica merged commit acca01d into apache:main Dec 29, 2025
10 checks passed
@chenlica
Copy link
Contributor

@carloea2 Please mention the related issue and close that issue as well.

@carloea2
Copy link
Contributor Author

carloea2 commented Dec 29, 2025

I do not have permission to close issues, can you do that? thanks

I also added the issue to the PR description.

@chenlica
Copy link
Contributor

I closed the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

DateTime backend exception following User Defined Function

3 participants