Turn on check_untyped_defs for aqt.taglimit

* Add type hints taglimit
* Turn on check_untyped_defs for aqt.taglimit
This commit is contained in:
Matt Krump 2020-07-25 15:43:42 -06:00
parent ca8265a695
commit 7356756868
2 changed files with 5 additions and 1 deletions

View file

@ -1,5 +1,6 @@
# Copyright: Ankitects Pty Ltd and contributors
# License: GNU AGPL, version 3 or later; http://www.gnu.org/copyleft/agpl.html
from typing import List, Optional
import aqt
from aqt.qt import *
@ -9,8 +10,9 @@ from aqt.utils import restoreGeom, saveGeom
class TagLimit(QDialog):
def __init__(self, mw, parent):
QDialog.__init__(self, parent, Qt.Window)
self.tags: Union[str, List] = ""
self.mw = mw
self.parent = parent
self.parent: Optional[QWidget] = parent
self.deck = self.parent.deck
self.dialog = aqt.forms.taglimit.Ui_Dialog()
self.dialog.setupUi(self)

View file

@ -76,3 +76,5 @@ check_untyped_defs=true
check_untyped_defs=true
[mypy-aqt.deckconf]
check_untyped_defs=true
[mypy-aqt.taglimit]
check_untyped_defs=true