Skip to content

Fix#6754 incorrect date truncation logic in JavaScript transform truncDate#6759

Merged
mattcasters merged 3 commits intoapache:mainfrom
leehaut:hotfix/lance-common-30
Mar 11, 2026
Merged

Fix#6754 incorrect date truncation logic in JavaScript transform truncDate#6759
mattcasters merged 3 commits intoapache:mainfrom
leehaut:hotfix/lance-common-30

Conversation

@leehaut
Copy link
Copy Markdown
Contributor

@leehaut leehaut commented Mar 11, 2026

Fix #6754 -- JavaScript transform plugin truncDate functionality changed and does not match documentation

This PR fixes an issue in the truncDate implementation used by the JavaScript transform.
The previous implementation only reset the specific time field for the requested truncation

@leehaut leehaut changed the title Fix incorrect date truncation logic in JavaScript transform truncDate Fix#6754 incorrect date truncation logic in JavaScript transform truncDate Mar 11, 2026
@mattcasters
Copy link
Copy Markdown
Contributor

Can you confirm that we now implemented the other options, truncation levels, correctly and that previous functionality still works as is? It would be amazing if we had an extra integration test to show this.

@leehaut
Copy link
Copy Markdown
Contributor Author

leehaut commented Mar 11, 2026

Can you confirm that we now implemented the other options, truncation levels, correctly and that previous functionality still works as is? It would be amazing if we had an extra integration test to show this.

I verified this through the ScriptValuesAddedFunctionsTest unit test. I will add an integration test for this

leehaut added 2 commits March 11, 2026 22:02
Signed-off-by: lance <leehaut@gmail.com>
Signed-off-by: lance <leehaut@gmail.com>
@leehaut
Copy link
Copy Markdown
Contributor Author

leehaut commented Mar 11, 2026

Add integration test for 0066-script-javascript-truncDate.

@mattcasters mattcasters merged commit c2dcbf7 into apache:main Mar 11, 2026
2 checks passed
@mattcasters
Copy link
Copy Markdown
Contributor

Thanks @leehaut, great work!

@leehaut leehaut deleted the hotfix/lance-common-30 branch March 15, 2026 13:02
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.

[Bug]: JavaScript transform plugin truncDate functionality changed and does not match documentation

2 participants