Mercurial > piecrust2
comparison piecrust/baking/worker.py @ 690:f7207f4dab82
bake: Fix a crash when a rendering error occurs.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Mon, 21 Mar 2016 19:16:54 -0700 |
parents | 61d606fbc313 |
children | 9ae9390192da |
comparison
equal
deleted
inserted
replaced
689:cd3a00455b87 | 690:f7207f4dab82 |
---|---|
166 logger.debug("Page %s was aborted." % fac.ref_spec) | 166 logger.debug("Page %s was aborted." % fac.ref_spec) |
167 result['aborted'] = True | 167 result['aborted'] = True |
168 except Exception as ex: | 168 except Exception as ex: |
169 logger.debug("Got rendering error. Sending it to master.") | 169 logger.debug("Got rendering error. Sending it to master.") |
170 result['errors'] = _get_errors(ex) | 170 result['errors'] = _get_errors(ex) |
171 if self.ctx.debug: | 171 if self.ctx.app.debug: |
172 logger.exception(ex) | 172 logger.exception(ex) |
173 finally: | 173 finally: |
174 self.app.env.abort_source_use = False | 174 self.app.env.abort_source_use = False |
175 return result | 175 return result |
176 | 176 |