[tool.poetry] name = "aiomqtt" version = "0.0.0" # Placeholder: Managed by poetry-dynamic-versioning description = "The idiomatic asyncio MQTT client, wrapped around paho-mqtt" license = "BSD-3-Clause" authors = ["Frederik Aalund ", "Felix Böhm ", "Jonathan Plasse "] readme = "README.md" packages = [{include = "aiomqtt"}] repository = "https://github.com/sbtinstruments/aiomqtt" documentation = "https://sbtinstruments.github.io/aiomqtt" keywords = ["mqtt", "iot", "internet-of-things", "asyncio", "paho-mqtt", "mqttv5"] classifiers = [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "Operating System :: OS Independent", ] [tool.poetry.urls] "Issue tracker" = "https://github.com/sbtinstruments/aiomqtt/issues" [tool.poetry.dependencies] python = "^3.8" paho-mqtt = "^2.1.0" typing-extensions = {version = "^4.4.0", markers = "python_version < '3.10'"} [tool.poetry.group.dev] optional = true [tool.poetry.group.dev.dependencies] mypy = "^1.10.0" ruff = "^0.4.8" pytest = "^7.3.1" pytest-cov = "^4.0.0" anyio = "^3.6.2" furo = "^2023.3.27" sphinx-autobuild = "^2021.3.14" myst-parser = "^1.0.0" sphinx-copybutton = "^0.5.2" sphinx = "^5.3" [tool.poetry-dynamic-versioning] enable = true vcs = "git" style = "pep440" strict = true metadata = false [build-system] requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning>=1.0.0"] build-backend = "poetry_dynamic_versioning.backend" [tool.ruff] target-version = "py38" [tool.ruff.lint] select = [ "F", # Pyflakes "E", # pycodestyle "W", # pycodestyle "C90", # mccabe "I", # isort "N", # pep8-naming "D", # pydocstyle "UP", # pyupgrade "YTT", # flake8-2020 "ANN", # flake8-annotations "S", # flake8-bandit "B", # flake8-bugbear "A", # flake8-builtins "COM", # flake8-commas "C4", # flake8-comprehensions "EM", # flake8-errmsg "ISC", # flake8-implicit-str-concat "ICN", # flake8-import-conventions "INP", # flake8-no-pep420 "PIE", # flake8-pie "T20", # flake8-print "PT", # flake8-pytest-style "RSE", # flake8-raise "RET", # flake8-return "SLF", # flake8-self "SIM", # flake8-simplify "TID", # flake8-tidy-imports "PTH", # flake8-use-pathlib "TD", # flake8-todos "ERA", # eradicate "PGH", # pygrep-hooks "PL", # Pylint "TRY", # tryceratops "RUF", # Ruff-specific rules "G", # flake8-logging-format ] ignore = [ "ANN101", # missing-type-self "ANN102", # missing-type-cls "ANN401", # dynamically-typed-expression "BLE001", # blind-except "COM", # trailing-comma "D10", # missing-docstring "E501", # line-too-long "ISC001", # single-line-implicit-string-concatenation "SIM105", # use-contextlib-suppress "TD003", # missing-todo-link ] unfixable = [ "ERA001", # commented-out-code "F401", # unused-import "F841", # unused-variable "T20", # print-found ] task-tags = ["SPDX-License-Identifier"] [tool.ruff.lint.per-file-ignores] "tests/*.py" = [ "S101", # assert-used ] "tests/test_client.py" = [ "SLF001", # private-member-access ] [tool.ruff.lint.flake8-pytest-style] # https://github.com/charliermarsh/ruff#flake8-pytest-style-pt fixture-parentheses = false mark-parentheses = false parametrize-names-type = "csv" [tool.ruff.lint.pydocstyle] # https://github.com/charliermarsh/ruff#pydocstyle convention = "google" [tool.mypy] # https://mypy.readthedocs.io/en/latest/config_file.html python_version = "3.8" strict = true show_column_numbers = true show_error_codes = true show_error_context = true pretty = true [tool.pytest.ini_options] # https://docs.pytest.org/en/latest/reference/reference.html#ini-options-ref filterwarnings = [ "error", "ignore:ssl.PROTOCOL_TLS is deprecated:DeprecationWarning", # TODO(jonathan): Remove these once we finish the migration to the new API "ignore:Callback API version 1 is deprecated, update to latest version:DeprecationWarning", ] markers = [ "network: tests that requires network access" ] xfail_strict = true [tool.coverage.run] # https://coverage.readthedocs.io/en/latest/config.html#run branch = true data_file = "reports/.coverage" [tool.coverage.report] # https://coverage.readthedocs.io/en/latest/config.html#report show_missing = true # Regexes for lines to exclude from consideration exclude_lines = [ # Have to re-enable the standard pragma "pragma: no cover", # Don't complain if tests do not hit defensive assertion code: "raise AssertionError", "raise NotImplementedError", ] [tool.coverage.xml] # https://coverage.readthedocs.io/en/latest/config.html#xml output = "reports/coverage.xml"