bundle2: use unbundle source as transaction name
authorPierre-Yves David <pierre-yves.david@fb.com>
Sat, 11 Apr 2015 13:58:36 -0400
changeset 24738 457e26da029b
parent 24737 b061a2049662
child 24739 ea0d5c8e047f
bundle2: use unbundle source as transaction name This is what a bundle 1 push is doing. This got caught by trying to run the whole test-suite using bundle2 for exchanges.
mercurial/exchange.py
tests/test-bundle2-exchange.t
--- a/mercurial/exchange.py	Wed Apr 15 18:34:34 2015 -0400
+++ b/mercurial/exchange.py	Sat Apr 11 13:58:36 2015 -0400
@@ -1282,7 +1282,7 @@
         # push can proceed
         if util.safehasattr(cg, 'params'):
             try:
-                tr = repo.transaction('unbundle')
+                tr = repo.transaction(source)
                 tr.hookargs['source'] = source
                 tr.hookargs['url'] = url
                 tr.hookargs['bundle2'] = '1'
--- a/tests/test-bundle2-exchange.t	Wed Apr 15 18:34:34 2015 -0400
+++ b/tests/test-bundle2-exchange.t	Sat Apr 11 13:58:36 2015 -0400
@@ -220,7 +220,7 @@
   lock:  free
   wlock: free
   postclose-tip:eea13746799a public book_eea1
-  txnclose hook: HG_BOOKMARK_MOVED=1 HG_BUNDLE2=1 HG_NEW_OBSMARKERS=1 HG_NODE=eea13746799a9e0bfd88f29d3c2e9dc9389f524f HG_PHASES_MOVED=1 HG_SOURCE=push HG_TXNNAME=unbundle HG_URL=push
+  txnclose hook: HG_BOOKMARK_MOVED=1 HG_BUNDLE2=1 HG_NEW_OBSMARKERS=1 HG_NODE=eea13746799a9e0bfd88f29d3c2e9dc9389f524f HG_PHASES_MOVED=1 HG_SOURCE=push HG_TXNNAME=push HG_URL=push
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
@@ -310,7 +310,7 @@
   remote: lock:  free
   remote: wlock: free
   remote: postclose-tip:5fddd98957c8 draft book_5fdd
-  remote: txnclose hook: HG_BOOKMARK_MOVED=1 HG_BUNDLE2=1 HG_NEW_OBSMARKERS=1 HG_NODE=5fddd98957c8a54a4d436dfe1da9d87f21a1b97b HG_SOURCE=serve HG_TXNNAME=unbundle HG_URL=remote:ssh:127.0.0.1
+  remote: txnclose hook: HG_BOOKMARK_MOVED=1 HG_BUNDLE2=1 HG_NEW_OBSMARKERS=1 HG_NODE=5fddd98957c8a54a4d436dfe1da9d87f21a1b97b HG_SOURCE=serve HG_TXNNAME=serve HG_URL=remote:ssh:127.0.0.1
   pre-close-tip:02de42196ebe draft book_02de
   postclose-tip:02de42196ebe draft book_02de
   txnclose hook: HG_SOURCE=push-response HG_TXNNAME=push-response