forked from mborsetti/webchanges
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmypy.ini
48 lines (34 loc) · 1.76 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
37
38
39
40
41
42
43
44
45
46
47
48
[mypy]
# Static Typing for Python
# Runs as part of pre-commit
# File info at https://mypy.readthedocs.io/en/stable/config_file.html
# Specifies the Python version used to parse and check the target program.
# python_version = 3.7
# Shows error codes in error messages.
show_error_codes = True
# Suppresses error messages about imports that cannot be resolved.
ignore_missing_imports = True
# Disallows calling functions without type annotations from functions with type annotations.
disallow_untyped_calls = True
# Disallows defining functions without type annotations or with incomplete type annotations.
disallow_untyped_defs = True
# Reports an error whenever a function with type annotations is decorated with a decorator without annotations.
disallow_untyped_decorators = True
# Changes the treatment of arguments with a default value of None by not implicitly making their type Optional.
no_implicit_optional = True
# Warns about casting an expression to its inferred type.
warn_redundant_casts = True
# Warns about unneeded # type: ignore comments.
# Disabled because it behaves differently in GitHub Actions than it does on Windows.
# warn_unused_ignores = True
# Shows a warning when returning a value with type Any from a function declared with a non-Any return type.
# warn_return_any = True
# Shows a warning when encountering any code inferred to be unreachable or redundant after performing type analysis.
warn_unreachable = False
# Use visually nicer output in error messages: use soft word wrap, show source code snippets, and show error location
# markers.
pretty = True
# Use an SQLite database to store the cache.
sqlite_cache = True
# Warns about per-module sections in the config file that do not match any files processed when invoking mypy.
warn_unused_configs = True