From 082513a80587c3732f13a89edda7c5ba4fcd8410 Mon Sep 17 00:00:00 2001 From: "Saurang Suthar(OpenERP)" <> Date: Wed, 25 Jul 2012 18:19:45 +0530 Subject: [PATCH] [IMP] Improved warning messages for resource module bzr revid: pso@tinyerp.com-20120725124945-pgebt9fh69mpb82i --- addons/resource/faces/task.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/resource/faces/task.py b/addons/resource/faces/task.py index f5240112277..81379c67240 100644 --- a/addons/resource/faces/task.py +++ b/addons/resource/faces/task.py @@ -91,8 +91,8 @@ class _IncompleteError(Exception): Exception.__init__(self, *args) else: Exception.__init__(self, - "not enough data for calculating task, "\ - "maybe you have a recursive reference", + "Not enough data for calculating task, "\ + "maybe you have a recursive reference.", *args) #@-node:__init__ #@-others @@ -1997,7 +1997,7 @@ class Task(object): except IndexError: raise AttributeError() - exception = AttributeError("'%s' is not a valid attribute of '%s'" + exception = AttributeError("'%s' is not a valid attribute of '%s'." % (name, self.path)) exception.is_frozen = self._is_frozen raise exception @@ -2925,7 +2925,7 @@ class Task(object): try: dest, dattr = self.__at_compile - raise RecursionError("Recursive definition of %s(%s) and %s(%s)" \ + raise RecursionError("Recursive definition of %s(%s) and %s(%s)." \ % (self.path, attrib_name, dest.path, dattr)) except AttributeError: pass @@ -3325,7 +3325,7 @@ class Task(object): #@+node:__assert def __assert(self, value): if not value: - warnings.warn('assertion in scenario: "%s"' % self.scenario, + warnings.warn('Assertion in scenario: "%s".' % self.scenario, RuntimeWarning, 2) #@-node:__assert #@+node:_warn