Github user ueshin commented on a diff in the pull request: https://github.com/apache/spark/pull/19607#discussion_r152174813 --- Diff: python/pyspark/sql/dataframe.py --- @@ -1913,7 +1920,16 @@ def toPandas(self): for f, t in dtype.items(): pdf[f] = pdf[f].astype(t, copy=False) - return pdf + + if timezone is None: + return pdf + else: + from pyspark.sql.types import _check_series_convert_timestamps_local_tz + for field in self.schema: + if isinstance(field.dataType, TimestampType): --- End diff -- Sure, I'll add it.
--- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org