[ 
https://issues.apache.org/jira/browse/ARROW-10232?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17210139#comment-17210139
 ] 

Antoine Pitrou commented on ARROW-10232:
----------------------------------------

Thanks for the report. I can confirm this fails on 1.0.1, but it was fixed in 
git master (we hope to release 2.0.0 in a week or two).

> FixedSizeListArray is incorrectly written/read to/from parquet
> --------------------------------------------------------------
>
>                 Key: ARROW-10232
>                 URL: https://issues.apache.org/jira/browse/ARROW-10232
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: Python
>    Affects Versions: 1.0.1
>            Reporter: Simon Perkins
>            Priority: Major
>
> FixedSizeListArray's seem to be either incorrectly written or read to or from 
> Parquet files.
>  
> When reading the parquet file, nulls/Nones are returned where the original 
> values should be.
>  
> {code:python}
> import pyarrow as pa
> import pyarrow.parquet as pq
> import numpy as np
> np_data = np.arange(20*4).reshape(20, 4).astype(np.float64)
> pa_data = pa.FixedSizeListArray.from_arrays(np_data.ravel(), 4)
> assert np_data.tolist() == pa_data.tolist()
> schema = pa.schema([pa.field("rectangle", pa_data.type)])
> table = pa.table({"rectangle": pa_data}, schema=schema)
> pq.write_table(table, "test.parquet")
> in_table = pq.read_table("test.parquet")   
> # rectangle is filled with nulls
> assert in_table.column("rectangle").to_pylist() == pa_data.tolist()
> {code}
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to