diff --git a/mercurial/changelog.py b/mercurial/changelog.py --- a/mercurial/changelog.py +++ b/mercurial/changelog.py @@ -404,12 +404,6 @@ class changelog(revlog.revlog): self.filteredrevs = frozenset() self._copiesstorage = opener.options.get(b'copies-storage') - def linkrev(self, rev): - """filtered version of revlog.linkrev""" - if rev in self.filteredrevs: - raise error.FilteredIndexError(rev) - return super(changelog, self).linkrev(rev) - def parentrevs(self, rev): """filtered version of revlog.parentrevs""" if rev in self.filteredrevs: diff --git a/mercurial/repoview.py b/mercurial/repoview.py --- a/mercurial/repoview.py +++ b/mercurial/repoview.py @@ -313,6 +313,12 @@ def wrapchangelog(unfichangelog, filtere raise error.FilteredIndexError(rev) return super(filteredchangelog, self).node(rev) + def linkrev(self, rev): + """filtered version of revlog.linkrev""" + if rev in self.filteredrevs: + raise error.FilteredIndexError(rev) + return super(filteredchangelog, self).linkrev(rev) + cl.__class__ = filteredchangelog return cl