-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmypy.ini
More file actions
63 lines (51 loc) · 1.27 KB
/
mypy.ini
File metadata and controls
63 lines (51 loc) · 1.27 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
[mypy]
# General mypy configuration for tensorlogic-py
# Python version
python_version = 3.9
# Import discovery
mypy_path = .
files = tests/, examples/
# Strictness
strict = True
warn_return_any = True
warn_unused_configs = True
warn_redundant_casts = True
warn_unused_ignores = True
warn_no_return = True
warn_unreachable = True
# Error reporting
show_error_context = True
show_column_numbers = True
show_error_codes = True
pretty = True
# Specific rules
disallow_untyped_defs = True
disallow_incomplete_defs = True
check_untyped_defs = True
disallow_untyped_decorators = False # Allow pytest decorators
disallow_any_generics = True
disallow_subclassing_any = True
no_implicit_optional = True
strict_optional = True
strict_equality = True
# Warnings
warn_unused_ignores = True
warn_redundant_casts = True
# Performance
cache_dir = .mypy_cache
incremental = True
sqlite_cache = True
# Miscellaneous
color_output = True
# Per-module options for third-party libraries
[mypy-numpy.*]
ignore_missing_imports = True
[mypy-pytest.*]
ignore_missing_imports = True
[mypy-tensorlogic_py.*]
# Our stub file provides types
follow_imports = normal
check_untyped_defs = True
# Ignore specific errors in test files
[mypy-tests.*]
disallow_untyped_defs = False # Tests can have less strict typing