1 |
|
from Actor import * |
2 |
|
from crab_exceptions import * |
3 |
|
from crab_logger import Logger |
4 |
– |
from StatusServer import StatusServer |
4 |
|
import common |
5 |
|
import string |
6 |
|
|
15 |
|
""" |
16 |
|
Check whether no job is still running or not yet retrieved |
17 |
|
""" |
18 |
< |
obj = StatusServer(self.cfg_params) |
19 |
< |
obj.run() |
20 |
< |
|
21 |
< |
pass |
18 |
> |
# get updated status from server |
19 |
> |
try: |
20 |
> |
from StatusServer import StatusServer |
21 |
> |
stat = StatusServer(self.cfg_params) |
22 |
> |
stat.resynchClientSide() |
23 |
> |
except: |
24 |
> |
pass |
25 |
|
|
26 |
|
def run(self): |
27 |
|
""" |
28 |
|
remove all |
29 |
< |
""" |
29 |
> |
|
30 |
|
if common.jobDB.nJobs()>0: |
31 |
|
self.check() |
32 |
|
|
41 |
|
print ( 'crab. directory '+tempWorkSpace+' removed' ) |
42 |
|
else: |
43 |
|
common.logger.message ( 'Impossible to remove: not all jobs are yet finished\n (you maight kill these jobs and then clean the task)') |
44 |
+ |
""" |
45 |
+ |
msg='' |
46 |
+ |
msg+='functionality not yet available for the server. Work in progres \n' |
47 |
+ |
msg+='only local worling directory will be removed' |
48 |
+ |
#msg+='planned for CRAB_2_5_0' |
49 |
+ |
common.logger.message(msg) |
50 |
+ |
common.work_space.delete() |
51 |
+ |
print 'directory '+common.work_space.topDir()+' removed' |