Closed jczarnowski closed 5 years ago
I think @timonegk's latest push in #38 has this exact change in it; mayhaps it'd be simplest to use that PR and close this one, as its changes seem functionally benign, and are definite improvements towards compatibility? (This PR is still awesome in its own right, of course :) )
Haha, don't worry about that. I've pushed it only because I needed these changes and to have a clean depency on this package and didn't notice that there was a similar PR.
To be honest I've also ended up doing exact same changes as #38 when I look at it now.
This was obsoleted by #38 getting merged, so I'm going to close this out. Thanks!
As per lxml documentation (https://lxml.de/api/lxml.etree-module.html#tostring), etree.tostring() returns bytes by default, which makes this line fail (using python 3.5 and lxml 3.5):
xmlString = '<?xml version="1.0"?>\n' + xmlString