You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "spenczar (via GitHub)" <gi...@apache.org> on 2023/08/08 22:46:40 UTC
[GitHub] [arrow] spenczar commented on issue #37072: null structarrays are poorly handled by cast
spenczar commented on issue #37072:
URL: https://github.com/apache/arrow/issues/37072#issuecomment-1670413898
With a bit more inspection, I'm now wondering if the blame really lies with `pa.nulls` (so, the C++ function `MakeArrayOfNull`).
If I do this:
```py
nulls = pa.array([None, None, None, None, None], struct_type)
```
Then everything works fine!
```py
nulls = nulls.cast(struct_type)
print(nulls)
-- is_valid:
[
false,
false,
false,
false,
false
]
-- child 0 type: int32
[
null,
null,
null,
null,
null
]
```
--
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: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org