# HG changeset patch # User Pierre-Yves David # Date 1600866995 -7200 # Node ID 147fb889278bb74a4fb887c9527a58412b6c7a0b # Parent 4e2238ba51a494aa20626ee14f078e346c3af148 sidedata: simply read p2copies files from the `ChangingFiles` object diff -r 4e2238ba51a4 -r 147fb889278b mercurial/changelog.py --- a/mercurial/changelog.py Wed Sep 23 15:16:16 2020 +0200 +++ b/mercurial/changelog.py Wed Sep 23 15:16:35 2020 +0200 @@ -27,8 +27,6 @@ stringutil, ) -from .revlogutils import sidedata as sidedatamod - _defaultextra = {b'branch': b'default'} @@ -360,9 +358,7 @@ @property def p2copies(self): if self._cpsd: - rawcopies = self._sidedata.get(sidedatamod.SD_P2COPIES) - if not rawcopies: - return {} + return self.changes.copied_from_p2 else: rawcopies = self.extra.get(b'p2copies') if rawcopies is None: