You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@arrow.apache.org by "Joris Van den Bossche (Jira)" <ji...@apache.org> on 2020/10/12 12:20:00 UTC

[jira] [Created] (ARROW-10282) [Python] Conversion from custom types (eg decimal) to int dtype raises warning

Joris Van den Bossche created ARROW-10282:
---------------------------------------------

             Summary: [Python] Conversion from custom types (eg decimal) to int dtype raises warning
                 Key: ARROW-10282
                 URL: https://issues.apache.org/jira/browse/ARROW-10282
             Project: Apache Arrow
          Issue Type: Bug
          Components: Python
            Reporter: Joris Van den Bossche


{code:python}
In [2]: import decimal

In [3]: pa.array([decimal.Decimal("123456")], pa.int32())
DeprecationWarning: an integer is required (got type decimal.Decimal).  Implicit conversion to integers using __int__ is deprecated, and may be removed in a future version of Python.

Out[3]: 
<pyarrow.lib.Int32Array object at 0x7f4432032b80>
[
  123456,
]
{code}

cc [~kszucs]



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