jrevels commented on issue #367: URL: https://github.com/apache/arrow-julia/issues/367#issuecomment-1363992349
Jumping to https://github.com/apache/arrow-julia/blob/0c4793871d911e185cb6a9603e577a1f52f52a22/src/ArrowTypes/src/ArrowTypes.jl#L333-L349 we can evaluate this in the REPL pretty easily, taking the branches implied: ``` julia> using Arrow.ArrowTypes: ToArrow, toarrow, ArrowType, promoteunion, concrete_or_concreteunion julia> x = t.x 1-element Vector{Union{Missing, ZonedDateTime}}: missing julia> A = typeof(x) Vector{Union{Missing, ZonedDateTime}} (alias for Array{Union{Missing, ZonedDateTime}, 1}) julia> S = eltype(A) Union{Missing, ZonedDateTime} julia> T = ArrowType(S) Union{Missing, Arrow.Timestamp} julia> concrete_or_concreteunion(T) false julia> T = typeof(toarrow(x[1])) # so this is where we get our `Missing` eltype from Missing ``` So I guess the problem here is that `ArrowType(ZonedDateTime)` is `Arrow.Timestamp`, which is non-concrete, even though `ZonedDateTime` is concrete. This explains why we don't encounter this issue with other types I tried (since their `ArrowType`s are concrete). Is it reasonable for us to make `ArrowType(ZonedDateTime)` return a concrete arrow type? I assume we'd have to pick a wide precision or something? I'll check -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
