# HG changeset patch # User Pierre-Yves David # Date 2024-02-21 13:42:13 # Node ID e0d3294917091a196af5b6977c84378ea467f553 # Parent 0c04074f5414c773cadb42ed9483b92bb0ab93d4 phases: pass an unfiltered repository to _ensure_phase_sets It seems better for such a low level function to be able to assume it operate on a real repository. diff --git a/mercurial/phases.py b/mercurial/phases.py --- a/mercurial/phases.py +++ b/mercurial/phases.py @@ -413,7 +413,7 @@ class phasecache: ) -> Any: # TODO: finish typing this """return a smartset for the given phases""" - self._ensure_phase_sets(repo) # ensure phase's sets are loaded + self._ensure_phase_sets(repo.unfiltered()) phases = set(phases) publicphase = public in phases @@ -536,7 +536,7 @@ class phasecache: # double check self._loadedrevslen to avoid an extra method call as # python is slow for that. if rev >= self._loadedrevslen: - self._ensure_phase_sets(repo) + self._ensure_phase_sets(repo.unfiltered()) for phase in trackedphases: if rev in self._phasesets[phase]: return phase