# Global options:

[mypy]
warn_unused_configs = True
follow_imports = silent
show_error_context = True
files = **/numba/core/types/*.py, **/numba/core/extending.py, **/numba/core/datamodel/*.py, **/numba/core/rewrites/*.py, **/numba/core/unsafe/*.py

# Per-module options:
# To classify a given module as Level 0, 1, 2 or 3 it must be added both in files (variable above) and in the lists below.
# Level 0 - modules checked on the strictest settings. Any is prohibited anywhere.
;[mypy-]
;disallow_any_decorated = True
;disallow_any_explicit = True
;disallow_any_expr = True
;disallow_any_unimported = True
;strict = True
;warn_unreachable = True
;follow_imports = normal

# Level 1 - module that pass mypy's strict mode and dead code detection.
;[mypy-]
;strict = True
;warn_unreachable = True
;follow_imports = normal

# Level 2 - module that pass reasonably strict settings.
#           No untyped functions allowed. Imports must be typed or explicitly ignored.
;[mypy-]
;warn_return_any = True
;disallow_untyped_defs = True
;disallow_incomplete_defs = True
;follow_imports = normal

# Level 3 - modules that pass mypy default settings (only those in `files` global setting and not in previous levels)
#           Function/variables are annotated to avoid mypy errors, but annotations are not complete.
[mypy-numba.core.*]
warn_return_any = True

# Level 4 - modules that do not pass mypy check: they are excluded from "files" setting in global section

# External packages that lack annotations
[mypy-llvmlite.*]
ignore_missing_imports = True

[mypy-numpy.*]
ignore_missing_imports = True

[mypy-winreg.*]
# this can be removed after Mypy 0.78 is out with the latest typeshed
ignore_missing_imports = True

[mypy-graphviz.*]
ignore_missing_imports = True
