From 186f1c77208f1e585e1c698a949aaaa1ee828fb8 Mon Sep 17 00:00:00 2001 From: Matt Krump <1036969+mkrump@users.noreply.github.com> Date: Fri, 24 Jul 2020 11:19:40 -0600 Subject: [PATCH] Add type hints to errors * Add type hints to errors * Turn on type checking for aqt.errors --- qt/aqt/errors.py | 2 +- qt/mypy.ini | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/qt/aqt/errors.py b/qt/aqt/errors.py index de73435d4..b6cbc2eb6 100644 --- a/qt/aqt/errors.py +++ b/qt/aqt/errors.py @@ -54,7 +54,7 @@ class ErrorHandler(QObject): def setTimer(self): # we can't create a timer from a different thread, so we post a # message to the object on the main thread - self.errorTimer.emit() + self.errorTimer.emit() # type: ignore def _setTimer(self): if not self.timer: diff --git a/qt/mypy.ini b/qt/mypy.ini index a39a1de9c..b6203b753 100644 --- a/qt/mypy.ini +++ b/qt/mypy.ini @@ -70,3 +70,5 @@ check_untyped_defs=true check_untyped_defs=true [mypy-aqt.models] check_untyped_defs=true +[mypy-aqt.errors] +check_untyped_defs=true