changeset 24:7b1720b6acf2

remove extra files
author Catherine Wise <catherine.wise@csiro.au>
date Tue, 14 Jan 2014 15:49:55 +1100
parents cf4cf95e6678
children 20dc961b7949
files TrustStoreGalaxyImport.py
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/TrustStoreGalaxyImport.py	Mon Jan 13 09:21:20 2014 +1100
+++ b/TrustStoreGalaxyImport.py	Tue Jan 14 15:49:55 2014 +1100
@@ -2,6 +2,7 @@
 import shutil
 import gzip
 import tempfile
+import os
 from py_ts import TrustStoreClient, ts_utils
 from galaxy.datatypes.checkers import *
 
@@ -82,6 +83,10 @@
                         gzipped_file.close()
 
                         shutil.copy(uncompressed, outputFile)
+                        try:
+                            os.remove(uncompressed)
+                        except OSError:
+                                pass
                     else:
                         shutil.copy(download, outputFile)
                 else: