1. Pierre-Yves David
  2. mutable-history

Commits

Pierre-Yves David  committed c083fb4

obsolete: stop using rev as it rebuild the cache every time there is a fault

We now use nodemap directly

  • Participants
  • Parent commits 4d6eef4
  • Branches default

Comments (0)

Files changed (1)

File hgext/obsolete.py

View file
  • Ignore whitespace
         @util.propertycache
         def _obsoleteset(self):
             obs = set()
+            nm = self.changelog.nodemap
             for obj in self._obsobjrels:
-                try:
-                    obs.add(self.changelog.rev(obj))
-                except error.LookupError:
-                    pass
+                rev = nm.get(obj, None)
+                if rev is not None:
+                    obs.add(rev)
             return obs
 
         def addobsolete(self, sub, obj):