forked from sunnypilot/panda
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
75 lines (64 loc) · 1.76 KB
/
pyproject.toml
File metadata and controls
75 lines (64 loc) · 1.76 KB
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
[project]
name = "pandacan"
version = "0.0.10"
description = "Code powering the comma.ai panda"
readme = "README.md"
requires-python = ">=3.11,<3.13" # macOS doesn't work with 3.13 due to pycapnp from opendbc
license = {text = "MIT"}
authors = [{name = "comma.ai"}]
classifiers = [
"Natural Language :: English",
"Programming Language :: Python :: 3",
"Topic :: System :: Hardware",
]
dependencies = [
"libusb1",
"opendbc @ git+https://github.com/sunnypilot/opendbc.git@master#egg=opendbc",
]
[project.optional-dependencies]
dev = [
"scons",
"pycryptodome >= 3.9.8",
"cffi",
"flaky",
"pytest",
"pytest-mock",
"pytest-timeout",
"pytest-randomly",
"ruff",
"mypy",
"setuptools",
"spidev; platform_system == 'Linux'",
]
[build-system]
requires = ["setuptools>=61", "wheel"]
build-backend = "setuptools.build_meta"
[tool.setuptools]
packages = ["panda"]
[tool.setuptools.package-dir]
panda = "."
[tool.mypy]
# third-party packages
ignore_missing_imports = true
# helpful warnings
warn_redundant_casts = true
warn_unreachable = true
warn_unused_ignores = true
# restrict dynamic typing
warn_return_any = true
# https://beta.ruff.rs/docs/configuration/#using-pyprojecttoml
[tool.ruff]
line-length = 160
target-version="py311"
[tool.ruff.lint]
select = ["E", "F", "W", "PIE", "C4", "ISC", "RUF100", "A"]
ignore = ["W292", "E741", "E402", "C408", "ISC003"]
flake8-implicit-str-concat.allow-multiline=false
[tool.ruff.lint.flake8-tidy-imports.banned-api]
"pytest.main".msg = "pytest.main requires special handling that is easy to mess up!"
[tool.pytest.ini_options]
addopts = "-Werror --strict-config --strict-markers --durations=10 --ignore-glob='*.sh' --ignore=tests/misra --ignore=tests/som --ignore=tests/hitl"
python_files = "test_*.py"
testpaths = [
"tests/"
]