Enable bare minimum pytype + GHA (no ryu code changes). Exclusions/ignored errors can be incrementally removed, to manage diff size and risk.

This commit is contained in:
Josh Bailey 2021-06-03 00:44:17 +00:00
parent f24e2b9bf1
commit 8b41507c2c
3 changed files with 22 additions and 2 deletions

View File

@ -55,3 +55,14 @@ setup-hooks =
console_scripts =
ryu-manager = ryu.cmd.manager:main
ryu = ryu.cmd.ryu_base:main
[pytype]
inputs =
ryu/controller/
disable =
attribute-error
import-error
key-error
module-attr
keep-going =
1

View File

@ -4,4 +4,5 @@ mock
nose
pycodestyle
pylint
pytype
formencode

12
tox.ini
View File

@ -1,10 +1,10 @@
[tox]
envlist = py35,py36,py37,py38,py39,pypy,pycodestyle,autopep8
envlist = py35,py36,py37,py38,py39,pypy,pycodestyle,autopep8,pytype
[gh-actions]
python =
3.5: py35
3.6: py36, pycodestyle, autopep8
3.6: py36, pycodestyle, autopep8, pytype
3.7: py37
3.8: py38
3.9: py39
@ -53,6 +53,14 @@ deps =
commands =
bash -c 'test -z "$(autopep8 --recursive --diff ryu/)"'
[testenv:pytype]
deps =
-U
--no-cache-dir
pytype
commands =
pytype --jobs 2
[pycodestyle]
exclude = pbr-*,.venv,.tox,.git,doc,dist,tools,vcsversion.py,.pyc,ryu/contrib
# W503: line break before binary operator