-
Notifications
You must be signed in to change notification settings - Fork 1
/
mypy.ini
36 lines (34 loc) · 1.19 KB
/
mypy.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
[mypy]
python_version = 3.10
files = labs_api/, tests/
plugins = pydantic.mypy
warn_redundant_casts = True
warn_unused_ignores = True
disallow_any_generics = True
warn_return_any = True
check_untyped_defs = True
show_error_codes = True
strict_equality = True
explicit_package_bases = True
show_traceback = True
disallow_incomplete_defs = True
disallow_untyped_defs = True
ignore_missing_imports = True
# Exclude submodules that are themselves not type-checked
exclude = prediction_market_agent/tools/mech/mech/
# See https://github.com/python/mypy/issues/3905#issuecomment-421065323
# We don't want to ignore all missing imports as we want to catch those in our own code
# But for certain libraries they don't have a stub file, so we only enforce import checking for our own libraries.
# Another alternative would be to list out every single dependency that does not have a stub.
[mypy-prediction_market_agent.*]
ignore_missing_imports = False
[mypy-scripts.*]
ignore_missing_imports = False
[mypy-tests.*]
ignore_missing_imports = False
[pydantic-mypy]
# See https://pydantic-docs.helpmanual.io/mypy_plugin/
init_forbid_extra = True
init_typed = True
warn_required_dynamic_aliases = True
warn_untyped_fields = True