summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2019-03-16 07:59:48 +0100
committerMichał Górny <mgorny@gentoo.org>2019-03-16 07:59:48 +0100
commite7be5162d984d1b8d83113c539df9217105e7971 (patch)
tree709998cd610a602262d54c91eee6a0e29edd3484
parentbad2341b9861494352ef6cfa6ea3d0049148f3fc (diff)
downloadgemato-e7be5162d984d1b8d83113c539df9217105e7971.tar.gz
openpgp: Fix decoding bytestrings for debug
Bug: https://bugs.gentoo.org/680524
-rw-r--r--gemato/openpgp.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/gemato/openpgp.py b/gemato/openpgp.py
index d14c718..fd33902 100644
--- a/gemato/openpgp.py
+++ b/gemato/openpgp.py
@@ -291,7 +291,7 @@ disable-scdaemon
addrs_key.add(addr)
else:
logging.debug('refresh_keys_wkd(): ignoring UID without mail: {}'
- .format(uid))
+ .format(uid.decode('utf8')))
# grab the final set (also aborts when there are no keys)
if not addrs_key:
@@ -307,14 +307,14 @@ disable-scdaemon
# if at least one fetch failed, gpg returns unsuccessfully
if exitst != 0:
logging.debug('refresh_keys_wkd(): gpg --locate-keys failed: {}'
- .format(err))
+ .format(err.decode('utf8')))
return False
# otherwise, xfer the keys
exitst, out, err = subenv._spawn_gpg(['--export'] + list(keys), '')
if exitst != 0:
logging.debug('refresh_keys_wkd(): gpg --export failed: {}'
- .format(err))
+ .format(err.decode('utf8')))
return False
exitst, out, err = self._spawn_gpg(['--import',