Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): update sqllogictest requirement from 0.23.0 to 0.24.0 #13902

Merged
merged 1 commit into from
Dec 26, 2024

Conversation

xudong963
Copy link
Member

Which issue does this PR close?

Closes ##13884

Rationale for this change

What changes are included in this PR?

Resolve the breaking change ("The Validator type used in various function in Runner implementation has a new required field Normalizer that is used to normalize result values.")

Are these changes tested?

Are there any user-facing changes?

@github-actions github-actions bot added the sqllogictest SQL Logic Tests (.slt) label Dec 25, 2024
Copy link
Member

@jonahgao jonahgao left a comment

Choose a reason for hiding this comment

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

LGTM, thank you @xudong963

}

fn value_validator(
normalizer: Normalizer,
Copy link
Member

Choose a reason for hiding this comment

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

Not related to this PR, I'm a bit confused about why sqllogictests need a Normalizer🤔
The value validator can already be customized, and specifically, the validator will call the normalizer within its proces. Normalizer seems like an unnecessary design to me.

Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

Not related to this PR, I'm a bit confused about why sqllogictests need a Normalizer🤔 The value validator can already be customized, and specifically, the validator will call the normalizer within its proces. Normalizer seems like an unnecessary design to me.

That was not entirely true unfortunately, the normalization was hardcoded in places.

Copy link
Member

Choose a reason for hiding this comment

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

That was not entirely true unfortunately, the normalization was hardcoded in places.

normalize_string was an internal part of the default validator. Although it was hard-coded, the outer validator can be user-defined. A user-defined validator like the one provided by DataFusion can offer more flexibility to meet specific row comparison needs, and might not require normalization.

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes. However, in my sidebranch for the sqlite tests it made things a bit cleaner, and in the branch I used to generate the 'cleansed' .slt files it was necessary as normalization was required where validation was not. I have no desire to spend any more time working on that dependency tbh so if you feel strongly about it I'll point you at that project :)

Copy link
Member

Choose a reason for hiding this comment

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

Thank you @Omega359 for the explanation. I don't have a strong opinion on this, just curious about its use cases. Since it can make some things cleaner, its existence is reasonable.

@jonahgao jonahgao merged commit 30660e0 into apache:main Dec 26, 2024
26 checks passed
@xudong963 xudong963 deleted the sqllogictest-dep branch December 26, 2024 02:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sqllogictest SQL Logic Tests (.slt)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants