diff -r cc497780eaf9 -r e530cde6d115 mercurial/exchange.py --- a/mercurial/exchange.py Tue Feb 03 15:01:43 2015 -0500 +++ b/mercurial/exchange.py Tue Apr 28 17:38:02 2015 -0700 @@ -1285,6 +1285,11 @@ # need a transaction when processing a bundle2 stream wlock = lock = tr = None recordout = None + # quick fix for output mismatch with bundle2 in 3.4 + captureoutput = repo.ui.configbool('experimental', 'bundle2-output-capture', + False) + if url.startswith('remote:http:') or url.startswith('remote:https:'): + captureoutput = True try: check_heads(repo, heads, 'uploading changes') # push can proceed @@ -1297,19 +1302,20 @@ tr.hookargs['source'] = source tr.hookargs['url'] = url tr.hookargs['bundle2'] = '1' - op = bundle2.bundleoperation(repo, lambda: tr) + op = bundle2.bundleoperation(repo, lambda: tr, + captureoutput=captureoutput) try: r = bundle2.processbundle(repo, cg, op=op) finally: r = op.reply - if r is not None: + if captureoutput and r is not None: repo.ui.pushbuffer(error=True, subproc=True) def recordout(output): r.newpart('output', data=output, mandatory=False) tr.close() except Exception, exc: exc.duringunbundle2 = True - if r is not None: + if captureoutput and r is not None: parts = exc._bundle2salvagedoutput = r.salvageoutput() def recordout(output): part = bundle2.bundlepart('output', data=output,