-
Notifications
You must be signed in to change notification settings - Fork 5
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
fix bug in hashing samples #151
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.
I think this makes sense, but I think @ararslan should weigh in on whether this will mess with anything in Julia internals relying on Base.hash
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.
Looks good! And seems to make sense as it follows what is recommended in Base.hash
's docstring to implement the 2-argument form and calling it recursively to to mix the hashes of the contents with each other.
(docstring from Julia 1.9.4)
hash(x[, h::UInt]) -> UInt
Compute an integer hash code such that isequal(x,y) implies hash(x)==hash(y). The optional second argument
h is another hash code to be mixed with the result.
New types should implement the 2-argument form, typically by calling the 2-argument hash method recursively
in order to mix hashes of the contents with each other (and with h). Typically, any type that implements
hash should also implement its own == (hence isequal) to guarantee the property mentioned above. Types
supporting subtraction (operator -) should also implement widen, which is required to hash values inside
heterogeneous arrays.
The CI failure looks unrelated but concerning |
I can replicate the CI failure on a local run and it also happens on |
Tests pass on |
see #153. This is definitely something that needs to be fixed in upstream Arrow, but we have a work around that's trivial |
Just to say, I don't think there was any bug in the Arrow release, but rather in Onda we were depending on Legolas generating a specific |
The test I added fails on main:
but passes on this PR.
closes #150