[Erp5-report] r30135 - /erp5/trunk/products/ERP5Type/patches/DCWorkflow.py

nobody at svn.erp5.org nobody at svn.erp5.org
Thu Oct 29 18:34:58 CET 2009


Author: romain
Date: Thu Oct 29 18:34:55 2009
New Revision: 30135

URL: http://svn.erp5.org?rev=30135&view=rev
Log:
Copy the error message, in order to prevent this persistent object to be stored
in multiple workflow history (in case of workflow script calling a workflow
transition on another object).

Modified:
    erp5/trunk/products/ERP5Type/patches/DCWorkflow.py

Modified: erp5/trunk/products/ERP5Type/patches/DCWorkflow.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Type/patches/DCWorkflow.py?rev=30135&r1=30134&r2=30135&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Type/patches/DCWorkflow.py [utf8] (original)
+++ erp5/trunk/products/ERP5Type/patches/DCWorkflow.py [utf8] Thu Oct 29 18:34:55 2009
@@ -34,6 +34,7 @@
 import sys
 from zLOG import LOG
 from Acquisition import aq_base
+from copy import deepcopy
 
 # Patch WorkflowUIMixin to add description on workflows
 from Products.DCWorkflow.WorkflowUIMixin import WorkflowUIMixin as WorkflowUIMixin_class
@@ -330,7 +331,7 @@
             script(sci)  # May throw an exception.
         except ValidationFailed, validation_exc:
             before_script_success = 0
-            before_script_error_message = validation_exc.msg
+            before_script_error_message = deepcopy(validation_exc.msg)
             validation_exc_traceback = sys.exc_traceback
         except ObjectMoved, moved_exc:
             ob = moved_exc.getNewObject()




More information about the Erp5-report mailing list