AlenkaF commented on issue #33842: URL: https://github.com/apache/arrow/issues/33842#issuecomment-1401553189
The builtin `datetime.time` is converted to `time64` in Arrow (see https://arrow.apache.org/docs/python/pandas.html#time-types) and [pa.time64()](https://arrow.apache.org/docs/python/generated/pyarrow.time64.html) is not, as far as I understand, timezone aware. The information about the timezone is stored in [pa.timestamp()](https://arrow.apache.org/docs/python/generated/pyarrow.timestamp.html) data type which works correctly: ```python >>> dt = datetime.datetime(2023, 1, 24, 0, 12, 0, tzinfo=datetime.timezone.utc) >>> pa.array([dt]).type TimestampType(timestamp[us, tz=UTC]) >>> pa.array([dt]).to_pylist() [datetime.datetime(2023, 1, 24, 0, 12, tzinfo=<UTC>)] ``` -- 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]
