changeset 37581:5b836a4c9a1f

py3: use b'%d' to convert int to bytes instead of str() Differential Revision: https://phab.mercurial-scm.org/D3280
author Pulkit Goyal <7895pulkit@gmail.com>
date Thu, 12 Apr 2018 15:22:56 +0530
parents 1c3c9211a40e
children 39ced3ef586d
files hgext/convert/git.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/convert/git.py	Thu Apr 12 15:03:15 2018 +0530
+++ b/hgext/convert/git.py	Thu Apr 12 15:22:56 2018 +0530
@@ -372,7 +372,7 @@
 
         tzs, tzh, tzm = tz[-5:-4] + "1", tz[-4:-2], tz[-2:]
         tz = -int(tzs) * (int(tzh) * 3600 + int(tzm))
-        date = tm + " " + str(tz)
+        date = tm + " " + (b"%d" % tz)
         saverev = self.ui.configbool('convert', 'git.saverev')
 
         c = common.commit(parents=parents, date=date, author=author,