hgext/largefiles/wirestore.py
changeset 37632 6c55ce51d6c3
parent 29316 28dfcf3d0ad3
child 43076 2372284d9457
--- a/hgext/largefiles/wirestore.py	Fri Apr 13 11:02:34 2018 -0700
+++ b/hgext/largefiles/wirestore.py	Fri Apr 13 11:08:46 2018 -0700
@@ -32,8 +32,12 @@
         '''For each hash, return 0 if it is available, other values if not.
         It is usually 2 if the largefile is missing, but might be 1 the server
         has a corrupted copy.'''
-        batch = self.remote.iterbatch()
-        for hash in hashes:
-            batch.statlfile(hash)
-        batch.submit()
-        return dict(zip(hashes, batch.results()))
+
+        with self.remote.commandexecutor() as e:
+            fs = []
+            for hash in hashes:
+                fs.append((hash, e.callcommand('statlfile', {
+                    'sha': hash,
+                })))
+
+            return {hash: f.result() for hash, f in fs}