From: Ondrej Lichtner <olichtne(a)redhat.com>
Pylint complained that iter_key was undefined, this is a mistake caused
by copy pasting code from list_to_dot. This patch fixes the issue.
Signed-off-by: Ondrej Lichtner <olichtne(a)redhat.com>
---
lnst/Common/Utils.py | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/lnst/Common/Utils.py b/lnst/Common/Utils.py
index 727f82a..c2fabd1 100644
--- a/lnst/Common/Utils.py
+++ b/lnst/Common/Utils.py
@@ -250,7 +250,9 @@ def dict_to_dot(original_dict, prefix=""):
elif isinstance(value, tuple):
#TODO temporary fix, tuples shouldn't be here
if len(value) == 2:
- return_list.append((iter_key+'.'+value[0], value[1]))
+ return_list.append((prefix+key,
+ "(%s, %s)" % (value[0],
+ value[1]) ))
else:
return_list.append((prefix+key, str(value)))
return return_list
--
2.6.2