diff --git a/pyproject.toml b/pyproject.toml index eb97f74fab..6d1ca9d8cb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,3 +7,39 @@ aggressive = 3 in-place = true recursive = true +[tool.mypy] +python_version = "3.10" +show_column_numbers = true +show_error_context = true +ignore_missing_imports = true +follow_imports = "skip" +incremental = true +check_untyped_defs = true +warn_unused_ignores = true +# keep this in-sync with 'mypy.exclude' in '.pre-commit-config.yaml' +files = [ + "nova/compute/manager.py", + "nova/compute/pci_placement_translator.py", + "nova/crypto.py", + "nova/filesystem.py", + "nova/limit/local.py", + "nova/limit/placement.py", + "nova/network/neutron.py", + "nova/pci/*.py", + "nova/privsep/path.py", + "nova/scheduler/client/report.py", + "nova/scheduler/request_filter.py", + "nova/scheduler/utils.py", + "nova/virt/driver.py", + "nova/virt/hardware.py", + "nova/virt/libvirt/machine_type_utils.py", + "nova/virt/libvirt/__init__.py", + "nova/virt/libvirt/cpu/__init__.py", + "nova/virt/libvirt/cpu/api.py", + "nova/virt/libvirt/cpu/core.py", + "nova/virt/libvirt/driver.py", + "nova/virt/libvirt/event.py", + "nova/virt/libvirt/guest.py", + "nova/virt/libvirt/host.py", + "nova/virt/libvirt/utils.py", +] diff --git a/setup.cfg b/setup.cfg index 9d837850ba..9c79f5c065 100644 --- a/setup.cfg +++ b/setup.cfg @@ -85,40 +85,6 @@ console_scripts = nova-spicehtml5proxy = nova.cmd.spicehtml5proxy:main nova-status = nova.cmd.status:main -[mypy] -show_column_numbers = true -show_error_context = true -ignore_missing_imports = true -follow_imports = skip -incremental = true -check_untyped_defs = true -warn_unused_ignores = true -files = - nova/compute/manager.py, - nova/compute/pci_placement_translator.py, - nova/crypto.py, - nova/filesystem.py, - nova/limit/local.py, - nova/limit/placement.py, - nova/network/neutron.py, - nova/pci/*.py, - nova/privsep/path.py, - nova/scheduler/client/report.py, - nova/scheduler/request_filter.py, - nova/scheduler/utils.py, - nova/virt/driver.py, - nova/virt/hardware.py, - nova/virt/libvirt/machine_type_utils.py, - nova/virt/libvirt/__init__.py, - nova/virt/libvirt/cpu/__init__.py, - nova/virt/libvirt/cpu/api.py, - nova/virt/libvirt/cpu/core.py, - nova/virt/libvirt/driver.py, - nova/virt/libvirt/event.py, - nova/virt/libvirt/guest.py, - nova/virt/libvirt/host.py, - nova/virt/libvirt/utils.py - [codespell] skip = *.po,*.js,*.css,*.html,*.svg,HACKING.py,*hacking*,*build*,*_static*,doc/dictionary.txt,*.pyc,*.inv,*.gz,*.jpg,*.png,*.vsd,*.graffle,*.json count =