D3707: py3: use `b'%d' % int` instead of pycompat.bytestr

pulkit (Pulkit Goyal) phabricator at mercurial-scm.org
Sun Jun 10 10:32:45 UTC 2018


pulkit created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D3707

AFFECTED FILES
  mercurial/posix.py

CHANGE DETAILS

diff --git a/mercurial/posix.py b/mercurial/posix.py
--- a/mercurial/posix.py
+++ b/mercurial/posix.py
@@ -543,7 +543,7 @@
     try:
         return pycompat.fsencode(pwd.getpwuid(uid)[0])
     except KeyError:
-        return pycompat.bytestr(uid)
+        return b'%d' % uid
 
 def groupname(gid=None):
     """Return the name of the group with the given gid.



To: pulkit, #hg-reviewers
Cc: mercurial-devel


More information about the Mercurial-devel mailing list