This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ezio.melotti
Recipients Arfrever, benjamin.peterson, danken, ezio.melotti, georg.brandl, jgarrison, m-samia, pefu, python-dev, r.david.murray, techtonik, thomaslee, tod
Date 2011-11-15.10:21:32
SpamBayes Score 1.7069327e-06
Marked as misclassified No
Message-id <1321352493.31.0.122616592798.issue4147@psf.upfronthosting.co.za>
In-reply-to
Content
Here is a new patch based on Dan's last patch.
Correct me if I'm wrong, but it seems to me that it's not possible for a node to have only text-nodes as children and yet have more than one child; i.e. you can't have two or more adjacent text nodes, because they would be considered as a single text node.  I therefore changed the check with all() to check if there's only a child and if it's a text node.
I also added a test that checks where the \n and \t are added, because testing only that the DOM is preserved is not enough.
History
Date User Action Args
2011-11-15 10:21:33ezio.melottisetrecipients: + ezio.melotti, georg.brandl, pefu, techtonik, thomaslee, benjamin.peterson, Arfrever, r.david.murray, jgarrison, m-samia, danken, tod, python-dev
2011-11-15 10:21:33ezio.melottisetmessageid: <1321352493.31.0.122616592798.issue4147@psf.upfronthosting.co.za>
2011-11-15 10:21:32ezio.melottilinkissue4147 messages
2011-11-15 10:21:32ezio.melotticreate