zhengruifeng opened a new issue, #48393:
URL: https://github.com/apache/arrow/issues/48393
### Describe the bug, including details regarding any error messages,
version, and platform.
```
In [123]: import pyarrow as pa
In [124]: import datetime
In [125]: from zoneinfo import ZoneInfo
In [126]: ts = datetime.datetime(2022, 1, 5, 15, 0, 1,
tzinfo=ZoneInfo('Asia/Singapore'))
In [127]: s = pa.scalar(ts)
In [128]: s
Out[128]: <pyarrow.TimestampScalar: '2022-01-05T15:00:01.000000+0800'>
In [129]: s.as_py() == ts
Out[129]: True
In [130]:
In [130]: a = pa.array([ts])
In [131]: a
Out[131]:
<pyarrow.lib.TimestampArray object at 0x10a84f580>
[
2022-01-05 15:00:01.000000Z
]
In [132]: a.type == s.type
Out[132]: True
In [133]: a[0] == s
Out[133]: False
In [134]: a[0].as_py() == ts
Out[134]: False
In [135]: a[0].as_py()
Out[135]: datetime.datetime(2022, 1, 5, 23, 0, 1, tzinfo=<DstTzInfo
'Asia/Singapore' +08+8:00:00 STD>)
```
### Component(s)
Python
--
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]