diff mercurial/changelog.py @ 7633:08cabecfa8a8

errors: move revlog errors - create error.py for exception classes to reduce demandloading - move revlog exceptions to it - change users to import error and drop revlog import if possible
author Matt Mackall <mpm@selenic.com>
date Sun, 11 Jan 2009 22:48:28 -0600
parents 1d58c0491d5e
children 14a4337a9b9b
line wrap: on
line diff
--- a/mercurial/changelog.py	Sat Jan 10 18:02:38 2009 -0600
+++ b/mercurial/changelog.py	Sun Jan 11 22:48:28 2009 -0600
@@ -8,7 +8,7 @@
 from node import bin, hex, nullid
 from revlog import revlog, RevlogError
 from i18n import _
-import util
+import util, error
 
 def _string_escape(text):
     """
@@ -179,7 +179,8 @@
 
         user = user.strip()
         if "\n" in user:
-            raise RevlogError(_("username %s contains a newline") % repr(user))
+            raise error.RevlogError(_("username %s contains a newline")
+                                    % repr(user))
         user, desc = util.fromlocal(user), util.fromlocal(desc)
 
         if date: