mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-05 08:44:57 -04:00
Make scripts-dev
pass mypy --disallow-untyped-defs
(#12356)
Not enforced in config yet. One day.
This commit is contained in:
parent
6463244375
commit
30c8e7e408
9 changed files with 96 additions and 53 deletions
|
@ -16,7 +16,7 @@
|
|||
can crop up, e.g the cache descriptors.
|
||||
"""
|
||||
|
||||
from typing import Callable, Optional
|
||||
from typing import Callable, Optional, Type
|
||||
|
||||
from mypy.nodes import ARG_NAMED_OPT
|
||||
from mypy.plugin import MethodSigContext, Plugin
|
||||
|
@ -94,7 +94,7 @@ def cached_function_method_signature(ctx: MethodSigContext) -> CallableType:
|
|||
return signature
|
||||
|
||||
|
||||
def plugin(version: str):
|
||||
def plugin(version: str) -> Type[SynapsePlugin]:
|
||||
# This is the entry point of the plugin, and let's us deal with the fact
|
||||
# that the mypy plugin interface is *not* stable by looking at the version
|
||||
# string.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue