diff hgext/churn.py @ 26587:56b2bcea2529

error: get Abort from 'error' instead of 'util' The home of 'Abort' is 'error' not 'util' however, a lot of code seems to be confused about that and gives all the credit to 'util' instead of the hardworking 'error'. In a spirit of equity, we break the cycle of injustice and give back to 'error' the respect it deserves. And screw that 'util' poser. For great justice.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Thu, 08 Oct 2015 12:55:45 -0700
parents 328739ea70c3
children 79fc627578ac
line wrap: on
line diff
--- a/hgext/churn.py	Mon Oct 05 22:49:24 2015 -0700
+++ b/hgext/churn.py	Thu Oct 08 12:55:45 2015 -0700
@@ -9,7 +9,7 @@
 '''command to display statistics about repository history'''
 
 from mercurial.i18n import _
-from mercurial import patch, cmdutil, scmutil, util, commands
+from mercurial import patch, cmdutil, scmutil, util, commands, error
 from mercurial import encoding
 import os
 import time, datetime
@@ -27,7 +27,7 @@
         t = cmdutil.changeset_templater(ui, repo, False, None, tmpl,
                                         None, False)
     except SyntaxError as inst:
-        raise util.Abort(inst.args[0])
+        raise error.Abort(inst.args[0])
     return t
 
 def changedlines(ui, repo, ctx1, ctx2, fns):