# HG changeset patch # User Pulkit Goyal <7895pulkit@gmail.com> # Date 2018-02-26 18:24:40 # Node ID d478c8cd89d112dc76592a95196f82eb15511075 # Parent a918c996a881a6cd51c49d6375c17b452ede9bef py3: convert bytes to str using encoding.strfromlocal using encoding.strfromlocal because sender is provided from user config or argument. Differential Revision: https://phab.mercurial-scm.org/D2460 diff --git a/hgext/patchbomb.py b/hgext/patchbomb.py --- a/hgext/patchbomb.py +++ b/hgext/patchbomb.py @@ -748,7 +748,7 @@ def email(ui, repo, *revs, **opts): if not parent.endswith('>'): parent += '>' - sender_addr = eutil.parseaddr(sender)[1] + sender_addr = eutil.parseaddr(encoding.strfromlocal(sender))[1] sender = mail.addressencode(ui, sender, _charsets, opts.get('test')) sendmail = None firstpatch = None