AWS Thinkbox Discussion Forums

Failed and Suspended Jobs Stat Report

Hi, I’m currently using the Deadline Monitor 10.2 version and I’m looking for a way to generate reports for Failed and suspended jobs just like the Completed Job Stats report. Is this available in any new releases or any custom script ideas?

There’s nothing in the 10.2 and later releases to do that, but you can use the Scripting API to pull job reports and from there interrogate them.

You can grab jobs and their reports like this:

from Deadline.Scripting import RepositoryUtils
def __main__():
    job_list = RepositoryUtils.GetJobs(True)

    for job in job_list:       
        job_report_collection = RepositoryUtils.GetJobReports(job.JobId) #gets an array of reports 
        print(job.JobStatus)
        for report in log_reports:#all_reports:
            str_log = get_str_log(report)

def get_str_log(report):
    log = RepositoryUtils.GetJobReportLog(report)
    str_log = unicodedata.normalize('NFKD', log).encode('ascii','ignore')

That doesn’t actually do anything at the moment, but it should get you started.

Privacy | Site terms | Cookie preferences