diff --git a/remotefilelog/remotefilelogserver.py b/remotefilelog/remotefilelogserver.py --- a/remotefilelog/remotefilelogserver.py +++ b/remotefilelog/remotefilelogserver.py @@ -503,10 +503,17 @@ for rev in ancestor.lazyancestors(fl.parentrevs, [fl.rev(n) for n in nodes], inclusive=True): - x, x, x, x, linkrev, p1, p2, node = fl.index[rev] + if util.safehasattr(fl, 'index'): + # 4.7 + x, x, x, x, linkrev, p1, p2, node = fl.index[rev] + p1node = fl.node(p1) + p2node = fl.node(p2) + else: + # 4.8 + linkrev = fl.linkrev(rev) + node = fl.node(rev) + p1node, p2node = fl.parents(node) copyfrom = '' - p1node = fl.node(p1) - p2node = fl.node(p2) linknode = repo.changelog.node(linkrev) if p1node == nullid: copydata = fl.renamed(node) @@ -572,7 +579,15 @@ while True: if cur in seen: break - start, length, size, base, linkrev, p1, p2, node = fl.index[cur] + if util.safehasattr(fl, 'index'): + # 4.7 + start, length, size, base, linkrev, p1, p2, node = fl.index[cur] + else: + # 4.8 + base = fl.deltaparent(cur) + linkrev = fl.linkrev(cur) + node = fl.node(cur) + p1, p2 = fl.parentrevs(cur) if linkrev < stophint and cur != startrev: break