Skip to content
Snippets Groups Projects
user avatar
Miss Islington (bot) authored
gh-91810: Fix regression with writing an XML declaration with encoding='unicode' (GH-93426) (GH-93791)

Suppress writing an XML declaration in open files in ElementTree.write()
with encoding='unicode' and xml_declaration=None.

If file patch is passed to ElementTree.write() with encoding='unicode',
always open a new file in UTF-8.
(cherry picked from commit d7db9dc3)

Co-authored-by: default avatarSerhiy Storchaka <storchaka@gmail.com>
893adbf0
History
Name Last commit Last update