Mercurial > public > mercurial-scm > hg-stable
diff mercurial/ui.py @ 4729:9881abfc0e44
Catch illegal boolean values in hgrc nicely.
With hg 0.9.3 the section and parameter name wasn't printed,
with hg 0.9.4 there was a traceback for ValueError.
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Tue, 26 Jun 2007 20:37:15 +0200 |
parents | 97369f6a6bb6 |
children | ca0d02222d6a |
line wrap: on
line diff
--- a/mercurial/ui.py Tue Jun 26 18:39:28 2007 +0200 +++ b/mercurial/ui.py Tue Jun 26 20:37:15 2007 +0200 @@ -237,7 +237,7 @@ try: func = getattr(cdata, funcname) return func(section, name) - except ConfigParser.InterpolationError, inst: + except (ConfigParser.InterpolationError, ValueError), inst: msg = _("Error in configuration section [%s] " "parameter '%s':\n%s") % (section, name, inst) if abort: