D316: largefiles: remove remotestore.batch()

indygreg (Gregory Szorc) phabricator at mercurial-scm.org
Thu Aug 10 06:47:29 UTC 2017


indygreg created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  This method was added in https://phab.mercurial-scm.org/rHG9e1616307c4cca80d177203afc39e5eecda60c84. AFAICT it didn't do anything at
  inception. If it did, there was no test coverage for it because
  changing it to raise doesn't fail any tests at that revision.
  
  https://phab.mercurial-scm.org/rHGb6e71f8af5b8710139b64706a375b3f16eb1241e later refactored all remote.batch() calls to
  remote.iterbatch(). So if this was somehow used, it isn't called
  any more because there are no calls to .batch() remaining in the
  repo.
  
  I suspect the original patch author got confused by the distinction
  between the peer/remote interface and the largefiles store. The lf
  store is a gateway to a peer instance. It exposes additional
  lf-specific methods to execute against a peer. However, it is not
  a peer and doesn't need to implement batch() because peer itself
  does that.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D316

AFFECTED FILES
  hgext/largefiles/remotestore.py

CHANGE DETAILS

diff --git a/hgext/largefiles/remotestore.py b/hgext/largefiles/remotestore.py
--- a/hgext/largefiles/remotestore.py
+++ b/hgext/largefiles/remotestore.py
@@ -109,10 +109,6 @@
                                            'from statlfile (%r)' % stat)
         return failed
 
-    def batch(self):
-        '''Support for remote batching.'''
-        return wireproto.remotebatch(self)
-
     def _put(self, hash, fd):
         '''Put file with the given hash in the remote store.'''
         raise NotImplementedError('abstract method')



To: indygreg, #hg-reviewers
Cc: mercurial-devel


More information about the Mercurial-devel mailing list