Fix lint
This commit is contained in:
parent
91514ad6c0
commit
414ab88a0e
@ -103,6 +103,7 @@ class Application(QApplication):
|
||||
self.modeman = None
|
||||
self.cmd_history = None
|
||||
self.config = None
|
||||
self.keyconfig = None
|
||||
|
||||
sys.excepthook = self._exception_hook
|
||||
|
||||
@ -195,7 +196,7 @@ class Application(QApplication):
|
||||
except keyconfparser.KeyConfigError as e:
|
||||
log.init.exception(e)
|
||||
errstr = "Error while reading key config:\n"
|
||||
if hasattr(e, 'lineno'):
|
||||
if e.lineno is not None:
|
||||
errstr += "In line {}: ".format(e.lineno)
|
||||
errstr += str(e)
|
||||
msgbox = QMessageBox(QMessageBox.Critical,
|
||||
|
@ -29,7 +29,15 @@ from qutebrowser.utils import log
|
||||
|
||||
class KeyConfigError(Exception):
|
||||
|
||||
"""Raised on errors with the key config."""
|
||||
"""Raised on errors with the key config.
|
||||
|
||||
Attributes:
|
||||
lineno: The config line in which the exception occured.
|
||||
"""
|
||||
|
||||
def __init__(self):
|
||||
super().__init__()
|
||||
self.lineno = None
|
||||
|
||||
|
||||
class KeyConfigParser:
|
||||
|
Loading…
Reference in New Issue
Block a user