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

expect_column_values_to_match_regex skips Null(empty) column values #5232

Closed
rishabhsahrawat opened this issue Jun 2, 2022 · 3 comments
Closed
Assignees
Labels
community devrel This item is being addressed by the Developer Relations Team triage Used by the GE core team to flag issues that were not yet triaged

Comments

@rishabhsahrawat
Copy link

Describe the bug
I am using expect_column_values_to_match_regex function with regex, ^[-+]?(\d*[.])?\d+$. My spark dataframe column has a mix of negative, positive, float and also no values.

Expected behavior
Given my regex pattern, the function should raise an error.

Any reasons why I am seeing this behaviour?
Thank you in advance!

@AFineDayFor AFineDayFor added community devrel This item is being addressed by the Developer Relations Team labels Jun 2, 2022
@AFineDayFor
Copy link
Contributor

Howdy @rishabhsahrawat, thanks for reaching out and being a part of the community 🎉

The regular expression ( ^[-+]?(\d*[.])?\d+$ ) is valid in that it runs can capture positive and negative floats, and ints. Can you elaborate on why this is to fail in this case?

For us to further look into this, can you share your current configuration or workflow.

🙇

@AFineDayFor AFineDayFor self-assigned this Jun 2, 2022
@rishabhsahrawat
Copy link
Author

rishabhsahrawat commented Jun 7, 2022

Hey @AFineDayFor ,
Thanks for your response. As I mentioned, the spark dataframe column also has no values (so basically just empty). My question is shouldn’t the regex fail since it does not have any expression for those empty/ no values?

@github-actions github-actions bot added the stale Stale issues and PRs label Jul 23, 2022
@great-expectations great-expectations deleted a comment from github-actions bot Jul 25, 2022
@kyleaton kyleaton removed the stale Stale issues and PRs label Jul 25, 2022
@AFineDayFor AFineDayFor added the triage Used by the GE core team to flag issues that were not yet triaged label Jul 27, 2022
@AFineDayFor
Copy link
Contributor

Howdy @rishabhsahrawat 👋 if the regex doesn't present a match, the team concludes it ought to return a null and not be managed be supplied to metrics nor any metrics yielded.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community devrel This item is being addressed by the Developer Relations Team triage Used by the GE core team to flag issues that were not yet triaged
Projects
None yet
Development

No branches or pull requests

3 participants