blob: 863375c4e385109767bbb2467984be7dd9e8f5f6 [file] [log] [blame]
import sys
import common
from autotest_lib.server import frontend
_AFE = frontend.AFE(debug=False)
def is_job_complete(job_id):
Check if a job is no longer active.
@param job_id: afe job id like 123 from 123-scottz
@return True if job is complete and False if it is not
if not'get_jobs', finished=True, id=job_id):
return 1
return 0
if __name__ == '__main__':
if len(sys.argv) != 2:
print ('Set return status to 0 if job is complete or 1 if it is not.\n'
'Usage: <job_id>')