[project]
name = "uart-mcp"
version = "0.1.0"
description = "UART MCP Server - 为AI助手提供串口通信能力"
readme = "README.md"
requires-python = ">=3.13"
license = "MIT"
keywords = ["mcp", "uart", "serial", "ai", "llm"]
dependencies = [
"pyserial>=3.5",
"mcp>=1.0.0",
]
[project.scripts]
uart-mcp = "uart_mcp:main"
[project.optional-dependencies]
dev = [
"pytest>=7.0",
"pytest-asyncio>=0.21",
"ruff>=0.1",
"mypy>=1.0",
]
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = ["src/uart_mcp"]
[tool.ruff]
line-length = 120
target-version = "py313"
[tool.ruff.lint]
select = ["E", "F", "I", "N", "W"]
ignore = ["E501"] # 忽略行长度检查,使用 line-length 控制
[tool.mypy]
python_version = "3.13"
strict = true
[tool.pytest.ini_options]
pythonpath = ["src"]
testpaths = ["tests"]
addopts = "--ignore=tests/test_integration_real_port.py"
[dependency-groups]
dev = [
"pytest-cov>=7.0.0",
"types-pyserial>=3.5.0.20251001",
]