# HG changeset patch # User Pierre-Yves David # Date 1459637807 25200 # Node ID faff8c2b5ee338606c86e8865e2a483c1a142e7c # Parent 0970ebec29b4304d36b7fd5c558a4d52aa03c26d hideablerevs: expand docstring to warn about possible traps Sean Farley just wasted multiple hours trying to figure out why his code was crashing. We update the docstring to make the constraint clearer. diff -r 0970ebec29b4 -r faff8c2b5ee3 mercurial/repoview.py --- a/mercurial/repoview.py Sun Apr 03 19:47:29 2016 +0900 +++ b/mercurial/repoview.py Sat Apr 02 15:56:47 2016 -0700 @@ -22,9 +22,14 @@ ) def hideablerevs(repo): - """Revisions candidates to be hidden + """Revision candidates to be hidden + + This is a standalone function to allow extensions to wrap it. - This is a standalone function to help extensions to wrap it.""" + Because we use the set of immutable changesets as a fallback subset in + branchmap (see mercurial.branchmap.subsettable), you cannot set "public" + changesets as "hideable". Doing so would break multiple code assertions and + lead to crashes.""" return obsolete.getrevs(repo, 'obsolete') def _getstatichidden(repo):