summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKubi <jean.gaoliang@huawei.com>2017-07-06 03:58:19 +0000
committerGerrit Code Review <gerrit@opnfv.org>2017-07-06 03:58:19 +0000
commit69049e54f6b6611bdaa9dbab9e6dc6a123583251 (patch)
tree527e850fb25ccaa4cfc0e9ad7f1d22d77f44d122
parent3369461d0e51b22aa96e5bfd0d80b3f0f7f82c67 (diff)
parent54efd531034af64f84836757a6b12f5541736a72 (diff)
Merge "show actual exceptions in task.py"
-rw-r--r--yardstick/cmd/commands/task.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/yardstick/cmd/commands/task.py b/yardstick/cmd/commands/task.py
index 0f98cabdc..03f6b1b1e 100644
--- a/yardstick/cmd/commands/task.py
+++ b/yardstick/cmd/commands/task.py
@@ -11,6 +11,8 @@
from __future__ import print_function
from __future__ import absolute_import
+import logging
+
from yardstick.benchmark.core.task import Task
from yardstick.common.utils import cliargs
from yardstick.common.utils import write_json_to_file
@@ -19,6 +21,9 @@ from yardstick.cmd.commands import change_osloobj_to_paras
output_file_default = "/tmp/yardstick.out"
+LOG = logging.getLogger(__name__)
+
+
class TaskCommands(object): # pragma: no cover
"""Task commands.
@@ -49,7 +54,7 @@ class TaskCommands(object): # pragma: no cover
Task().start(param, **kwargs)
except Exception as e:
self._write_error_data(e)
- raise
+ LOG.exception("")
def _write_error_data(self, error):
data = {'status': 2, 'result': str(error)}