Commit 08eff355 authored by Romain Courteaud's avatar Romain Courteaud

lxml returns unicode characters.

parent 5c0fb29a
...@@ -58,13 +58,13 @@ class SoftwareInstance(Item): ...@@ -58,13 +58,13 @@ class SoftwareInstance(Item):
tree = etree.fromstring(xml) tree = etree.fromstring(xml)
for element in tree.findall('parameter'): for element in tree.findall('parameter'):
key = element.get('id') key = element.get('id').encode("UTF-8")
value = result_dict.get(key, None) value = result_dict.get(key, None)
if value is not None: if value is not None:
value = value + ' ' + element.text value = value + ' ' + element.text
else: else:
value = element.text value = element.text
result_dict[key] = value result_dict[key] = value.encode("UTF-8")
return result_dict return result_dict
security.declareProtected(Permissions.AccessContentsInformation, security.declareProtected(Permissions.AccessContentsInformation,
......
281 282
\ No newline at end of file \ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment