ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/CRAB/python/WorkSpace.py
(Generate patch)

Comparing COMP/CRAB/python/WorkSpace.py (file contents):
Revision 1.32 by spiga, Sat Mar 7 16:31:09 2009 UTC vs.
Revision 1.33 by slacapra, Tue May 26 12:53:56 2009 UTC

# Line 1 | Line 1
1   from crab_exceptions import *
2 < #from threading import RLock
2 > import logging
3   import common
4 < import os, shutil, string, time
4 > import os, string, time
5  
6   class WorkSpace:
7      def __init__(self, top_dir, cfg_params):
# Line 94 | Line 94 | class WorkSpace:
94          """
95          delete the whole workspace without doing any test!!!
96          """
97 <        common.logger.quiet(1)
98 <        common.logger.close()
97 >        logging.shutdown()
98          if os.path.exists(self._top_dir):
99 < #            shutil.rmtree(self._top_dir)
100 <            # os.system("/usr/sbin/lsof %s/crab.log" % self._log_dir )
102 <            os.system("rm -rf %s" % self._top_dir )
103 <            # SL For some obscure reason the lgo dir is not removed at the first try
104 <            os.system("rm -rf %s" % self._top_dir )
99 >            import shutil
100 >            shutil.rmtree(self._top_dir)
101              pass
102          return
103  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines