This patch makes src/kimchi/utils.py pep8 clean, and fix the
wrong var reference of 'storage_server'.
Signed-off-by: Mark Wu <wudxw(a)linux.vnet.ibm.com>
---
Makefile.am | 1 +
src/kimchi/utils.py | 9 +++++----
2 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 9ccac0e..1ee8c1d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -56,6 +56,7 @@ PEP8_WHITELIST = \
src/kimchi/rollbackcontext.py \
src/kimchi/root.py \
src/kimchi/server.py \
+ src/kimchi/utils.py \
tests/test_mockmodel.py \
tests/test_model.py \
tests/test_plugin.py \
diff --git a/src/kimchi/utils.py b/src/kimchi/utils.py
index ae0cfac..be32195 100644
--- a/src/kimchi/utils.py
+++ b/src/kimchi/utils.py
@@ -18,7 +18,7 @@
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
#
import cherrypy
@@ -37,6 +37,7 @@ from threading import Timer
kimchi_log = cherrypy.log.error_log
+
def is_digit(value):
if isinstance(value, int):
return True
@@ -169,11 +170,11 @@ def patch_find_nfs_target(nfs_server):
try:
out = run_command(cmd, 10)[0]
except TimeoutExpired:
- kimchi_log.warning("server %s query timeout, may not have any path
exported",
- storage_server)
+ kimchi_log.warning("server %s query timeout, may not have any path "
+ "exported", nfs_server)
return list()
- targets = parse_cmd_output(out, output_items = ['target'])
+ targets = parse_cmd_output(out, output_items=['target'])
for target in targets:
target['type'] = 'nfs'
target['host_name'] = nfs_server
--
1.8.4.2