changeset 2846:9c019996bce0

revset: divergent volatile set was deprecated Use contentdivergent volatile set instead. Match 31c922423f3f mercurial changeset.
author Boris Feld <boris.feld@octobus.net>
date Fri, 11 Aug 2017 12:12:03 +0200
parents 9fc6a4615ae5
children a1805a65ce21
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:55:07 2017 +0200
+++ b/hgext3rd/evolve/__init__.py	Fri Aug 11 12:12:03 2017 +0200
@@ -491,7 +491,7 @@
     troubled = set()
     troubled.update(getrevs(repo, 'orphan'))
     troubled.update(getrevs(repo, 'bumped'))
-    troubled.update(getrevs(repo, 'divergent'))
+    troubled.update(getrevs(repo, 'contentdivergent'))
     troubled = revset.baseset(troubled)
     troubled.sort() # set is non-ordered, enforce order
     return subset & troubled
@@ -761,7 +761,7 @@
     filtered = repo.changelog.filteredrevs
     priorunstables = len(set(getrevs(repo, 'orphan')) - filtered)
     priorbumpeds = len(set(getrevs(repo, 'bumped')) - filtered)
-    priordivergents = len(set(getrevs(repo, 'divergent')) - filtered)
+    priordivergents = len(set(getrevs(repo, 'contentdivergent')) - filtered)
     ret = orig(ui, repo, *args, **kwargs)
     filtered = repo.changelog.filteredrevs
     newunstables = \
@@ -769,7 +769,7 @@
     newbumpeds = \
         len(set(getrevs(repo, 'bumped')) - filtered) - priorbumpeds
     newdivergents = \
-        len(set(getrevs(repo, 'divergent')) - filtered) - priordivergents
+        len(set(getrevs(repo, 'contentdivergent')) - filtered) - priordivergents
     if newunstables > 0:
         ui.warn(_('%i new unstable changesets\n') % newunstables)
     if newbumpeds > 0:
--- a/hgext3rd/evolve/compat.py	Fri Aug 11 11:55:07 2017 +0200
+++ b/hgext3rd/evolve/compat.py	Fri Aug 11 12:12:03 2017 +0200
@@ -155,3 +155,6 @@
 
 if not util.safehasattr(obsolete, '_computeorphanset'):
     obsolete._computeorphanset = obsolete.cachefor('orphan')(obsolete._computeunstableset)
+
+if not util.safehasattr(obsolete, '_computecontentdivergentset'):
+    obsolete._computecontentdivergentset = obsolete.cachefor('contentdivergent')(obsolete._computedivergentset)