[
https://issues.apache.org/jira/browse/ARROW-17333?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
David Li updated ARROW-17333:
-----------------------------
Labels: kernel (was: )
> Unsupported cast using function cast_struct
> -------------------------------------------
>
> Key: ARROW-17333
> URL: https://issues.apache.org/jira/browse/ARROW-17333
> Project: Apache Arrow
> Issue Type: Bug
> Affects Versions: 9.0.0
> Reporter: Hyun S
> Priority: Major
> Labels: kernel
>
> Casting of structs that were introduced in ARROW-1888 no longer seems to work
> on the new 9.0.0 release. However, works on the older 8.0.0 release.
> I've included the same example given in ARROW-1888 to reproduce the error.
>
> Steps to reproduce:
> {{arr = pa.array([\\{'a': 1, 'b': None}, \\{'a': 2, 'b': None}])}}
> {{print(arr.type)}}
> {{arr.cast(pa.struct([('a', pa.int64()), ('b', pa.int64())]))}}
>
> Expected:
> {{<pyarrow.lib.StructArray object at 0x7fb475f0e460> – is_valid: all not null
> – child 0 type: int64 [ 1, 2 ] – child 1 type: int64 [ null, null ] }}
>
> Actual Results:
> {{ArrowNotImplementedError: Unsupported cast from struct<a: int64, b: null>
> to struct using function cast_struct}}
>
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)