Wes McKinney commented on ARROW-1345:

Looks like this might be working now (we should validate that this was broken 
in 0.8.0, and add a unit test, though)

In [9]: pa.array(pd.Series([np.array([1,2,3], dtype='i4')]))
<pyarrow.lib.ListArray object at 0x7f136c9a21d8>

however, this is a new bug/feature that merits its own JIRA:

In [11]: pa.array([np.array([1,2,3], dtype='i4')])
ArrowInvalid                              Traceback (most recent call last)
<ipython-input-11-56cfec0cffc2> in <module>()
----> 1 pa.array([np.array([1,2,3], dtype='i4')])

~/code/arrow/python/pyarrow/array.pxi in pyarrow.lib.array 

~/code/arrow/python/pyarrow/array.pxi in pyarrow.lib._sequence_to_array 

~/code/arrow/python/pyarrow/error.pxi in pyarrow.lib.check_status 

ArrowInvalid: ../src/arrow/python/builtin_convert.cc:941 code: 
InferArrowType(seq, &real_type)
../src/arrow/python/builtin_convert.cc:325 code: seq_visitor.Visit(obj)
../src/arrow/python/builtin_convert.cc:195 code: VisitElem(ref, level)
Error inferring Arrow data type for collection of Python objects. Got Python 
object of type ndarray but can only handle these types: bool, float, integer, 
date, datetime, bytes, unicode

> [Python] Conversion from nested NumPy arrays fails on integers other than 
> int64, float32
> ----------------------------------------------------------------------------------------
>                 Key: ARROW-1345
>                 URL: https://issues.apache.org/jira/browse/ARROW-1345
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: Python
>    Affects Versions: 0.8.0
>            Reporter: Wes McKinney
>            Priority: Major
>             Fix For: 0.9.0
> The inferred types are the largest ones, and then later conversion fails on 
> any arrays with smaller types because only exact conversions are implemented 
> thus far

This message was sent by Atlassian JIRA

Reply via email to