add support for utf8 in sequences, verticals and custom modules.

This commit is contained in:
Brian Wilson
2012-12-04 03:54:36 -05:00
parent 5b02e1e3ce
commit 4ebd70dcc4
21 changed files with 35 additions and 44 deletions

View File

@@ -22,7 +22,7 @@ def stringify_children(node):
# next element.
parts = [node.text]
for c in node.getchildren():
parts.append(etree.tostring(c, with_tail=True))
parts.append(etree.tostring(c, with_tail=True, encoding='unicode'))
# filter removes possible Nones in texts and tails
return ''.join(filter(None, parts))
return u''.join(filter(None, parts))