From 47a95fc6b6a2c761ed940860055a60a3b9543fed Mon Sep 17 00:00:00 2001 From: Gaetan Delannay Date: Wed, 24 Feb 2010 18:28:37 +0100 Subject: [PATCH] When a computed method raises an exception, full traceback is now logged. --- gen/plone25/mixins/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gen/plone25/mixins/__init__.py b/gen/plone25/mixins/__init__.py index 3acbaaf..d23df89 100644 --- a/gen/plone25/mixins/__init__.py +++ b/gen/plone25/mixins/__init__.py @@ -7,6 +7,7 @@ # ------------------------------------------------------------------------------ import os, os.path, sys, types, mimetypes +from appy.shared.utils import Traceback import appy.gen from appy.gen import String, Selection from appy.gen.utils import FieldDescr, GroupDescr, PhaseDescr, StateDescr, \ @@ -715,6 +716,7 @@ class AbstractMixin: if not isinstance(res, basestring): res = repr(res) except Exception, e: + obj.log(Traceback.get(), type='error') res = str(e) return res