[misc] Add some type annotations
This commit is contained in:
parent
35eff0c416
commit
fd09b381a6
|
@ -53,11 +53,12 @@ deps =
|
|||
black
|
||||
flake8
|
||||
mypy
|
||||
types-requests
|
||||
commands =
|
||||
black -S --check --diff src tests
|
||||
flake8 src tests
|
||||
# not yet
|
||||
#mypy src tests
|
||||
#mypy --ignore-missing-imports src tests
|
||||
|
||||
[testenv]
|
||||
deps =
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Copyright (C) 2020 by Thomas Lindner <tom@dl6tom.de>
|
||||
# Copyright (C) 2020, 2023 by Thomas Lindner <tom@dl6tom.de>
|
||||
# Copyright (C) 2020 by Cathy Hu <cathy.hu@fau.de>
|
||||
# Copyright (C) 2020 by Martin Rey <martin.rey@mailbox.org>
|
||||
#
|
||||
|
@ -71,7 +71,7 @@ class Censor:
|
|||
hood (Hood): A Hood Model object
|
||||
"""
|
||||
|
||||
__instances = {}
|
||||
__instances: dict[int, list["Censor"]] = {}
|
||||
|
||||
def __init__(self, hood):
|
||||
self.hood = hood
|
||||
|
@ -177,7 +177,7 @@ class Spawner:
|
|||
BotClass (Censor subclass): A Bot Class object
|
||||
"""
|
||||
|
||||
__instances = []
|
||||
__instances: list["Spawner"] = []
|
||||
|
||||
def __init__(self, ORMClass, BotClass):
|
||||
self.ORMClass = ORMClass
|
||||
|
|
Loading…
Reference in a new issue