* morituri/common/task.py:

Document and change name of a method.
This commit is contained in:
Thomas Vander Stichele
2011-05-24 10:39:02 +00:00
parent 8771d439dc
commit 114fb827cc
2 changed files with 11 additions and 2 deletions

View File

@@ -1,3 +1,8 @@
2011-05-24 Thomas Vander Stichele <thomas at apestaart dot org>
* morituri/common/task.py:
Document and change name of a method.
2011-05-24 Thomas Vander Stichele <thomas at apestaart dot org>
* morituri/common/gstreamer.py:

View File

@@ -117,8 +117,7 @@ class Task(object, log.Loggable):
self._notifyListeners('described', description)
self.description = description
# FIXME: does not actually raise
def setAndRaiseException(self, exception):
def setExceptionAndTraceback(self, exception):
"""
Call this to set a synthetically created exception (and not one
that was actually raised and caught)
@@ -140,8 +139,13 @@ class Task(object, log.Loggable):
self.exceptionMessage = line
self.exceptionTraceback = traceback.format_exc()
self.debug('set exception, %r' % self.exceptionMessage)
# FIXME: remove
setAndRaiseException = setExceptionAndTraceback
def setException(self, exception):
"""
Call this to set a caught exception on the task.
"""
import traceback
self.exception = exception