forked from okhsunrog/km003c-protocol-research
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
98 lines (86 loc) · 2.33 KB
/
pyproject.toml
File metadata and controls
98 lines (86 loc) · 2.33 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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
[build-system]
# Use maturin as the build backend to build the Rust extension when this
# project is packaged. For day-to-day dev, prefer `uv run maturin develop`.
requires = ["maturin>=1.5,<2.0"]
build-backend = "maturin"
[project]
name = "km003c-protocol-research"
version = "0.1.0"
requires-python = ">=3.11"
classifiers = [
"Programming Language :: Rust",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
]
dependencies = [
"matplotlib>=3.5.0",
"seaborn>=0.11.0",
"numpy>=2.3.3",
"usbpdpy>=0.2.1",
"polars",
"streamlit>=1.49.1",
"plotly>=6.3.0",
"pyyaml>=6.0.2",
"pyusb>=1.3.1",
"pycryptodome>=3.23.0",
]
[tool.maturin]
# Build the external Rust crate that exports the `km003c_lib` python module.
# The crate uses the `python` feature to enable pyo3 bindings.
bindings = "pyo3"
features = ["python"]
manifest-path = "/home/okhsunrog/code/rust/km003c-rs/km003c-lib/Cargo.toml"
[dependency-groups]
dev = [
"pytest>=8.2.2",
"pytest-asyncio>=0.23.7",
"mypy>=1.18.1",
"types-pyyaml>=6.0.12",
"ruff>=0.13.0",
"maturin>=1.5,<2.0",
]
[tool.mypy]
python_version = "3.11"
strict = true
warn_return_any = true
warn_unused_configs = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
check_untyped_defs = true
disallow_untyped_decorators = true
no_implicit_optional = true
warn_redundant_casts = true
warn_unused_ignores = true
warn_no_return = true
warn_unreachable = true
implicit_reexport = false
strict_equality = true
[[tool.mypy.overrides]]
module = ["plotly.*", "km003c_lib.*", "streamlit.*"]
ignore_missing_imports = true
[[tool.mypy.overrides]]
module = ["tests.*"]
disallow_untyped_defs = false
disallow_incomplete_defs = false
[tool.ruff.lint]
ignore = ["E402", "F821"]
exclude = ["notebooks/*.ipynb", "tests/*.py"]
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
[tool.pytest.ini_options]
# Test discovery
testpaths = ["tests"]
python_files = ["test_*.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
# Markers
markers = [
"unit: Unit tests (no hardware required, fast)",
"integration: Integration tests (require real KM003C device, slow)",
]
# Default: run only unit tests (fast, no device)
addopts = "-v -m unit"
# Logging
log_cli = false
log_cli_level = "INFO"