# HG changeset patch # User Gregory Szorc # Date 1518654913 25200 # Node ID b67d4b7e8235a1c5d16a2885801d21bf670d3b03 # Parent 7a46f07359044b706747d5947cebeccca2280a22 py3: stringify integer with %d instead of bytes() The unbundle wire protocol command now returns a properly formatted reply in Python 3. Differential Revision: https://phab.mercurial-scm.org/D2274 diff -r 7a46f0735904 -r b67d4b7e8235 mercurial/wireprotoserver.py --- a/mercurial/wireprotoserver.py Wed Feb 14 17:23:26 2018 -0700 +++ b/mercurial/wireprotoserver.py Wed Feb 14 17:35:13 2018 -0700 @@ -445,7 +445,7 @@ _sshv1respondstream(self._fout, rsp) elif isinstance(rsp, wireprototypes.pushres): _sshv1respondbytes(self._fout, b'') - _sshv1respondbytes(self._fout, bytes(rsp.res)) + _sshv1respondbytes(self._fout, b'%d' % rsp.res) elif isinstance(rsp, wireprototypes.pusherr): _sshv1respondbytes(self._fout, rsp.res) elif isinstance(rsp, wireprototypes.ooberror):