
We want typing. Change-Id: I83cff62f92f942257f178921a6b94d49f25c69c9 Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
59 lines
1.3 KiB
TOML
59 lines
1.3 KiB
TOML
[tool.mypy]
|
|
python_version = "3.9"
|
|
show_column_numbers = true
|
|
show_error_context = true
|
|
ignore_missing_imports = true
|
|
follow_imports = "normal"
|
|
check_untyped_defs = true
|
|
warn_unused_ignores = true
|
|
# many of the following are false while we incrementally add typing
|
|
warn_return_any = false
|
|
warn_unused_configs = true
|
|
warn_redundant_casts = true
|
|
strict_equality = true
|
|
disallow_untyped_decorators = false
|
|
disallow_any_generics = false
|
|
disallow_subclassing_any = false
|
|
disallow_untyped_calls = false
|
|
disallow_incomplete_defs = true
|
|
disallow_untyped_defs = false
|
|
no_implicit_reexport = false
|
|
extra_checks = true
|
|
# keep this in-sync with 'mypy.exclude' in '.pre-commit-config.yaml'
|
|
exclude = '''
|
|
(?x)(
|
|
doc
|
|
| examples
|
|
| releasenotes
|
|
)
|
|
'''
|
|
|
|
[[tool.mypy.overrides]]
|
|
module = [
|
|
"openstack.exceptions",
|
|
"openstack.fields",
|
|
"openstack.format",
|
|
"openstack.utils",
|
|
]
|
|
warn_return_any = true
|
|
disallow_untyped_decorators = true
|
|
disallow_any_generics = true
|
|
disallow_subclassing_any = true
|
|
disallow_untyped_calls = true
|
|
disallow_untyped_defs = true
|
|
no_implicit_reexport = true
|
|
|
|
[[tool.mypy.overrides]]
|
|
module = ["openstack.tests.unit.*"]
|
|
ignore_errors = true
|
|
|
|
[tool.ruff]
|
|
line-length = 79
|
|
|
|
[tool.ruff.format]
|
|
quote-style = "preserve"
|
|
docstring-code-format = true
|
|
|
|
[tool.ruff.lint]
|
|
select = ["E4", "E7", "E9", "F", "U"]
|