/ Published in: Python

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
import qb, datetime jobs = qb.jobinfo() for job in jobs: now = datetime.datetime.today() then = datetime.datetime.fromtimestamp(job['timesubmit']) elapsed = now-then if elapsed.days > 10 : print str(job['id']) + ':' + str(job['timesubmit']) print 'Time elapsed %d days' % (elapsed.days) qb.remove(job['id'])
Comments
