* morituri/extern/task/task.py:
Also stub out log calls on Runner.
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2011-08-07 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||
|
||||
* morituri/extern/task/task.py:
|
||||
Also stub out log calls on Runner.
|
||||
|
||||
2011-08-07 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||
|
||||
* morituri/extern/task/task.py:
|
||||
|
||||
19
morituri/extern/task/task.py
vendored
19
morituri/extern/task/task.py
vendored
@@ -385,13 +385,30 @@ class MultiCombinedTask(BaseMultiTask):
|
||||
self.setProgress(float(self._stopped) / len(self.tasks))
|
||||
BaseMultiTask.stopped(self, task)
|
||||
|
||||
class TaskRunner(object, log.Loggable):
|
||||
class TaskRunner(object):
|
||||
"""
|
||||
I am a base class for task runners.
|
||||
Task runners should be reusable.
|
||||
"""
|
||||
logCategory = 'TaskRunner'
|
||||
|
||||
### log stubs
|
||||
def warning(self, message, *args):
|
||||
pass
|
||||
|
||||
def info(self, message, *args):
|
||||
pass
|
||||
|
||||
def debug(self, message, *args):
|
||||
pass
|
||||
|
||||
def log(self, message, *args):
|
||||
pass
|
||||
|
||||
def error(self, message, *args):
|
||||
pass
|
||||
|
||||
|
||||
def run(self, task):
|
||||
"""
|
||||
Run the given task.
|
||||
|
||||
Reference in New Issue
Block a user