iotests/297: Split mypy configuration out into mypy.ini
More separation of code and configuration. Signed-off-by: John Snow <jsnow@redhat.com> Reviewed-by: Hanna Reitz <hreitz@redhat.com> Message-id: 20211019144918.3159078-3-jsnow@redhat.com Signed-off-by: John Snow <jsnow@redhat.com>
This commit is contained in:
parent
95a556e7c7
commit
8f7960fa31
@ -73,19 +73,7 @@ def run_linters():
|
||||
sys.stdout.flush()
|
||||
|
||||
env['MYPYPATH'] = env['PYTHONPATH']
|
||||
p = subprocess.run(('mypy',
|
||||
'--warn-unused-configs',
|
||||
'--disallow-subclassing-any',
|
||||
'--disallow-any-generics',
|
||||
'--disallow-incomplete-defs',
|
||||
'--disallow-untyped-decorators',
|
||||
'--no-implicit-optional',
|
||||
'--warn-redundant-casts',
|
||||
'--warn-unused-ignores',
|
||||
'--no-implicit-reexport',
|
||||
'--namespace-packages',
|
||||
'--scripts-are-modules',
|
||||
*files),
|
||||
p = subprocess.run(('mypy', *files),
|
||||
env=env,
|
||||
check=False,
|
||||
stdout=subprocess.PIPE,
|
||||
|
12
tests/qemu-iotests/mypy.ini
Normal file
12
tests/qemu-iotests/mypy.ini
Normal file
@ -0,0 +1,12 @@
|
||||
[mypy]
|
||||
disallow_any_generics = True
|
||||
disallow_incomplete_defs = True
|
||||
disallow_subclassing_any = True
|
||||
disallow_untyped_decorators = True
|
||||
implicit_reexport = False
|
||||
namespace_packages = True
|
||||
no_implicit_optional = True
|
||||
scripts_are_modules = True
|
||||
warn_redundant_casts = True
|
||||
warn_unused_configs = True
|
||||
warn_unused_ignores = True
|
Loading…
Reference in New Issue
Block a user