mirror of
https://github.com/affaan-m/ECC.git
synced 2026-08-17 21:15:40 +02:00
* ci: add ruff + mypy to the Python CI job and fix pyproject tool config The python-tests job runs pytest but not lint/type checks, and the ruff and mypy configuration in pyproject.toml was silently broken, so neither tool could run at all. - add ruff and mypy steps to the existing python-tests job - fix invalid pyproject keys: [tool.ruff] src-path -> src, [tool.mypy] src_paths -> mypy_path - ignore ruff UP042 (the (str, Enum) mixin is intentional) - resolve ruff findings (unused/unsorted imports) across src and tests - fix mypy errors in tools/executor.py and prompt/builder.py * fix(ci): satisfy Python lint after main refresh --------- Co-authored-by: haelyra <49814733+haelyra@users.noreply.github.com>
84 lines
1.9 KiB
TOML
84 lines
1.9 KiB
TOML
[project]
|
|
name = "llm-abstraction"
|
|
version = "0.1.0"
|
|
description = "Provider-agnostic LLM abstraction layer"
|
|
readme = "README.md"
|
|
requires-python = ">=3.11"
|
|
license = {text = "MIT"}
|
|
authors = [
|
|
{name = "Affaan Mustafa", email = "affaan@example.com"}
|
|
]
|
|
keywords = ["llm", "openai", "anthropic", "ollama", "ai"]
|
|
classifiers = [
|
|
"Development Status :: 3 - Alpha",
|
|
"Intended Audience :: Developers",
|
|
"License :: OSI Approved :: MIT License",
|
|
"Programming Language :: Python :: 3",
|
|
"Programming Language :: Python :: 3.11",
|
|
"Programming Language :: Python :: 3.12",
|
|
]
|
|
|
|
dependencies = [
|
|
"anthropic>=0.120.2",
|
|
"openai>=1.30.0",
|
|
]
|
|
|
|
[project.optional-dependencies]
|
|
dev = [
|
|
"pytest>=9.1.1",
|
|
"pytest-asyncio>=1.4.0",
|
|
"pytest-cov>=7.1.0",
|
|
"pytest-mock>=3.15.1",
|
|
"ruff>=0.16.1",
|
|
"mypy>=2.3.0",
|
|
"pyyaml>=6.0.3",
|
|
]
|
|
|
|
[project.urls]
|
|
Homepage = "https://github.com/affaan-m/ECC"
|
|
Repository = "https://github.com/affaan-m/ECC"
|
|
|
|
[project.scripts]
|
|
llm-select = "llm.cli.selector:main"
|
|
|
|
[build-system]
|
|
requires = ["hatchling"]
|
|
build-backend = "hatchling.build"
|
|
|
|
[tool.hatch.build.targets.wheel]
|
|
packages = ["src/llm"]
|
|
|
|
[tool.pytest.ini_options]
|
|
testpaths = ["tests"]
|
|
asyncio_mode = "auto"
|
|
filterwarnings = ["ignore::DeprecationWarning"]
|
|
|
|
[tool.coverage.run]
|
|
source = ["src/llm"]
|
|
branch = true
|
|
|
|
[tool.coverage.report]
|
|
exclude_lines = [
|
|
"pragma: no cover",
|
|
"if TYPE_CHECKING:",
|
|
"raise NotImplementedError",
|
|
]
|
|
|
|
[tool.ruff]
|
|
src = ["src"]
|
|
target-version = "py311"
|
|
|
|
[tool.ruff.lint]
|
|
select = ["E", "F", "I", "N", "W", "UP"]
|
|
# E501: line length is handled by the formatter, not enforced here.
|
|
# UP042: the (str, Enum) mixin is intentional — enum members must compare
|
|
# and serialize as plain strings across providers. StrEnum changes
|
|
# str() semantics, so the explicit mixin is kept deliberately.
|
|
ignore = ["E501", "UP042"]
|
|
|
|
[tool.mypy]
|
|
python_version = "3.11"
|
|
mypy_path = "src"
|
|
warn_return_any = true
|
|
warn_unused_ignores = true
|