bundle2: catch UnknownPartError during push stable
authorPierre-Yves David <pierre-yves.david@fb.com>
Mon, 21 Apr 2014 19:42:51 -0700
branchstable
changeset 21180 b056777221bf
parent 21179 372f4772f7a0
child 21181 a92619a2dbd7
bundle2: catch UnknownPartError during push We narrow the exception catching while unbundling the push reply.
mercurial/exchange.py
--- a/mercurial/exchange.py	Mon Apr 21 19:42:40 2014 -0700
+++ b/mercurial/exchange.py	Mon Apr 21 19:42:51 2014 -0700
@@ -228,7 +228,7 @@
     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