[mypy] files = numpy/**/*.pyi exclude = (?x)( ^numpy/( .+\.py$ | _build_utils/ | _core/code_generators/ | distutils/ ) ) namespace_packages = False enable_error_code = ignore-without-code, redundant-expr, truthy-bool warn_unreachable = False strict = True strict_bytes = True allow_redefinition_new = True local_partial_types = True ; Stubtest requires mypy to pass before running, which would currently fail ; on numerous stubs. To allow running stubtest independently, we temporarily ; ignore these errors here. The goal is to eventually fix these mypy errors ; and remove the ignores. ; See also https://github.com/numpy/numpy/issues/27032 disable_error_code = overload-overlap