diff mercurial/commands.py @ 35039:d7a4384d2d87

pull: store binary node in pullop.remotebookmarks The internal representation of bookmark value is binary. The fact we stored 'hex' was an implementation detail from using pushkey. We move the values in 'pullop.remotebookmarks' to binary before adding a way to exchange bookmarks not based on pushkey.
author Boris Feld <boris.feld@octobus.net>
date Tue, 17 Oct 2017 11:01:45 +0200
parents 6ef744a7df65
children 4b288d118d8b
line wrap: on
line diff
--- a/mercurial/commands.py	Thu Oct 19 11:46:41 2017 +0200
+++ b/mercurial/commands.py	Tue Oct 17 11:01:45 2017 +0200
@@ -3973,12 +3973,13 @@
             # not ending up with the name of the bookmark because of a race
             # condition on the server. (See issue 4689 for details)
             remotebookmarks = other.listkeys('bookmarks')
+            remotebookmarks = bookmarks.unhexlifybookmarks(remotebookmarks)
             pullopargs['remotebookmarks'] = remotebookmarks
             for b in opts['bookmark']:
                 b = repo._bookmarks.expandname(b)
                 if b not in remotebookmarks:
                     raise error.Abort(_('remote bookmark %s not found!') % b)
-                revs.append(remotebookmarks[b])
+                revs.append(hex(remotebookmarks[b]))
 
         if revs:
             try: