From a1f67b92e0b782302e6bc079dadfbfa357988f4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Rapinat?= Date: Thu, 19 Mar 2015 17:39:55 +0100 Subject: [PATCH] workaround before python3 support --- po/update_po.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/po/update_po.py b/po/update_po.py index 2feac19b5..fc483569d 100644 --- a/po/update_po.py +++ b/po/update_po.py @@ -169,7 +169,10 @@ def TipsParse(filename, mark): tips = open('../data/tips.xml.in.h', 'w') marklist = root.iter(mark) for key in marklist: - tip = ElementTree.tostring(key, encoding="UTF-8") + if sys.version_info[0] < 3: + tip = ElementTree.tostring(key, encoding="UTF-8") + else: # no python3 support yet + return tip = tip.replace("", "") tip = tip.replace('\n<_tip number="%(number)s">' % key.attrib, "") tip = tip.replace("
", "
")