1[metadata] 2name = qemu 3version = file:VERSION 4maintainer = QEMU Developer Team 5maintainer_email = qemu-devel@nongnu.org 6url = https://www.qemu.org/ 7download_url = https://www.qemu.org/download/ 8description = QEMU Python Build, Debug and SDK tooling. 9long_description = file:PACKAGE.rst 10long_description_content_type = text/x-rst 11classifiers = 12 Development Status :: 3 - Alpha 13 License :: OSI Approved :: GNU General Public License v2 (GPLv2) 14 Natural Language :: English 15 Operating System :: OS Independent 16 Programming Language :: Python :: 3 :: Only 17 Programming Language :: Python :: 3.8 18 Programming Language :: Python :: 3.9 19 Programming Language :: Python :: 3.10 20 Programming Language :: Python :: 3.11 21 Programming Language :: Python :: 3.12 22 Programming Language :: Python :: 3.13 23 Typing :: Typed 24 25[options] 26python_requires = >= 3.8 27packages = 28 qemu.qmp 29 qemu.machine 30 qemu.utils 31 32[options.package_data] 33* = py.typed 34 35[options.extras_require] 36# Remember to update tests/minreqs.txt if changing anything below: 37devel = 38 avocado-framework >= 90.0 39 distlib >= 0.3.6 40 flake8 >= 5.0.4 41 fusepy >= 2.0.4 42 isort >= 5.1.2 43 mypy >= 1.4.0 44 pylint >= 2.17.3 45 pylint != 3.2.4; python_version<"3.9" 46 tox >= 3.18.0 47 urwid >= 2.1.2 48 urwid-readline >= 0.13 49 Pygments >= 2.9.0 50 51# Provides qom-fuse functionality 52fuse = 53 fusepy >= 2.0.4 54 55# QMP TUI dependencies 56tui = 57 urwid >= 2.1.2 58 urwid-readline >= 0.13 59 Pygments >= 2.9.0 60 61[options.entry_points] 62console_scripts = 63 qom = qemu.utils.qom:main 64 qom-set = qemu.utils.qom:QOMSet.entry_point 65 qom-get = qemu.utils.qom:QOMGet.entry_point 66 qom-list = qemu.utils.qom:QOMList.entry_point 67 qom-tree = qemu.utils.qom:QOMTree.entry_point 68 qom-fuse = qemu.utils.qom_fuse:QOMFuse.entry_point [fuse] 69 qemu-ga-client = qemu.utils.qemu_ga_client:main 70 qmp-shell = qemu.qmp.qmp_shell:main 71 qmp-shell-wrap = qemu.qmp.qmp_shell:main_wrap 72 qmp-tui = qemu.qmp.qmp_tui:main [tui] 73 74[flake8] 75# Prefer pylint's bare-except checks to flake8's 76extend-ignore = E722 77exclude = __pycache__, 78 79[mypy] 80strict = True 81python_version = 3.8 82warn_unused_configs = True 83namespace_packages = True 84warn_unused_ignores = False 85 86[mypy-qemu.utils.qom_fuse] 87# fusepy has no type stubs: 88allow_subclassing_any = True 89 90[mypy-qemu.qmp.qmp_tui] 91# urwid and urwid_readline have no type stubs: 92allow_subclassing_any = True 93 94# The following missing import directives are because these libraries do not 95# provide type stubs. Allow them on an as-needed basis for mypy. 96[mypy-fuse] 97ignore_missing_imports = True 98 99[mypy-tomli] 100ignore_missing_imports = True 101 102[mypy-tomllib] 103ignore_missing_imports = True 104 105[mypy-urwid] 106ignore_missing_imports = True 107 108[mypy-urwid_readline] 109ignore_missing_imports = True 110 111[mypy-pygments] 112ignore_missing_imports = True 113 114[mypy-distlib] 115ignore_missing_imports = True 116 117[mypy-distlib.scripts] 118ignore_missing_imports = True 119 120[mypy-distlib.version] 121ignore_missing_imports = True 122 123[mypy-pip._vendor.distlib] 124ignore_missing_imports = True 125 126[mypy-pip._vendor.distlib.scripts] 127ignore_missing_imports = True 128 129[mypy-pip._vendor.distlib.version] 130ignore_missing_imports = True 131 132[pylint.messages control] 133# Disable the message, report, category or checker with the given id(s). You 134# can either give multiple identifiers separated by comma (,) or put this 135# option multiple times (only on the command line, not in the configuration 136# file where it should appear only once). You can also use "--disable=all" to 137# disable everything first and then reenable specific checks. For example, if 138# you want to run only the similarities checker, you can use "--disable=all 139# --enable=similarities". If you want to run only the classes checker, but have 140# no Warning level messages displayed, use "--disable=all --enable=classes 141# --disable=W". 142disable=consider-using-f-string, 143 consider-using-with, 144 too-many-arguments, 145 too-many-positional-arguments, 146 too-many-function-args, # mypy handles this with less false positives. 147 too-many-instance-attributes, 148 no-member, # mypy also handles this better. 149 150[pylint.basic] 151# Good variable names which should always be accepted, separated by a comma. 152good-names=i, 153 j, 154 k, 155 ex, 156 Run, 157 _, # By convention: Unused variable 158 fh, # fh = open(...) 159 fd, # fd = os.open(...) 160 c, # for c in string: ... 161 T, # for TypeVars. See pylint#3401 162 SocketAddrT, # Not sure why this is invalid. 163 164[pylint.similarities] 165# Ignore imports when computing similarities. 166ignore-imports=yes 167ignore-signatures=yes 168 169# Minimum lines number of a similarity. 170# TODO: Remove after we opt in to Pylint 2.8.3. See commit msg. 171min-similarity-lines=6 172 173 174[isort] 175force_grid_wrap=4 176force_sort_within_sections=True 177include_trailing_comma=True 178line_length=72 179lines_after_imports=2 180multi_line_output=3 181 182# tox (https://tox.readthedocs.io/) is a tool for running tests in 183# multiple virtualenvs. This configuration file will run the test suite 184# on all supported python versions. To use it, "pip install tox" and 185# then run "tox" from this directory. You will need all of these versions 186# of python available on your system to run this test. 187 188[tox:tox] 189envlist = py38, py39, py310, py311, py312, py313 190skip_missing_interpreters = true 191 192[testenv] 193allowlist_externals = make 194deps = 195 .[devel] 196 .[fuse] # Workaround to trigger tox venv rebuild 197 .[tui] # Workaround to trigger tox venv rebuild 198commands = 199 make check 200 201# Coverage.py [https://coverage.readthedocs.io/en/latest/] is a tool for 202# measuring code coverage of Python programs. It monitors your program, 203# noting which parts of the code have been executed, then analyzes the 204# source to identify code that could have been executed but was not. 205 206[coverage:run] 207concurrency = multiprocessing 208source = qemu/ 209parallel = true 210