quinnj opened a new pull request, #465:
URL: https://github.com/apache/arrow-julia/pull/465
Fixes #461. The issue here is that in the conversion from a column of a
struct that had a field with type `Union{T, Missing}` where `T` was a type that
had any `Tuple{Vararg}` fieldtypes, then the ArrowTypes.default call blew up
(fieldcount not defined). To resolve, we _could_ try to define a `default` for
`Tuple{Vararg}`, but that seemed pretty messy and relying on some pretty deep
reflection internals that aren't well-exposed (`T.parameters[end] isa
Core.TypeofVararg`!), so the alternative proposed here is that to get a struct
fields default value, we actually call the `default` on the entire struct and
get the default from that. I think this should be more robust because we have
pretty sensible `default`s (pun intended) on most types, but when it comes to
_field types_ specifically, there are a lot of weird edge cases that are just
hard to handle, like vararg fields. In this way, we don't try to mess with
field type directly and instead rely on being able to get the `default` o
f the parent struct on the way down.
--
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]