File: pyproject.toml

package info (click to toggle)
python-androidtvremote2 0.1.1-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 356 kB
  • sloc: python: 871; makefile: 5
file content (79 lines) | stat: -rw-r--r-- 2,541 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
[project]
name = "androidtvremote2"
version = "0.1.1"
license = {text = "Apache-2.0"}
authors = [
    { name="tronikos", email="tronikos@gmail.com" },
]
description = "A Python library for interacting with Android TV using the Android TV Remote protocol v2"
readme = "README.md"
requires-python = ">=3.10"
dependencies = [
    "aiofiles>=0.8",
    "cryptography>=3",
    "protobuf>=4.21",
]

[project.urls]
"Homepage" = "https://github.com/tronikos/androidtvremote2"
"Bug Tracker" = "https://github.com/tronikos/androidtvremote2/issues"

[build-system]
requires = ["setuptools"]
build-backend = "setuptools.build_meta"

[tool.black]
extend-exclude = "_pb2.py|_pb2_grpc.py"

[tool.isort]
profile = "black"
force_sort_within_sections = true
combine_as_imports = true
extend_skip_glob = ["*_pb2.py", "*_pb2_grpc.py"]

[tool.ruff]
target-version = "py311"
exclude = ["*_pb2.py", "*_pb2_grpc.py", "*.pyi"]
line-length = 127

select = [
    "B007", # Loop control variable {name} not used within loop body
    "B014", # Exception handler with duplicate exception
    "C",  # complexity
    "D",  # docstrings
    "E",  # pycodestyle
    "F",  # pyflakes/autoflake
    "ICN001", # import concentions; {name} should be imported as {asname}
    "PGH004",  # Use specific rule codes when using noqa
    "PLC0414", # Useless import alias. Import alias does not rename original package.
    "SIM105", # Use contextlib.suppress({exception}) instead of try-except-pass
    "SIM117", # Merge with-statements that use the same scope
    "SIM118", # Use {key} in {dict} instead of {key} in {dict}.keys()
    "SIM201", # Use {left} != {right} instead of not {left} == {right}
    "SIM212", # Use {a} if {a} else {b} instead of {b} if not {a} else {a}
    "SIM300", # Yoda conditions. Use 'age == 42' instead of '42 == age'.
    "SIM401", # Use get from dict with default instead of an if block
    "T20",  # flake8-print
    "TRY004", # Prefer TypeError exception for invalid type
    "RUF006", # Store a reference to the return value of asyncio.create_task
    "UP",  # pyupgrade
    "W",  # pycodestyle
]

ignore = [
    "D203",  # 1 blank line required before class docstring
    "D213",  # Multi-line docstring summary should start at the second line
    # keep-runtime-annotations
    'UP006', # Non PEP585 annotations
    'UP007', # Non PEP604 annotations
]

[tool.ruff.flake8-pytest-style]
fixture-parentheses = false

[tool.ruff.per-file-ignores]
# Allow for demo script to write to stdout
"demo.py" = ["T201"]

[tool.ruff.mccabe]
max-complexity = 25