kvm_stat profiler: Format exception to string
PATCH 1/1 kvm_stat profiler: Format exception to string
There's a small mistake on the kvm_stat profiler:
The contents of the exception message were not
converted to a string before checking if the
problem was due to debugfs not mounted. Let's
fix that.
Signed-off-by Lucas Meneghel Rodrigues <[email protected]>
--- client/profilers/kvm_stat/kvm_stat.py | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
client/profilers/kvm_stat/kvm_stat.py +2 -2
@@ -25,11 +25,11 @@ class kvm_stat(profiler.profiler): try: utils.system_output("%s --batch" % self.stat_path) except error.CmdError, e: - if 'debugfs' in e: + if 'debugfs' in str(e): utils.system('mount -t debugfs debugfs /sys/kernel/debug') else: raise error.AutotestError('kvm_stat failed due to an ' - 'unknown reason: %s' % e) + 'unknown reason: %s' % str(e)) def start(self, test):
Signature · 1 line
1.6.5.2