qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/5] python: add QAPI and qapidoc et al to python linter tests
@ 2025-04-17 21:31 John Snow
  2025-04-17 21:31 ` [PATCH v2 1/5] qapi: Add some pylint ignores John Snow
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: John Snow @ 2025-04-17 21:31 UTC (permalink / raw)
  To: qemu-devel
  Cc: John Snow, Cleber Rosa, Markus Armbruster, Peter Maydell,
	Michael Roth

Hiya, this series turns on automated linting for scripts/qapi,
docs/sphinx/qapidoc.py and docs/sphinx/qapi_domain.py.

This includes flake8/isort/pylint/mypy for scripts/qapi, but omits mypy
from the Sphinx plugins owing to my inability to strictly type the
extensions given the wide versions of Sphinx we actually support.

Though I have been using black in my own development, I have not yet
enabled it anywhere automatically. Maybe soon.

V2:
 - Mostly commit message updates based on Markus's's's review.

John Snow (5):
  qapi: Add some pylint ignores
  docs/qapidoc: linting fixes
  python: update missing dependencies from minreqs
  python: add qapi static analysis tests
  qapi: delete un-needed python static analysis configs

 docs/sphinx/qapi_domain.py  | 25 ++++++++++++++-----------
 docs/sphinx/qapidoc.py      |  5 +++--
 python/setup.cfg            |  1 +
 python/tests/minreqs.txt    | 25 +++++++++++++++++++++++++
 python/tests/qapi-flake8.sh |  4 ++++
 python/tests/qapi-isort.sh  |  6 ++++++
 python/tests/qapi-mypy.sh   |  2 ++
 python/tests/qapi-pylint.sh |  6 ++++++
 scripts/qapi/.flake8        |  3 ---
 scripts/qapi/.isort.cfg     |  7 -------
 scripts/qapi/backend.py     |  2 ++
 scripts/qapi/mypy.ini       |  4 ----
 scripts/qapi/pylintrc       |  1 +
 13 files changed, 64 insertions(+), 27 deletions(-)
 create mode 100755 python/tests/qapi-flake8.sh
 create mode 100755 python/tests/qapi-isort.sh
 create mode 100755 python/tests/qapi-mypy.sh
 create mode 100755 python/tests/qapi-pylint.sh
 delete mode 100644 scripts/qapi/.flake8
 delete mode 100644 scripts/qapi/.isort.cfg
 delete mode 100644 scripts/qapi/mypy.ini

-- 
2.48.1




^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2025-04-22  6:41 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-17 21:31 [PATCH v2 0/5] python: add QAPI and qapidoc et al to python linter tests John Snow
2025-04-17 21:31 ` [PATCH v2 1/5] qapi: Add some pylint ignores John Snow
2025-04-17 21:31 ` [PATCH v2 2/5] docs/qapidoc: linting fixes John Snow
2025-04-17 21:31 ` [PATCH v2 3/5] python: update missing dependencies from minreqs John Snow
2025-04-17 21:31 ` [PATCH v2 4/5] python: add qapi static analysis tests John Snow
2025-04-17 21:31 ` [PATCH v2 5/5] qapi: delete un-needed python static analysis configs John Snow
2025-04-22  6:40   ` Markus Armbruster

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).