# HG changeset patch # User Boris Feld # Date 2018-06-11 17:05:41 # Node ID 9df777d7f061cfa11531a5f80686e46e64dec7d5 # Parent 354fad8697fddfbc079b943229b8f9c17117c6a6 perftemplating: abort on incompatible version This is what the other debug commands do. Thanks to Yuya Nishihara for pointing this out. diff --git a/contrib/perf.py b/contrib/perf.py --- a/contrib/perf.py +++ b/contrib/perf.py @@ -912,8 +912,8 @@ def perfmoonwalk(ui, repo, **opts): def perftemplating(ui, repo, testedtemplate=None, **opts): """test the rendering time of a given template""" if makelogtemplater is None: - ui.write_err('incompatible Mercurial version') - return 1 + raise error.Abort(("perftemplating not available with this Mercurial"), + hint="use 4.3 or later") nullui = ui.copy() nullui.fout = open(os.devnull, 'wb')