test: enable float/double/binary array casts to string#4386
Merged
Conversation
3861785 to
460615e
Compare
460615e to
413d575
Compare
Enable FloatType, DoubleType, and BinaryType in CometCastSuite's ArrayType-to-StringType coverage. Allow ArrayType(BinaryType) casts to string to use the existing native binary string formatting path. Co-authored-by: Codex <codex@openai.com>
413d575 to
78945c6
Compare
Member
Author
|
@coderfender @comphead please help review. Thanks! |
andygrove
reviewed
Jun 2, 2026
andygrove
left a comment
Member
There was a problem hiding this comment.
Thanks @manuzhang. Changes look reasonable. Can you confirm that there are existing tests covering these changes?
Member
Author
|
@andygrove These are tests I've done locally
|
coderfender
reviewed
Jun 2, 2026
coderfender
left a comment
Contributor
There was a problem hiding this comment.
Thank you for this PR @manuzhang. The only suggestion is to probably use this PR to add some more test cases to help hash out any edge cases which arent exposed in the current framework for Float, Binary and Double type ?
Add focused FloatType, DoubleType, and BinaryType array-to-string edge coverage and align subnormal float formatting with Spark. Co-authored-by: Codex <codex@openai.com>
andygrove
reviewed
Jun 2, 2026
comphead
reviewed
Jun 2, 2026
comphead
left a comment
Contributor
There was a problem hiding this comment.
Thanks @manuzhang should we have also sql tests reflecting the correct behavior?
Add SQL-file coverage for array casts to string and remove the stale float precision example from the compatibility note. Co-authored-by: Codex <codex@openai.com>
Contributor
|
this is annoying Restarted CI |
comphead
reviewed
Jun 3, 2026
Contributor
|
Thanks @manuzhang the PR looks solid to me, some minor note though and CI pending |
Scope the compatibility warning to floating-point string formatting edge cases near precision limits or scientific notation. Co-authored-by: Codex <codex@openai.com>
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?
Part of #4248
Rationale for this change
CometCastSuitehad FloatType, DoubleType, and BinaryType commented out forArrayTypetoStringTypecasts. The native cast path already handles floating-point elements, and BinaryType can use the existing native binary string formatting path when arrays cast their elements to strings.What changes are included in this PR?
CometCastSuite.cast ArrayType to StringType.ArrayType(BinaryType) -> StringTypeso it follows normal element string-cast support.How are these changes tested?
./mvnw test -Pspark-4.1 -Dtest=none -Dsuites="org.apache.comet.CometCastSuite cast ArrayType to StringType"Co-authored-by: @codex