Euler source The code that runs the solver shell and this site, version 4.34.2 Repository on GitHub

mypy.ini

77 lines of INI Raw file Open on GitHub

[mypy]
# Global options:
warn_redundant_casts = true
warn_unused_ignores = true
warn_no_return = true
warn_return_any = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
check_untyped_defs = true
disallow_untyped_decorators = true
no_implicit_optional = true
strict_optional = true
warn_unreachable = true
pretty = true
color_output = true
show_error_codes = true

# Disable error-based exit code when finding code to improve
no_error_summary = false
error_summary = true

# Allow files to import missing modules (helpful for stubs)
ignore_missing_imports = true

# Enable namespace packages widely used in Python 3
namespace_packages = true

# Resolve the packages from their sources. The editable install's import hook is invisible
# to mypy, so without this a run on `tests` alone sees them as missing (hence Any), and its
# cache then misleads the next full run into errors that are not there.
mypy_path = packages/solver, packages/site, packages/webshell, packages/content

# Enable type inference for installed packages
implicit_reexport = false

# Per-module options (more permissive for tests)
[mypy.plugins.matplotlib.*]
follow_imports = skip

[mypy.plugins.numpy.*]
follow_imports = skip

[mypy.plugins.PIL.*]
follow_imports = skip

[mypy-tests.*]
disallow_untyped_defs = false
disallow_incomplete_defs = false
# A test's stand-in records its calls with `lambda *a: calls.append(a)`; the None it
# returns is the point, not a slip.
disable_error_code = func-returns-value

# Skip checking for installed packages we cant fix
[mypy-twisted.*]
ignore_missing_imports = true
follow_imports = skip

[mypy-click.*]
follow_imports = skip

[mypy-matplotlib.*]
follow_imports = skip

[mypy-numba.*]
follow_imports = skip

[mypy-numpy.*]
follow_imports = skip

[mypy-PIL.*]
follow_imports = skip

[mypy-requests.*]
follow_imports = skip

[mypy-jinja2.*]
follow_imports = skip