From: Daniel Martí Date: Mon, 4 Jan 2016 20:10:18 +0000 (+0100) Subject: update: fix encoding issues with the xml index X-Git-Tag: 0.7.0~86^2~17 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=a1703f12040fc27cfb20b5ecb443347e230c5bfd;p=fdroidserver.git update: fix encoding issues with the xml index --- diff --git a/fdroidserver/update.py b/fdroidserver/update.py index de75848d..0e0aef68 100644 --- a/fdroidserver/update.py +++ b/fdroidserver/update.py @@ -826,7 +826,7 @@ def make_index(apps, sortedids, apks, repodir, archive, categories): logging.warning("\tfdroid update --create-key") sys.exit(1) - repoel.setAttribute("pubkey", extract_pubkey()) + repoel.setAttribute("pubkey", extract_pubkey().decode('utf-8')) root.appendChild(repoel) for appid in sortedids: @@ -966,9 +966,9 @@ def make_index(apps, sortedids, apks, repodir, archive, categories): os.symlink(sigfile_path, siglinkname) if options.pretty: - output = doc.toprettyxml() + output = doc.toprettyxml(encoding='utf-8') else: - output = doc.toxml() + output = doc.toxml(encoding='utf-8') with open(os.path.join(repodir, 'index.xml'), 'wb') as f: f.write(output)