From f35398d32d4cbff242c4d16fa4e757d383a51dc5 Mon Sep 17 00:00:00 2001 From: Navan Chauhan Date: Sun, 27 Sep 2020 01:14:19 +0530 Subject: corrected exception --- app/dock-single.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/dock-single.py') diff --git a/app/dock-single.py b/app/dock-single.py index 024cd8f..54ade78 100644 --- a/app/dock-single.py +++ b/app/dock-single.py @@ -228,7 +228,7 @@ with tempfile.TemporaryDirectory() as directory: make_archive(zi, 'zip', directory) try: copyfile("report.pdf",os.path.join(reportDirectory,(str(jobID)+".pdf"))) - except: + except FileNotFoundError: reason = "Could not generate the report, this could be because of a failed docking job. Please check the ZIP archive for the configuration and converted PDBQTs and try submitting manually. " email(toaddr,jobID,date,description,zipArchive=zi,reason=reason) mycursor.execute('UPDATE curieweb set done=1 where id="%s"' % (jobID)) -- cgit v1.2.3