# --- BUILD SYSTEM ---
[build-system]
requires = ["uv_build>=0.8.22,<0.9.0"]
build-backend = "uv_build"
# --- PROJECT ---
[project]
name = "linear-mcp"
version = "0.0.1"
description = "A Linear MCP server for Dedalus."
readme = "README.md"
requires-python = ">=3.11"
license = { text = "MIT" }
authors = [
{ name = "Dedalus Labs", email = "oss@dedaluslabs.ai" },
]
maintainers = [
{ name = "Dedalus Labs", email = "oss@dedaluslabs.ai" },
]
keywords = ["ai", "mcp", "agents", "dedalus", "linear"]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Typing :: Typed",
]
dependencies = [
"dedalus-mcp>=0.7.0",
"pydantic>=2.12.5",
"python-dotenv>=1.2.1",
"uvloop>=0.22.1; platform_system != 'Windows'",
]
# --- PROJECT URLS ---
[project.urls]
Homepage = "https://github.com/dedalus-labs/linear-mcp"
Repository = "https://github.com/dedalus-labs/linear-mcp"
Issues = "https://github.com/dedalus-labs/linear-mcp/issues"
# --- DEPENDENCY GROUPS ---
[dependency-groups]
runtime = [
"pydantic>=2.12.5",
"uvloop>=0.22.1; platform_system != 'Windows'",
]
test = [
"anyio>=4.11.0",
"pytest>=8.4.2",
"pytest-asyncio>=1.2.0",
"pytest-cov>=7.0.0",
"pytest-mock>=3.15.1",
]
lint = ["ruff>=0.13.3", "pre-commit>=4.3.0", "ty>=0.0.1a21"]
debug = ["pdbpp>=0.10.3", "icecream>=2.1.8"]
dev = [
{ include-group = "runtime" },
{ include-group = "test" },
{ include-group = "lint" },
{ include-group = "debug" },
]
# --- UV ---
[tool.uv]
preview = true
package = false # runnable project, not a distributable package
default-groups = ["runtime"]
cache-dir = ".cache/uv"
compile-bytecode = true
link-mode = "hardlink" # macOS/Linux only
environments = ["sys_platform == 'linux'", "sys_platform == 'darwin'"]
concurrent-downloads = 50
concurrent-builds = 4
concurrent-installs = 4
resolution = "highest"
prerelease = "if-necessary"
fork-strategy = "fewest"
index-strategy = "first-index"
python-preference = "managed"
python-downloads = "automatic"
[tool.uv.sources]
[tool.uv.build-backend]
source-exclude = [
"dist/**",
"**/__pycache__/**",
"**/build/**",
"**/.pytest_cache/**",
"**/.mypy_cache/**",
]
# --- RUFF ---
[tool.ruff]
line-length = 88
target-version = "py311"
extend-exclude = ["build/", "dist/", ".venv/", "__pycache__/"]
# --- RUFF FORMATTING ---
[tool.ruff.format]
docstring-code-format = true
docstring-code-line-length = 72
skip-magic-trailing-comma = false # trailing commas → multi-line (minimise diffs)
quote-style = "double"
indent-style = "space"
# --- RUFF LINTING ---
[tool.ruff.lint]
select = [
# Core
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
# Imports
"I", # isort
"UP", # pyupgrade
# Quality
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"SIM", # flake8-simplify
"RUF", # ruff-specific
# Docs & style
"D", # pydocstyle
"N", # pep8-naming
# Types
"ANN", # flake8-annotations
"TCH", # flake8-type-checking
# Security
"S", # bandit
# Error handling
"BLE", # flake8-blind-except
"TRY", # tryceratops
"RSE", # flake8-raise
"RET", # flake8-return
# Performance
"PERF", # perflint
"FLY", # flynt
"FURB", # refurb
# Misc
"ARG", # flake8-unused-arguments
"COM", # flake8-commas
"DTZ", # flake8-datetimez
"EM", # flake8-errmsg
"ERA", # eradicate
"EXE", # flake8-executable
"FBT", # flake8-boolean-trap
"G", # flake8-logging-format
"ICN", # flake8-import-conventions
"INP", # flake8-no-pep420
"INT", # flake8-gettext
"ISC", # flake8-implicit-str-concat
"LOG", # flake8-logging
"PD", # pandas-vet
"PGH", # pygrep-hooks
"PIE", # flake8-pie
"PL", # pylint
"PT", # flake8-pytest-style
"PTH", # flake8-use-pathlib
"PYI", # flake8-pyi
"Q", # flake8-quotes
"SLF", # flake8-self
"SLOT", # flake8-slots
"T20", # flake8-print
"TID", # tidy imports
]
ignore = [
# Handled by formatter
"COM812", # trailing comma
"E501", # line too long
"ISC001", # implicit str concat
# Imports
"E402", # module-level import not at top
"TID252", # prefer absolute imports
# Docstrings (we use module-level catalogs instead)
"D100", # missing module docstring
"D101", # missing class docstring
"D102", # missing method docstring
"D103", # missing function docstring
"D104", # missing package docstring
"D105", # missing magic method docstring
"D107", # missing __init__ docstring
# Acceptable in this project
"S101", # assert
"T201", # print
"RET504", # assignment before return
# Tool functions take many params and use bool flags
"FBT001", # boolean positional arg
"FBT002", # boolean default positional arg
"PLR0911", # too many return statements
"PLR0912", # too many branches
"PLR0913", # too many arguments (tools are param-heavy by nature)
]
unfixable = ["B", "TRY", "RUF"]
# --- RUFF PYDOCSTYLE ---
[tool.ruff.lint.pydocstyle]
convention = "google"
# --- RUFF ISORT ---
[tool.ruff.lint.isort]
known-first-party = ["src"]
force-single-line = false
force-sort-within-sections = true
section-order = [
"future",
"standard-library",
"third-party",
"first-party",
"local-folder",
]
split-on-trailing-comma = true
lines-after-imports = 2
relative-imports-order = "closest-to-furthest"
# --- RUFF FLAKE8-QUOTES ---
[tool.ruff.lint.flake8-quotes]
docstring-quotes = "double"
inline-quotes = "double"
# --- RUFF FLAKE8-ANNOTATIONS ---
[tool.ruff.lint.flake8-annotations]
allow-star-arg-any = true
ignore-fully-untyped = true # skip files with zero annotations
# --- RUFF PYLINT ---
[tool.ruff.lint.pylint]
max-args = 8 # tool funcs take many params
# --- PYTEST ---
[tool.pytest.ini_options]
asyncio_mode = "auto"
asyncio_default_fixture_loop_scope = "function"
testpaths = ["tests"]
python_files = ["test_*.py", "*_test.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
addopts = [
"--strict-markers",
"--strict-config",
"--tb=short",
"--cov=src",
"--cov-report=term-missing",
"--cov-report=html",
"--cov-report=xml",
"--cov-fail-under=60",
"-v",
"--color=yes",
]
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
"integration: marks tests as integration tests",
"unit: marks tests as unit tests",
]
filterwarnings = [
"error",
"ignore::UserWarning",
"ignore::DeprecationWarning",
"ignore::pytest.PytestUnraisableExceptionWarning",
]
log_cli = false
log_cli_level = "INFO"
log_cli_format = "%(asctime)s [%(levelname)8s] %(message)s"
log_cli_date_format = "%Y-%m-%d %H:%M:%S"
# --- COVERAGE ---
[tool.coverage.run]
source = ["src"]
omit = ["tests/*", "*/tests/*", "test_*.py", "*_test.py"]
[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 .*\\(.*Protocol.*\\):",
"@(abc\\.)?abstractmethod",
]
# --- TY ---
[tool.ty.rules]
# Type safety
unresolved-import = "ignore" # third-party stubs not always available
invalid-assignment = "error"
invalid-return-type = "error"
invalid-argument-type = "error"
missing-argument = "error"
too-many-positional-arguments = "error"
unresolved-reference = "error"
# Inheritance
invalid-base = "error"
conflicting-metaclass = "error"
subclass-of-final-class = "error"
# Warnings
undefined-reveal = "warn"
# Ignored
division-by-zero = "ignore" # caught at runtime
unused-ignore-comment = "ignore" # keep for dev flexibility
# --- TY ENVIRONMENT ---
[tool.ty.environment]
root = ["src"]
python-platform = "darwin"
python-version = "3.11"
# --- TY TERMINAL ---
[tool.ty.terminal]
output-format = "concise"
error-on-warning = false
# --- TY SOURCE ---
[tool.ty.src]
include = ["**/*.py", "**/*.pyi"]
exclude = [
"build/**",
"dist/**",
".venv/**",
"__pycache__/**",
"*.egg-info/**",
".pytest_cache/**",
".ruff_cache/**",
".mypy_cache/**",
]
respect-ignore-files = true