mypy: check_untyped_defs for qutebrowser.app

This commit is contained in:
Florian Bruhin 2019-10-15 18:14:39 +02:00
parent 76e11911d9
commit 02bde80f0b
2 changed files with 5 additions and 4 deletions

View File

@ -144,5 +144,5 @@ check_untyped_defs = True
# [mypy-qutebrowser.misc.*]
# check_untyped_defs = True
# [mypy-qutebrowser.app]
# check_untyped_defs = True
[mypy-qutebrowser.app]
check_untyped_defs = True

View File

@ -110,7 +110,8 @@ def run(args):
q_app.setApplicationName("qutebrowser")
q_app.setDesktopFileName("org.qutebrowser.qutebrowser")
q_app.setApplicationVersion(qutebrowser.__version__)
q_app.lastWindowClosed.connect(quitter.on_last_window_closed)
q_app.lastWindowClosed.connect( # type: ignore
quitter.on_last_window_closed)
if args.version:
print(version.version())
@ -350,7 +351,7 @@ def _open_startpage(win_id=None):
If set, open the startpage in the given window.
"""
if win_id is not None:
window_ids = [win_id]
window_ids = [win_id] # type: typing.Iterable[int]
else:
window_ids = objreg.window_registry
for cur_win_id in list(window_ids): # Copying as the dict could change