[build-system]
requires = ["setuptools>=61.0", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "moneywiz-mcp-server"
version = "1.0.0"
description = "MCP server for MoneyWiz financial data integration"
authors = [
{name = "MoneyWiz MCP Team", email = "dev@example.com"}
]
readme = "README.md"
license = {text = "MIT"}
requires-python = ">=3.10"
keywords = ["mcp", "moneywiz", "finance", "ai", "claude"]
classifiers = [
"Development Status :: 4 - Beta",
"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",
"Topic :: Office/Business :: Financial",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"mcp[cli]>=1.0.0",
"aiosqlite>=0.19.0",
"python-dateutil>=2.8.0",
"pydantic>=2.0.0",
"python-dotenv>=1.0.0",
"typing-extensions>=4.8.0",
]
[project.optional-dependencies]
dev = [
"pytest>=8.4.0",
"pytest-asyncio>=1.1.0",
"pytest-cov>=4.1.0",
"pytest-mock>=3.11.0",
"ruff==0.12.4",
"types-python-dateutil>=2.8.0",
"mypy>=1.8.0",
"pre-commit>=3.6.0",
"bandit>=1.7.5",
]
test = [
"pytest>=8.4.0",
"pytest-asyncio>=1.1.0",
"pytest-cov>=4.1.0",
"pytest-mock>=3.11.0",
"coverage[toml]>=7.9.0",
]
[project.scripts]
moneywiz-mcp-server = "moneywiz_mcp_server.main:cli_main"
[project.urls]
"Homepage" = "https://github.com/jcvalerio/moneywiz-mcp-server"
"Bug Reports" = "https://github.com/jcvalerio/moneywiz-mcp-server/issues"
"Source" = "https://github.com/jcvalerio/moneywiz-mcp-server"
[tool.setuptools.packages.find]
where = ["src"]
[tool.setuptools.package-dir]
"" = "src"
# Testing configuration
[tool.pytest.ini_options]
minversion = "7.0"
addopts = [
"--strict-markers",
"--strict-config",
"--cov=moneywiz_mcp_server",
"--cov-report=term-missing",
"--cov-report=html",
"--cov-report=xml",
"--cov-fail-under=30", # Reasonable coverage target for current state
]
testpaths = ["tests"]
asyncio_mode = "auto"
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
"integration: marks tests as integration tests",
"unit: marks tests as unit tests",
]
[tool.coverage.run]
source = ["src"]
omit = [
"*/tests/*",
"*/test_*",
"*/__pycache__/*",
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"def __repr__",
"if self.debug:",
"if settings.DEBUG",
"raise AssertionError",
"raise NotImplementedError",
"if 0:",
"if __name__ == .__main__.:",
"class .*\\bProtocol\\):",
"@(abc\\.)?abstractmethod",
]
# Ruff configuration (modern linter + formatter)
[tool.ruff]
target-version = "py310"
line-length = 88
exclude = [
".bzr",
".direnv",
".eggs",
".git",
".git-rewrite",
".hg",
".mypy_cache",
".nox",
".pants.d",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"venv",
]
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
"I", # isort
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"UP", # pyupgrade
"ARG001", # unused arguments
"SIM", # flake8-simplify
"TCH", # flake8-type-checking
"TID", # flake8-tidy-imports
"Q", # flake8-quotes
"PGH", # pygrep-hooks
"PIE", # flake8-pie
"PL", # pylint
"PT", # flake8-pytest-style
"PTH", # flake8-use-pathlib
"ERA", # eradicate
"PD", # pandas-vet
"PYI", # flake8-pyi
"NPY", # numpy
"PERF", # perflint
"RUF", # ruff-specific rules
]
ignore = [
"PLR0913", # too many arguments
"PLR0912", # too many branches
"PLR0915", # too many statements
"PLR2004", # magic value comparison
"PD901", # pandas df generic names
"PT011", # pytest-raises-too-broad
# Temporary ignores to unblock CI - to be addressed in follow-up
"PLR0911", # too many return statements (date parser)
"PLW2901", # redefined loop variable (env loader)
"PTH110", # os.path.exists (legacy paths)
"PTH118", # os.path.join (legacy paths)
"PTH120", # os.path.dirname (legacy paths)
"PTH123", # open() vs Path.open() (minor modernization)
"ARG001", # unused function argument (interface compliance)
"F401", # unused import (tools not yet implemented)
"E501", # line too long (formatter handles most cases)
"PLC0415", # import outside top-level (acceptable in some contexts)
"PLW0603", # global statement (acceptable for singleton patterns)
"SIM103", # simplify bool return (readability preference)
]
[tool.ruff.lint.per-file-ignores]
"tests/**/*" = ["PLR2004", "S101", "TID252", "PLC0415", "E501"]
"scripts/**/*" = ["T201", "S603", "S607"] # Allow print, subprocess calls
"**/test_*.py" = ["PLC0415", "E501", "ARG001"]
"continue-development.py" = ["PLC0415"]
"analyze_schema.py" = ["PLC0415"]
"setup_env.py" = ["PLC0415"]
"test_mcp_*.py" = ["PLC0415", "E501", "ARG001"]
[tool.ruff.lint.isort]
known-first-party = ["moneywiz_mcp_server"]
force-sort-within-sections = true
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
skip-magic-trailing-comma = false
line-ending = "auto"
# Type checking
[tool.mypy]
python_version = "3.10"
strict = true
warn_return_any = true
warn_unused_configs = true
disallow_any_generics = true
disallow_subclassing_any = true
disallow_untyped_calls = 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
strict_equality = true
show_error_codes = true
show_column_numbers = true
pretty = true
mypy_path = "src"
[[tool.mypy.overrides]]
module = [
"moneywiz_api.*",
"mcp.*",
"aiosqlite.*",
"investigate_scheduled_transactions",
"investigate_budgets",
"investigate_budgets_deep",
"focused_scheduled_investigation",
"final_scheduled_investigation",
]
ignore_missing_imports = true
# Bandit security configuration
[tool.bandit]
exclude_dirs = ["tests", "scripts"]
tests = ["B201", "B301"]
skips = ["B101", "B601", "B110", "B608"] # B110: try-except-pass, B608: hardcoded SQL (false positive)