bundle2: also capture reply capability on failure
When unbundling over the wire is aborted, we have a mechanism to convey the
error inside a bundle part. As we add support for more errors, we need to know if
the client will support them. For this purpose, we duck punch the reply
capabilities of the client on the raised extensions.
This is similar to what is done to salvage the server output on error.
--- a/mercurial/bundle2.py Sat Jun 06 00:32:19 2015 -0700
+++ b/mercurial/bundle2.py Sat Jun 06 00:50:27 2015 -0700
@@ -347,8 +347,11 @@
# craziness in a future version.
exc.duringunbundle2 = True
salvaged = []
+ replycaps = None
if op.reply is not None:
salvaged = op.reply.salvageoutput()
+ replycaps = op.reply.capabilities
+ exc._replycaps = replycaps
exc._bundle2salvagedoutput = salvaged
raise
finally: