-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Make Topk aggregate tests deterministic #8998
Make Topk aggregate tests deterministic #8998
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't test the code path with collisions anymore, but that might be okay @alamb
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mustafasrepo but just for curiosity, how the test becomes deterministic if only test result has changed? 🤔 no extra sorting or code change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this PR makes a lot of sense to me -- thank you @mustafasrepo . I am pretty sure it still covers the core use case -- I left a comment that might also increase coverage.
@avantgardnerio if you have additional suggestions on how to improve this test that would be most helpful
@@ -26,8 +26,8 @@ CREATE TABLE traces(trace_id varchar, timestamp bigint, other bigint) AS VALUES | |||
('a', NULL, NULL), | |||
('a', 1, 1), | |||
('a', -1, -1), | |||
('b', 0, 0), | |||
('c', 1, 1), | |||
('b', -2, 0), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe add some rows with a duplicate timestamp to address @avantgardnerio 's comment?
Perhaps something lke
('c', 4, 10),
('c', 2, 10),
In this PR, I have changed source table such that timestamp values are unique. Since each group consists of distinct rows, |
Which issue does this PR close?
Closes #8845.
Rationale for this change
What changes are included in this PR?
Are these changes tested?
Are there any user-facing changes?