zhengruifeng commented on code in PR #52980:
URL: https://github.com/apache/spark/pull/52980#discussion_r2512641620
##########
python/pyspark/sql/types.py:
##########
@@ -400,7 +406,9 @@ def toInternal(self, dt: datetime.datetime) -> int:
def fromInternal(self, ts: int) -> datetime.datetime:
if ts is not None:
# using int to avoid precision loss in float
- return datetime.datetime.fromtimestamp(ts //
1000000).replace(microsecond=ts % 1000000)
+ return datetime.datetime.fromtimestamp(ts // 1000000,
self.tz_info).replace(
Review Comment:
is it possible that the users change the timezone between calls of this
method?
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]