diff mercurial/bundle2.py @ 46780:6266d19556ad

node: introduce nodeconstants class In preparing for moving from SHA1 hashes to a modern hash function, place nullid and other constant magic vules in a class. Provide the active set of constants in the repository and push it down. Provide nullid directly in strategic places like the repository as it is accessed very often. This changeset introduces the API change, but not the mechanical replacement of the node.py attributes itself. Differential Revision: https://phab.mercurial-scm.org/D9750
author Joerg Sonnenberger <joerg@bec.de>
date Wed, 13 Jan 2021 16:14:58 +0100
parents bc2519513ae0
children ffd3e823a7e5
line wrap: on
line diff
--- a/mercurial/bundle2.py	Wed Mar 10 18:09:21 2021 +0100
+++ b/mercurial/bundle2.py	Wed Jan 13 16:14:58 2021 +0100
@@ -2146,7 +2146,7 @@
     contains binary encoded (bookmark, node) tuple. If the local state does
     not marks the one in the part, a PushRaced exception is raised
     """
-    bookdata = bookmarks.binarydecode(inpart)
+    bookdata = bookmarks.binarydecode(op.repo, inpart)
 
     msgstandard = (
         b'remote repository changed while pushing - please try again '
@@ -2376,7 +2376,7 @@
     When mode is 'records', the information is recorded into the 'bookmarks'
     records of the bundle operation. This behavior is suitable for pulling.
     """
-    changes = bookmarks.binarydecode(inpart)
+    changes = bookmarks.binarydecode(op.repo, inpart)
 
     pushkeycompat = op.repo.ui.configbool(
         b'server', b'bookmarks-pushkey-compat'