-
Notifications
You must be signed in to change notification settings - Fork 2
Modifications
Adrian Wilke edited this page Nov 18, 2019
·
5 revisions
- Test, if everything is executed, even on timeouts
TimeoutContinuationTest - Original code:
https://github.com/jupyter/nbgrader/blob/v0.5.4/nbgrader/converters/autograde.py#L180 - Modification:
Insert a catch block to ignore errors
def convert_single_notebook(self, notebook_filename):
self.log.info("Sanitizing %s", notebook_filename)
self._sanitizing = True
self._init_preprocessors()
super(Autograde, self).convert_single_notebook(notebook_filename)
notebook_filename = os.path.join(self.writer.build_directory, os.path.basename(notebook_filename))
self.log.info("Autograding %s", notebook_filename)
self._sanitizing = False
self._init_preprocessors()
try:
super(Autograde, self).convert_single_notebook(notebook_filename)
except:
self.log.error("Error while autograding %s", notebook_filename)
pass
finally:
self._sanitizing = True
- Original code:
https://github.com/jupyter/nbgrader/blob/v0.5.4/nbgrader/converters/base.py#L260 - Modification:
Comment out remove command
self.log.warning("NOT Removing failed assignment: {}".format(dest))
#self.log.warning("Removing failed assignment: {}".format(dest))
#rmtree(dest)
find / -name "autograde.py" | grep nbgrader
find / -name "base.py" | grep nbgrader
- on conda installations, the lib path is used (not the pkgs path)