-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmypy.ini
More file actions
49 lines (43 loc) · 1.71 KB
/
mypy.ini
File metadata and controls
49 lines (43 loc) · 1.71 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
# SPDX-FileCopyrightText: Copyright (C) 2021 Opal Health Informatics Group at the Research Institute of the McGill University Health Centre <[email protected]>
#
# SPDX-License-Identifier: AGPL-3.0-or-later
# https://mypy.readthedocs.io/en/stable/config_file.html
[mypy]
ignore_missing_imports = True
strict_equality = True
show_error_codes = True
show_error_code_links = True
warn_return_any = True
warn_unused_ignores = True
warn_redundant_casts = True
warn_unused_configs = True
warn_unreachable = True
# https://mypy.readthedocs.io/en/stable/command_line.html#cmdoption-mypy-disallow-any-generics
disallow_any_generics = True
# https://mypy.readthedocs.io/en/stable/command_line.html#cmdoption-mypy-disallow-untyped-calls
disallow_untyped_calls = True
disallow_untyped_defs = True
disallow_incomplete_defs = True
disallow_untyped_decorators = True
check_untyped_defs = True
enable_error_code = redundant-expr,truthy-bool,ignore-without-code
plugins = mypy_django_plugin.main,mypy_drf_plugin.main,pydantic.mypy
[mypy.plugins.django-stubs]
django_settings_module = config.settings.test
[mypy-*.migrations.*]
# Django migrations should not produce any errors:
# ignore_errors = False
# suppress error from initial migration, anything else should be reported due migrations with custom code
allow_untyped_globals = True
[mypy-*.tests.*]
warn_unreachable = False
# Disabled to enforce type definitions in tests as well.
# This hopefully helps find test issues faster.
# suppress errors for tests about untyped defs
# disallow_untyped_defs = False
# disallow_untyped_decorators = False
# disallow_incomplete_defs = False
[mypy-*.factories]
disallow_untyped_calls = False
[mypy-*.fhir.tests.*]
disable_error_code = index,union-attr,arg-type