[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "wemo-mcp-server"
version = "1.2.0"
description = "Model Context Protocol server for WeMo smart home device discovery and control"
authors = [
{name = "apiarya", email = "izzasnvyp7@privaterelay.appleid.com"}
]
readme = "README.md"
requires-python = ">=3.10"
keywords = ["mcp", "wemo", "smart-home", "belkin", "iot", "home-automation"]
license = {text = "MIT"}
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Home Automation",
"Topic :: System :: Networking",
]
dependencies = [
"mcp>=1.2.0",
"httpx>=0.25.0",
"pywemo>=1.4.0",
]
[project.optional-dependencies]
dev = [
"pytest>=7.0.0",
"pytest-asyncio>=0.21.0",
"pytest-cov>=4.1.0",
"black>=23.0.0",
"isort>=5.12.0",
"mypy>=1.0.0",
"ruff>=0.1.0",
"pre-commit>=3.5.0",
]
[project.urls]
Homepage = "https://github.com/apiarya/wemo-mcp-server"
Repository = "https://github.com/apiarya/wemo-mcp-server.git"
Issues = "https://github.com/apiarya/wemo-mcp-server/issues"
[project.scripts]
wemo-mcp-server = "wemo_mcp_server:main"
[tool.hatch.version]
path = "src/wemo_mcp_server/__init__.py"
[tool.hatch.build.targets.sdist]
include = [
"/src",
"/README.md",
"/LICENSE",
]
[tool.hatch.build.targets.wheel]
packages = ["src/wemo_mcp_server"]
[tool.black]
line-length = 100
target-version = ["py310"]
[tool.isort]
profile = "black"
line_length = 100
[tool.mypy]
python_version = "3.10"
warn_return_any = true
warn_unused_configs = true
# Temporarily less strict - will enable gradually
# strict = true
# disallow_untyped_defs = true
ignore_missing_imports = true
check_untyped_defs = true
[tool.ruff]
line-length = 100
target-version = "py310"
[tool.ruff.lint]
select = ["E", "F", "W", "C90", "I", "N", "D", "UP", "YTT", "S", "BLE", "FBT", "B", "A", "COM", "C4", "DTZ", "T10", "DJ", "EM", "EXE", "FA", "ISC", "ICN", "G", "INP", "PIE", "T20", "PYI", "PT", "Q", "RSE", "RET", "SLF", "SLOT", "SIM", "TID", "TCH", "INT", "ARG", "PTH", "ERA", "PD", "PGH", "PL", "TRY", "FLY", "NPY", "AIR", "PERF", "FURB", "LOG", "RUF"]
ignore = [
# Docstring rules (too pedantic for now)
"D100", "D101", "D102", "D103", "D104", "D105", "D106", "D107",
"D203", "D213", "D205", "D400", "D415", "D401",
# Complexity rules (will address gradually)
"C901", "PLR0911", "PLR0912", "PLR0913", "PLR0915", "PLR2004",
# Logging rules (f-strings are fine)
"G004", "G003", "G201",
# Exception handling (current patterns are acceptable)
"BLE001", "S110", "E722", "TRY300", "TRY400", "TRY301", "TRY003", "EM101",
# Performance (premature optimization)
"PERF203", "PERF102",
# Too strict for current codebase
"FBT001", "FBT003", "B007", "RUF013",
# Line length (will fix incrementally)
"E501",
# Print statements and asserts (allowed in tests)
"T201", "S101",
# Test-specific rules
"PLC0415", # Imports inside functions OK in tests
"N806", # Allow MockScanner naming in tests
]
[tool.pytest.ini_options]
asyncio_mode = "auto"
testpaths = ["tests"]
addopts = "-v --cov=wemo_mcp_server --cov-report=term-missing --cov-report=html"
[tool.coverage.run]
source = ["src/wemo_mcp_server"]
omit = [
"tests/*",
"*/__pycache__/*",
"*/site-packages/*",
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"def __repr__",
"def __str__",
"raise AssertionError",
"raise NotImplementedError",
"if __name__ == .__main__.:",
"if TYPE_CHECKING:",
"@abstractmethod",
]
precision = 2
show_missing = true