From: Frederik De B. <re...@bu...> - 2010-05-25 10:36:43
|
New submission from Frederik De Bleser <fre...@pa...>: The node value is not stored under one node value if the parser divides it up into multiple chunks. I'm not sure if this is a bug or if my implementation code is wrong, but the behavior is different from CPython. In the attached example, the XML document has four lines. Java's SAX parser chunks the input into two lines at the time. Only the first two lines are stored inside childNodes[0].nodeValue. The other two are in the next child node. CPython stores everything under childNodes[0].nodeValue, even for very large node values. (I tested with 7 million characters) To reproduce: jython minidom_test.py Expected result: line1 line2 line3 line4 Actual result: line1 line2 Actual result in Python: line1 line2 line3 line4 Is this an error in the implementation or am I using minidom wrong? I'm using Mac OS X 10.6.3 with Jython: Jython 2.5.1 (Release_2_5_1:6813, Sep 26 2009, 13:47:54) [Java HotSpot(TM) 64-Bit Server VM (Apple Inc.)] on java1.6.0_20 ---------- components: Library files: minidom_test.py messages: 5776 nosy: fdb severity: normal status: open title: minidom chunks the character input on multi-line values type: behaviour versions: 2.5.1 Added file: http://bugs.jython.org/file795/minidom_test.py _______________________________________ Jython tracker <re...@bu...> <http://bugs.jython.org/issue1614> _______________________________________ |