Mercurial > public > mercurial-scm > hg
diff mercurial/wireproto.py @ 36945:4901d1e22b27
peer-request: include more details about batch commands
A batch commands encapsulate multiple other commands. We display a bit more
details about what is actually batched if peer request tracking is set.
author | Boris Feld <boris.feld@octobus.net> |
---|---|
date | Mon, 05 Mar 2018 11:48:28 -0500 |
parents | ef68493d652b |
children | d683c7367989 |
line wrap: on
line diff
--- a/mercurial/wireproto.py Wed Mar 14 15:56:34 2018 -0400 +++ b/mercurial/wireproto.py Mon Mar 05 11:48:28 2018 -0500 @@ -400,6 +400,13 @@ Returns an iterator of the raw responses from the server. """ + ui = self.ui + if ui.debugflag and ui.configbool('devel', 'debug.peer-request'): + ui.debug('devel-peer-request: batched-content\n') + for op, args in req: + msg = 'devel-peer-request: - %s (%d arguments)\n' + ui.debug(msg % (op, len(args))) + rsp = self._callstream("batch", cmds=encodebatchcmds(req)) chunk = rsp.read(1024) work = [chunk]