From 4290cbe6a0653d1ba3458bd3a60c8b7208469afb Mon Sep 17 00:00:00 2001 From: Mike Lambert Date: Sat, 18 Mar 2017 01:04:08 +0900 Subject: [PATCH] Log the exception why we're aborting the whole mapreduce My multiple-day-long mapreduce just died. Without any retries. Without any log statements explaining why. Sigh. I'm not going to push for a retry (since arguably the preprocess would just repeatedly fail, and one can agree/disagree as to whether it should retry with the intent that the programmer fixes something on a subsequent retry). But it should at the very least log the exception, so the programmer can attempt to fix it, before he or she attempts to run the multiple-day-long mapreduce again. --- python/src/mapreduce/base_handler.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/src/mapreduce/base_handler.py b/python/src/mapreduce/base_handler.py index 8f77480d..17f358f4 100755 --- a/python/src/mapreduce/base_handler.py +++ b/python/src/mapreduce/base_handler.py @@ -128,7 +128,7 @@ def initialize(self, request, response): # pylint: disable=bare-except except: self._preprocess_success = False - logging.error( + logging.exception( "Preprocess task %s failed. Dropping it permanently.", self.request.headers["X-AppEngine-TaskName"]) self._drop_gracefully()