From patchwork Fri Mar 2 01:53:55 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: D2524: pycompat: add support for encoding argument to our wrapper From: phabricator X-Patchwork-Id: 28642 Message-Id: <82e68dd51b6a188048a05106aed8964c@localhost.localdomain> To: mercurial-devel@mercurial-scm.org Date: Fri, 2 Mar 2018 01:53:55 +0000 This revision was automatically updated to reflect the committed changes. Closed by commit rHG3396586abdc1: pycompat: add support for encoding argument to our wrapper (authored by durin42, committed by ). REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D2524?vs=6300&id=6316 REVISION DETAIL https://phab.mercurial-scm.org/D2524 AFFECTED FILES mercurial/pycompat.py CHANGE DETAILS To: durin42, #hg-reviewers Cc: mercurial-devel diff --git a/mercurial/pycompat.py b/mercurial/pycompat.py --- a/mercurial/pycompat.py +++ b/mercurial/pycompat.py @@ -224,8 +224,8 @@ xrange = builtins.range unicode = str - def open(name, mode='r', buffering=-1): - return builtins.open(name, sysstr(mode), buffering) + def open(name, mode='r', buffering=-1, encoding=None): + return builtins.open(name, sysstr(mode), buffering, encoding) def _getoptbwrapper(orig, args, shortlist, namelist): """