# HG changeset patch # User Boris Feld # Date 1502290881 -7200 # Node ID 119e1c6be1ce94b36376681e975477e627b62c17 # Parent dd35abc409ee1c4fa83bed2d53d9896594a3dc88 bundle2: fix transaction availability detection Changeset 5fc4ddfbe626 introduce more complex logic around 'bundleoperation.gettransaction'. In that process it turns the old "attribute" into a proper method which breaks the code that detects the "transaction availability". The change was visible in 'test-acl.t', fixing this reverts the test changes. Differential Revision: https://phab.mercurial-scm.org/D303 diff -r dd35abc409ee -r 119e1c6be1ce mercurial/bundle2.py --- a/mercurial/bundle2.py Thu Aug 10 09:37:50 2017 -0700 +++ b/mercurial/bundle2.py Wed Aug 09 17:01:21 2017 +0200 @@ -373,7 +373,7 @@ msg = ['bundle2-input-bundle:'] if unbundler.params: msg.append(' %i params' % len(unbundler.params)) - if op.gettransaction is None or op.gettransaction is _notransaction: + if op._gettransaction is None or op._gettransaction is _notransaction: msg.append(' no-transaction') else: msg.append(' with-transaction') diff -r dd35abc409ee -r 119e1c6be1ce tests/test-acl.t --- a/tests/test-acl.t Thu Aug 10 09:37:50 2017 -0700 +++ b/tests/test-acl.t Wed Aug 09 17:01:21 2017 +0200 @@ -120,7 +120,7 @@ bundle2-output-bundle: "HG20", 2 parts total bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-bundle: 1 parts total @@ -184,7 +184,7 @@ bundle2-output-bundle: "HG20", 2 parts total bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-bundle: 1 parts total @@ -259,7 +259,7 @@ bundle2-output-bundle: "HG20", 2 parts total bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-bundle: 1 parts total @@ -742,7 +742,7 @@ bundle2-output-bundle: "HG20", 2 parts total bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-bundle: 1 parts total @@ -1056,7 +1056,7 @@ bundle2-output-bundle: "HG20", 2 parts total bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-bundle: 1 parts total @@ -1141,7 +1141,7 @@ bundle2-output-bundle: "HG20", 2 parts total bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-bundle: 1 parts total @@ -1298,7 +1298,7 @@ bundle2-output-bundle: "HG20", 2 parts total bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-bundle: 1 parts total @@ -1502,7 +1502,7 @@ bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported @@ -1798,7 +1798,7 @@ bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported @@ -1891,7 +1891,7 @@ bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported @@ -2052,7 +2052,7 @@ bundle2-output-part: "reply:changegroup" (advisory) (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload bundle2-output-part: "reply:pushkey" (params: 0 advisory) empty payload - bundle2-input-bundle: with-transaction + bundle2-input-bundle: no-transaction bundle2-input-part: "reply:changegroup" (advisory) (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported bundle2-input-part: "reply:pushkey" (params: 0 advisory) supported