diff mercurial/localrepo.py @ 37646:72e26319f3b8

wireproto: use command executor for unbundle This also required unifying the name of the argument because the new API always passes arguments by keyword. I decided to change implementations to "bundle" instead of the interface to "cg" because "bundle" is more appropriate in a modern world. Differential Revision: https://phab.mercurial-scm.org/D3314
author Gregory Szorc <gregory.szorc@gmail.com>
date Fri, 13 Apr 2018 11:30:44 -0700
parents cc8c06835097
children a168799687e5
line wrap: on
line diff
--- a/mercurial/localrepo.py	Thu Apr 12 12:33:07 2018 -0700
+++ b/mercurial/localrepo.py	Fri Apr 13 11:30:44 2018 -0700
@@ -275,14 +275,14 @@
         raise error.Abort(_('cannot perform stream clone against local '
                             'peer'))
 
-    def unbundle(self, cg, heads, url):
+    def unbundle(self, bundle, heads, url):
         """apply a bundle on a repo
 
         This function handles the repo locking itself."""
         try:
             try:
-                cg = exchange.readbundle(self.ui, cg, None)
-                ret = exchange.unbundle(self._repo, cg, heads, 'push', url)
+                bundle = exchange.readbundle(self.ui, bundle, None)
+                ret = exchange.unbundle(self._repo, bundle, heads, 'push', url)
                 if util.safehasattr(ret, 'getchunks'):
                     # This is a bundle20 object, turn it into an unbundler.
                     # This little dance should be dropped eventually when the