Yu Ishikawa created SPARK-8511:
----------------------------------

             Summary: Modify a test to remove a saved model in `regression.py`
                 Key: SPARK-8511
                 URL: https://issues.apache.org/jira/browse/SPARK-8511
             Project: Spark
          Issue Type: Improvement
          Components: PySpark
            Reporter: Yu Ishikawa


According to the reference of python, {{os.removedirs}} doesn't work if there 
are any files in the directory we want to remove.
https://docs.python.org/3/library/os.html#os.removedirs

Instead of that, using `shutil.rmtree()` would be better to remove a temporary 
directory to test for saving model.
https://github.com/apache/spark/blob/branch-1.4/python%2Fpyspark%2Fmllib%2Fregression.py#L137



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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

Reply via email to