From b3eb1856f77d2c6d85bba35c7f51fd8b2c6bae07 Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Sun, 17 Jun 2018 02:37:03 +0800 Subject: [PATCH] mgr/iostat: column_width should be int not float in python3, 3/2 is a float not intger Signed-off-by: Kefu Chai --- src/pybind/mgr/mgr_module.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pybind/mgr/mgr_module.py b/src/pybind/mgr/mgr_module.py index 1db2e71a425e..a9c0b1b211cc 100644 --- a/src/pybind/mgr/mgr_module.py +++ b/src/pybind/mgr/mgr_module.py @@ -364,7 +364,7 @@ class MgrModule(ceph_module.BaseMgrModule): :param width: the width of the terminal """ n = len(elems) - column_width = width / n + column_width = int(width / n) ret = '|' for elem in elems: @@ -380,7 +380,7 @@ class MgrModule(ceph_module.BaseMgrModule): :param width: the width of the terminal """ n = len(elems) - column_width = width / n + column_width = int(width / n) # dash line ret = '+' -- 2.47.3