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

Comparing COMP/CRAB/python/DBinterface.py (file contents):
Revision 1.36 by mcinquil, Thu Jun 19 11:12:00 2008 UTC vs.
Revision 1.37 by farinafa, Thu Jun 19 15:12:01 2008 UTC

# Line 324 | Line 324 | class DBinterface:
324          for job in task.jobs:
325              if not job.runningJob:
326                  raise CrabException( "Missing running object for job %s"%str(job['jobId']) )
327 +
328              id = str(job.runningJob['jobId'])
329              rForJ = None
330              nj_list= []
# Line 345 | Line 346 | class DBinterface:
346              for r in reportList:
347                  if r.getAttribute('id') in [ id, 'all']:
348                      rForJ = r
349 <                    break  
349 >                    break
350 >
351              # Data alignment
350            jobStatus = str(job.runningJob['statusScheduler'])
352              if str(job.runningJob['status']) != 'EE':
353                  if rForJ.getAttribute('status') not in ['Created', 'Submitting', 'Unknown'] and \
354 <                         job.runningJob['statusScheduler'] != 'Cleared':
354 >                   job.runningJob['statusScheduler'] != 'Cleared' and \
355 >                   not (job.runningJob['statusScheduler'] == 'Killing' and rForJ.getAttribute('statusScheduler')!='Killed'):
356 >                       # update the status  
357                      common.logger.debug(3,"Updating DB status for job: " + str(id) + " @: " \
358                                            + str(rForJ.getAttribute('status')) )
359                      job.runningJob['statusScheduler'] = str( rForJ.getAttribute('status') )
357                    jobStatus = str(job.runningJob['statusScheduler'])
360                      job.runningJob['status'] = str( rForJ.getAttribute('sched_status') )
361            
362                  job.runningJob['destination'] = str( rForJ.getAttribute('site') )

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines