Files
openvino/src/bindings/python/setup.cfg
T
Jan Iwaszkiewicz 5ae221e107 [PyOV] Fix mypy after bump, general refactor (#13913)
* Fix mypy errors after bump PEP482, reformat code in general

* Enable checks

* Fix smaller issues

* Revert typo with comments

* Fix indents
2022-11-08 19:26:39 +04:00

85 lines
3.0 KiB
INI

[tox:tox]
envlist = py3
[testenv]
skipdist=True
skip_install=True
deps =
-rrequirements.txt
-rrequirements_test.txt
setenv =
OV_BACKEND = {env:OV_BACKEND:"CPU"}
PYTHONPATH = {env:PYTHONPATH}
OpenVINO_DIR = {env:OpenVINO_DIR}
passenv =
http_proxy
https_proxy
commands=
{envbindir}/python setup.py bdist_wheel
{envbindir}/pip install --no-index --pre --find-links=dist/ openvino
pytest --backend={env:OV_BACKEND} tests -m "not template_plugin" -v -k 'not _cuda' --ignore=tests/test_onnx/test_zoo_models.py --ignore=tests/test_utils
pytest --backend={env:OV_BACKEND} tests_compatibility/test_ngraph -v -k 'not _cuda' --ignore=tests_compatibility/test_onnx/test_zoo_models.py
[testenv:zoo_models]
commands=
{envbindir}/python setup.py bdist_wheel
{envbindir}/pip install --no-index --pre --find-links=dist/ openvino
pytest --backend={env:OV_BACKEND} tests/test_onnx/test_zoo_models.py -v -n 4 --forked -k 'not _cuda' --model_zoo_xfail
[testenv:devenv]
envdir = devenv
usedevelop = True
deps = -rrequirements.txt
[flake8]
# ignore:
# A001 variable "var_name" is shadowing a python builtin
# A002 argument "..." is shadowing a python builtin
# CCE001 ClassName.method1 should be after ClassName.method2
# D100 - Missing docstring in public module
# D101 - Missing docstring in public class
# D102 - Missing docstring in public method
# D103 - Missing docstring in public function
# D104 - Missing docstring in public package
# D105 - Missing docstring in magic method
# D107 - Missing docstring in __init__
# D412 - No blank lines allowed between a section header and its content
# F401 - module imported but unused
# N803 - argument name '...' should be lowercase
# T001 - print found
# W503 - line break before binary operator (prefer line breaks before op, not after)
# RST301 - Unexpected indentation
# TAE002 - too complex annotation
# PT007 - wrong values type @pytest.mark.parametrize, expected list of tuples
# PT012 - pytest.raises() block should contain a single simple statement
# VNE001 - single letter variable names like 'X' are not allowed
# VNE003 - variable names that shadow builtins are not allowed
ignore=A001,A002,CCE001,D100,D101,D102,D103,D104,D105,D107,D412,E402,F401,N803,RST301,TAE002,T001,W503,PT007,PT012
inline-quotes = double
filename = *.py
max-line-length = 160
max-parameters-amount = 8
show_source = True
docstring-convention = google
enable-extensions = G
per-file-ignores =
src/openvino/runtime/*/ops.py: VNE001,VNE003
tests_compatibility/test_ngraph/*: C101,C812,C815,C816,C819,CCE001,D212,E800,ECE001,N400,N802,N806,P101,P103,PT001,PT005,PT006,PT011,PT019,PT023,RST201,S001,VNE002
src/compatibility/ngraph/*: C101,C812,C819,CCE001,E800,N806,P101,RST201,RST202,RST203,RST206,VNE001,VNE003
[pydocstyle]
convention = google
[mypy]
ignore_missing_imports = True
disable_error_code = attr-defined
show_column_numbers = True
show_error_context = True
show_absolute_path = True
pretty = True
follow_imports = normal
disallow_untyped_defs = True
disallow_untyped_calls = True
check_untyped_defs = True