Mercurial > evolve
changeset 2845:9fc6a4615ae5
revset: unstable volatile set was deprecated
Use orphan volatile set instead.
Match 5579864798c6 mercurial changeset.
author | Boris Feld <boris.feld@octobus.net> |
---|---|
date | Fri, 11 Aug 2017 11:55:07 +0200 |
parents | 9688988472da |
children | 9c019996bce0 |
files | hgext3rd/evolve/__init__.py hgext3rd/evolve/compat.py |
diffstat | 2 files changed, 6 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext3rd/evolve/__init__.py Fri Aug 11 11:43:57 2017 +0200 +++ b/hgext3rd/evolve/__init__.py Fri Aug 11 11:55:07 2017 +0200 @@ -489,7 +489,7 @@ """ revset.getargs(x, 0, 0, 'troubled takes no arguments') troubled = set() - troubled.update(getrevs(repo, 'unstable')) + troubled.update(getrevs(repo, 'orphan')) troubled.update(getrevs(repo, 'bumped')) troubled.update(getrevs(repo, 'divergent')) troubled = revset.baseset(troubled) @@ -759,13 +759,13 @@ # part of the troubled stuff may be filtered (stash ?) # This needs a better implementation but will probably wait for core. filtered = repo.changelog.filteredrevs - priorunstables = len(set(getrevs(repo, 'unstable')) - filtered) + priorunstables = len(set(getrevs(repo, 'orphan')) - filtered) priorbumpeds = len(set(getrevs(repo, 'bumped')) - filtered) priordivergents = len(set(getrevs(repo, 'divergent')) - filtered) ret = orig(ui, repo, *args, **kwargs) filtered = repo.changelog.filteredrevs newunstables = \ - len(set(getrevs(repo, 'unstable')) - filtered) - priorunstables + len(set(getrevs(repo, 'orphan')) - filtered) - priorunstables newbumpeds = \ len(set(getrevs(repo, 'bumped')) - filtered) - priorbumpeds newdivergents = \
--- a/hgext3rd/evolve/compat.py Fri Aug 11 11:43:57 2017 +0200 +++ b/hgext3rd/evolve/compat.py Fri Aug 11 11:55:07 2017 +0200 @@ -152,3 +152,6 @@ return self.precursors obsolete.obsstore.predecessors = predecessors + +if not util.safehasattr(obsolete, '_computeorphanset'): + obsolete._computeorphanset = obsolete.cachefor('orphan')(obsolete._computeunstableset)