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

Rok Mihevc commented on ARROW-4258:
-----------------------------------

This issue has been migrated to [issue 
#20835|https://github.com/apache/arrow/issues/20835] on GitHub. Please see the 
[migration documentation|https://github.com/apache/arrow/issues/14542] for 
further details.

> [Python] Safe cast fails from numpy float64 array with nans to integer
> ----------------------------------------------------------------------
>
>                 Key: ARROW-4258
>                 URL: https://issues.apache.org/jira/browse/ARROW-4258
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: Python
>            Reporter: Bryan Cutler
>            Assignee: Krisztian Szucs
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 0.12.0
>
>          Time Spent: 2h 20m
>  Remaining Estimate: 0h
>
> ```
> >>> pa.Array.from_pandas(pd.Series([1, None]), type=pa.int32(), safe=True)
>  Traceback (most recent call last):
>    File "<stdin>", line 1, in <module>
>    File "pyarrow/array.pxi", line 474, in pyarrow.lib.Array.from_pandas
>    File "pyarrow/array.pxi", line 169, in pyarrow.lib.array
>    File "pyarrow/array.pxi", line 69, in pyarrow.lib._ndarray_to_array
>    File "pyarrow/error.pxi", line 81, in pyarrow.lib.check_status
>  pyarrow.lib.ArrowInvalid: Floating point value truncated
> ```



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to