Mercurial > hg
changeset 15652:ca6accdad79c
wireproto: handle other server output in pushkey
Remote side may add useful information alongside failure return code. For
example "ssl is required". This patch mirror what is done for the unbundle
command.
author | Pierre-Yves David <pierre-yves.david@logilab.fr> |
---|---|
date | Mon, 12 Dec 2011 15:16:58 +0100 |
parents | e69a3cdad37e |
children | 93c77d5b9752 |
files | mercurial/wireproto.py |
diffstat | 1 files changed, 3 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/wireproto.py Thu Dec 15 11:45:01 2011 +0100 +++ b/mercurial/wireproto.py Mon Dec 12 15:16:58 2011 +0100 @@ -239,11 +239,14 @@ old=encoding.fromlocal(old), new=encoding.fromlocal(new)), f d = f.value + d, output = d.split('\n', 1) try: d = bool(int(d)) except ValueError: raise error.ResponseError( _('push failed (unexpected response):'), d) + for l in output.splitlines(True): + self.ui.status(_('remote: '), l) yield d @batchable