arrow-julia
arrow-julia copied to clipboard
Arrow Table doesn't implement `==` for value equality
I was surprised by this when I was writing a unit test that a function returned the expected structure.
For example:
julia> t = let io = IOBuffer(); Arrow.write(io, (v1=collect(1:10),)); seekstart(io); Arrow.Table(io) end
Arrow.Table with 10 rows, 1 columns, and schema:
:v1 Int64
julia> t2 = let io = IOBuffer(); Arrow.write(io, (v1=collect(1:10),)); seekstart(io); Arrow.Table(io) end
Arrow.Table with 10 rows, 1 columns, and schema:
:v1 Int64
julia> t == t2
false
Is the reason for this because it would be too expensive? I think users generally understand that == on large collections is expensive and should probably be avoided. Or is it because we don't want to have to implement an expensive hash() function, and we'd have to do that if we implement ==?
Thanks! :)
Yeah, I'd like for this to be defined. DataFrames has a pretty decent definition that I think we could copy.