Bug report
Bug description:
xml_doc.write(xml_path, encoding="utf-8") # \r\n
with open(xml_path, "wb") as f:
xml_doc.write(f, encoding="utf-8") # \n
Also pls add option to write newline to the end of file
CPython versions tested on:
3.12
Operating systems tested on:
No response