Achim Gaedke <achim.gae...@physik.tu-darmstadt.de> added the comment:

sorry, the output given before was generated with python2.7

changing the line
xml.sax.parseString(xml_data, d_handler)

to

xml.sax.parseString(bytes(xml_data, "utf-8"), d_handler)

makes it working for python 3.2, result the same:

$ python3.2 pulldom_test.py
with pulldom
<xml.dom.minidom.Document object at 0x9bf9f2c> []
with minidom
<xml.dom.minidom.Document object at 0x9c2fccc> [<DOM Text node "'\n'">, <DOM 
Element: a at 0x9c3850c>, <DOM Text node "'\n'">, <DOM Element: b at 
0x9c3856c>, <DOM Text node "'\n'">, <DOM Element: c at 0x9c385cc>, <DOM Text 
node "'\n'">]

Both test were done on debian testing/wheezy.

$ python3.2 -V
Python 3.2.2rc1
$ python -V
Python 2.7.2+

----------
versions: +Python 2.7
Added file: http://bugs.python.org/file23874/pulldom_test.py

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue13551>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to