Github user HyukjinKwon commented on a diff in the pull request:

    https://github.com/apache/spark/pull/20567#discussion_r167394424
  
    --- Diff: python/pyspark/sql/dataframe.py ---
    @@ -1955,38 +1967,34 @@ def toPandas(self):
                         return _check_dataframe_localize_timestamps(pdf, 
timezone)
                     else:
                         return pd.DataFrame.from_records([], 
columns=self.columns)
    -            except ImportError as e:
    -                msg = "note: pyarrow must be installed and available on 
calling Python process " \
    -                      "if using spark.sql.execution.arrow.enabled=true"
    -                raise ImportError("%s\n%s" % (_exception_message(e), msg))
    -        else:
    -            pdf = pd.DataFrame.from_records(self.collect(), 
columns=self.columns)
     
    -            dtype = {}
    +        pdf = pd.DataFrame.from_records(self.collect(), 
columns=self.columns)
    --- End diff --
    
    Actual diff here is just `else:`. It was removed and it fixes the 
indentation.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to