# HG changeset patch # User Pierre-Yves David # Date 2014-04-22 02:42:51 # Node ID b056777221bf4e44dbd97b84ba3e086e4aa5a5c6 # Parent 372f4772f7a00e9508b39df7bf94d7f060bb516c bundle2: catch UnknownPartError during push We narrow the exception catching while unbundling the push reply. diff --git a/mercurial/exchange.py b/mercurial/exchange.py --- a/mercurial/exchange.py +++ b/mercurial/exchange.py @@ -228,7 +228,7 @@ def _pushbundle2(pushop): reply = pushop.remote.unbundle(stream, ['force'], 'push') try: op = bundle2.processbundle(pushop.repo, reply) - except KeyError, exc: + except bundle2.UnknownPartError, exc: raise util.Abort('missing support for %s' % exc) cgreplies = op.records.getreplies(cgpart.id) assert len(cgreplies['changegroup']) == 1