Wainberg commented on issue #40909:
URL: https://github.com/apache/arrow/issues/40909#issuecomment-2027947431

   A third example with `datetime.timedelta` and `int`, similar to the second:
   
   ```python
   >>> pa.array([1, datetime.timedelta(1)])
   Traceback (most recent call last):
     File "<stdin>", line 1, in <module>
     File "pyarrow/array.pxi", line 344, in pyarrow.lib.array
     File "pyarrow/array.pxi", line 42, in pyarrow.lib._sequence_to_array
     File "pyarrow/error.pxi", line 154, in 
pyarrow.lib.pyarrow_internal_check_status
     File "pyarrow/error.pxi", line 91, in pyarrow.lib.check_status
   pyarrow.lib.ArrowInvalid: Could not convert datetime.timedelta(days=1) with 
type datetime.timedelta: tried to convert to int64
   >>> pa.array([datetime.timedelta(1), 1])
   <pyarrow.lib.DurationArray object at 0x7fb5dd50c0a0>
   [
     86400000000,
     1
   ]
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to