rawdata: update callers in lfs' wrapper
authorPierre-Yves David <pierre-yves.david@octobus.net>
Wed, 07 Aug 2019 20:10:32 +0200
changeset 42791 f972f43badb3
parent 42790 da643cadec90
child 42792 5769ed8fa5f4
rawdata: update callers in lfs' wrapper We update callers incrementally because this help bisecting failures. This was useful during development, so we expect it might be useful again in the future.
hgext/lfs/wrapper.py
--- a/hgext/lfs/wrapper.py	Wed Aug 07 20:10:24 2019 +0200
+++ b/hgext/lfs/wrapper.py	Wed Aug 07 20:10:32 2019 +0200
@@ -169,7 +169,7 @@
 # Wrapping may also be applied by remotefilelog
 def filelogrenamed(orig, self, node):
     if _islfs(self, node):
-        rawtext = self._revlog.revision(node, raw=True)
+        rawtext = self._revlog.rawdata(node)
         if not rawtext:
             return False
         metadata = pointer.deserialize(rawtext)
@@ -183,7 +183,7 @@
 def filelogsize(orig, self, rev):
     if _islfs(self, rev=rev):
         # fast path: use lfs metadata to answer size
-        rawtext = self._revlog.revision(rev, raw=True)
+        rawtext = self._revlog.rawdata(rev)
         metadata = pointer.deserialize(rawtext)
         return int(metadata['size'])
     return orig(self, rev)