Misc UI work. Colored jobs. Error handling.

This commit is contained in:
Brett Williams
2023-05-31 22:17:47 -05:00
parent 4cb1bff76e
commit f039bfae35
2 changed files with 41 additions and 25 deletions

View File

@@ -110,7 +110,11 @@ def get_job_file(job_id, filename):
@server.get('/api/jobs')
def jobs_json():
return [x.json() for x in RenderQueue.all_jobs()]
try:
return [x.json() for x in RenderQueue.all_jobs()]
except Exception as e:
logger.exception(f"Exception fetching all_jobs: {e}")
return [], 500
@server.get('/api/jobs/<status_val>')