Catch ValueError when reading config
This commit is contained in:
parent
53464dcbab
commit
af6f6b99e9
1
TODO
1
TODO
@ -2,7 +2,6 @@ Bugs
|
||||
====
|
||||
|
||||
All kind of FIXMEs
|
||||
Catch ValueError for invalid interpolations when reading config
|
||||
Display untransformed values for get
|
||||
|
||||
Style
|
||||
|
@ -112,7 +112,8 @@ class QuteBrowser(QApplication):
|
||||
configparser.InterpolationError,
|
||||
configparser.DuplicateSectionError,
|
||||
configparser.DuplicateOptionError,
|
||||
configparser.ParsingError) as e:
|
||||
configparser.ParsingError,
|
||||
ValueError) as e:
|
||||
errstr = "Error while reading config:"
|
||||
if hasattr(e, 'section') and hasattr(e, 'option'):
|
||||
errstr += "\n\n{} -> {}:".format(e.section, e.option)
|
||||
|
Loading…
Reference in New Issue
Block a user