From 65f73c66cb104063b9d5bbd3dfc199ba091e8991 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tun=C3=A7=20K=C3=B6se?= Date: Mon, 13 Mar 2023 10:08:06 +0200 Subject: [PATCH] Don't skip the assignment if a notebook raises an exception --- nbgrader/converters/base.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nbgrader/converters/base.py b/nbgrader/converters/base.py index 3d9632866..209a6dabf 100644 --- a/nbgrader/converters/base.py +++ b/nbgrader/converters/base.py @@ -391,7 +391,7 @@ def _handle_failure(gd: typing.Dict[str, str]) -> None: self.convert_single_notebook(notebook_filename) # Exceptions that shouldn't interrupt the entire conversion process should go here - # Those that should go in outer try/except + # Those that should interrupt go in the outer try/except except UnresponsiveKernelError: self.log.error( "While processing assignment %s, the kernel became " @@ -405,6 +405,7 @@ def _handle_failure(gd: typing.Dict[str, str]) -> None: errors.append((gd['assignment_id'], gd['student_id'])) _handle_failure(gd) + # Raise unhandled exceptions for the outer try/except except Exception as e: raise e