# HG changeset patch # User Pierre-Yves David # Date 1485359419 -3600 # Node ID f22120b12715d7398b14c491ef89a0fa26e51533 # Parent 9480e13ee59a5c64a6bb5dcf62a3721de8546c19# Parent c3741a5adbb0d61c98f1593058857f4d684a2fb7 merge with stable diff -r 9480e13ee59a -r f22120b12715 README --- a/README Mon Jan 23 16:09:16 2017 +0100 +++ b/README Wed Jan 25 16:50:19 2017 +0100 @@ -46,7 +46,7 @@ say in $HGSRC: cd tests - python $HGSRC/tests/run-tests.py --with-hg=$HGSRC/hg + python $HGSRC/tests/run-tests.py (evolve's stable and default branches correspond to Mercurial's stable and default branches. So to test evolve from default, you need @@ -62,6 +62,10 @@ - improvement of prune error message. - fold: require --from flag for folding revisions to working copy +5.5.1 -- + + - fix crash when trying to fold an empty revision set (issue5453) + 5.5.0 -- 2016-10-30 - The {obsolete} template now yield "obsolete" or "". diff -r 9480e13ee59a -r f22120b12715 hgext/evolve.py --- a/hgext/evolve.py Mon Jan 23 16:09:16 2017 +0100 +++ b/hgext/evolve.py Wed Jan 25 16:50:19 2017 +0100 @@ -3133,7 +3133,10 @@ else: raise error.Abort(_('must specify either --from or --exact')) - if len(revs) == 1: + if not revs: + raise error.Abort(_('specified revisions evaluate to an empty set'), + hint=_('use different revision arguments')) + elif len(revs) == 1: ui.write_err(_('single revision specified, nothing to fold\n')) return 1 diff -r 9480e13ee59a -r f22120b12715 tests/test-evolve.t --- a/tests/test-evolve.t Mon Jan 23 16:09:16 2017 +0100 +++ b/tests/test-evolve.t Wed Jan 25 16:50:19 2017 +0100 @@ -701,6 +701,10 @@ abort: cannot fold non-linear revisions (given revisions are unrelated to parent of working directory) [255] + $ hg fold --exact -r "4 and not 4" + abort: specified revisions evaluate to an empty set + (use different revision arguments) + [255] $ hg phase --public 0 $ hg fold --from -r 0 abort: cannot fold public revisions