ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/CRAB/python/Checker.py
Revision: 1.8
Committed: Fri Oct 5 12:09:51 2007 UTC (17 years, 7 months ago) by mcinquil
Content type: text/x-python
Branch: MAIN
CVS Tags: CRAB_2_1_0_pre5, CRAB_2_1_0_pre4, CRAB_2_1_0_pre3, CRAB_2_1_0_pre2, CRAB_2_1_0_pre1, CRAB_2_0_4, CRAB_2_0_4_pre2, CRAB_2_0_4_pre1, CRAB_2_0_3, CRAB_2_0_3_pre1, CRAB_2_0_2, CRAB_2_0_2_pre6, CRAB_2_0_2_pre5, CRAB_2_0_2_pre4, CRAB_2_0_2_pre3, CRAB_2_0_2_pre2, CRAB_2_0_2_pre1, CRAB_2_0_1, CRAB_2_0_1_pre1, CRAB_2_0_0
Changes since 1.7: +1 -1 lines
Log Message:
Added ce_white/black_list in glite list-match + bug fix ce_white_list

File Contents

# User Rev Content
1 slacapra 1.1 from Actor import *
2     import common
3    
4     class Checker(Actor):
5     def __init__(self, cfg_params, nj_list):
6     self.cfg_params = cfg_params
7     self.nj_list = nj_list
8     return
9    
10     def run(self):
11     """
12     The main method of the class.
13     """
14     common.logger.debug(5, "Checker::run() called")
15    
16     if len(self.nj_list)==0:
17     common.logger.debug(5, "No jobs to check")
18     return
19    
20     # run a list-match on first job
21     for nj in self.nj_list:
22 slacapra 1.7 block = common.jobDB.block(nj)
23 mcinquil 1.8 match = common.scheduler.listMatch(nj, block, [], [])
24 slacapra 1.2 flag = ''
25 afanfani 1.4 if not match:
26 slacapra 1.6 flag=' NOT '
27     number=' '
28 fanzago 1.3 if match : number= str(match)
29 slacapra 1.5 common.logger.message("Job #"+str(nj+1)+" does "+flag+" matches " + number + " sites")
30 slacapra 1.1 pass
31    
32     return