Mercurial > hg
comparison hgext/remotefilelog/shallowbundle.py @ 42782:1d9031b6cb7e
rawdata: update callers in shallowbundle
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.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Wed, 07 Aug 2019 20:12:07 +0200 |
parents | 0531dff73d0b |
children | 2372284d9457 |
comparison
equal
deleted
inserted
replaced
42781:aeb2be20b33b | 42782:1d9031b6cb7e |
---|---|
122 return results | 122 return results |
123 | 123 |
124 def nodechunk(self, revlog, node, prevnode, linknode): | 124 def nodechunk(self, revlog, node, prevnode, linknode): |
125 prefix = '' | 125 prefix = '' |
126 if prevnode == nullid: | 126 if prevnode == nullid: |
127 delta = revlog.revision(node, raw=True) | 127 delta = revlog.rawdata(node) |
128 prefix = mdiff.trivialdiffheader(len(delta)) | 128 prefix = mdiff.trivialdiffheader(len(delta)) |
129 else: | 129 else: |
130 # Actually uses remotefilelog.revdiff which works on nodes, not revs | 130 # Actually uses remotefilelog.revdiff which works on nodes, not revs |
131 delta = revlog.revdiff(prevnode, node) | 131 delta = revlog.revdiff(prevnode, node) |
132 p1, p2 = revlog.parents(node) | 132 p1, p2 = revlog.parents(node) |
265 node, p1, p2, linknode, deltabase, delta, flags = revisiondata | 265 node, p1, p2, linknode, deltabase, delta, flags = revisiondata |
266 | 266 |
267 if not available(f, node, f, deltabase): | 267 if not available(f, node, f, deltabase): |
268 continue | 268 continue |
269 | 269 |
270 base = fl.revision(deltabase, raw=True) | 270 base = fl.rawdata(deltabase) |
271 text = mdiff.patch(base, delta) | 271 text = mdiff.patch(base, delta) |
272 if not isinstance(text, bytes): | 272 if not isinstance(text, bytes): |
273 text = bytes(text) | 273 text = bytes(text) |
274 | 274 |
275 meta, text = shallowutil.parsemeta(text) | 275 meta, text = shallowutil.parsemeta(text) |