[tool.poetry] name = "template-backend-service" version = "0.1.2" description = "" authors = ["Nadezhda Lavrenteva "] readme = "README.md" [tool.poetry.dependencies] python = ">=3.12 <3.13" coverage = "^7.6.1" avroid-service-lib = "^0.0.6" [[tool.poetry.source]] name = "nexus" url = "https://nexus.avroid.tech/repository/tavro-cloud-pypi-release/simple" priority = "supplemental" [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" [tool.poetry.group.dev.dependencies] python = ">=3.12 <3.13" alembic = "^1.13.3" fastapi = "^0.115.0" kafka-python = "^2.0.2" pydantic = "^2.9.2" sqlalchemy = "^2.0.35" pydantic-settings = "^2.5.2" uvicorn = "^0.31.0" pyyaml = "^6.0.2" aiopg = {version = "^1.4.0", extras = ["sa"]} httpx = "^0.27.2" structlog = "^24.4.0" orjson = "^3.10.12" [tool.poetry.group.format.dependencies] mypy = "^1.11.2" ruff = "^0.6.8" pre-commit = "^3.8.0" [tool.poetry.group.tests.dependencies] pytest-mock = "^3.14.0" pytest-asyncio = "^0.24.0" pytest-cov = "^5.0.0" [tool.pytest.ini_options] asyncio_mode = "auto" asyncio_default_fixture_loop_scope = "function" [tool.coverage.run] omit = ["tests/*"] concurrency = ["greenlet", "thread"] [tool.mypy] warn_redundant_casts = true disallow_any_generics = true disallow_untyped_calls = true disallow_untyped_defs = true disallow_incomplete_defs = true check_untyped_defs = true no_implicit_optional = true warn_unused_ignores = true warn_return_any = true strict_equality = true ignore_missing_imports = true plugins = ["pydantic.mypy"] [[tool.mypy.overrides]] module = "tests.*,migrations.*" ignore_errors = true [tool.ruff] line-length = 120 [tool.ruff.lint] select = [ "E", "F", "W", "C90", "I", "N", "UP", "YTT", "ASYNC", "S", "B", "C4", "DTZ", "T10", "ISC", "ICN", "PIE", "T20", "PT", "Q", "RET", "SLF", "SIM", "ERA", "PLE", "TRY", "PYI", "PERF", "LOG", "RUF008", "RUF009", "RUF012", "RUF013", "RUF015", "RUF019", "RUF100", "RUF200" ] unfixable = [ "ERA", # do not autoremove commented out code ] ignore = [ "TRY003", "ISC001", # may cause conflicts when used with the formatter ] [tool.ruff.lint.per-file-ignores] "tests/*" = ["S", "C4", "ISC", "SLF", "RUF012"] "src/*" = ["PT"] "migrations/*" = ["S", "C4", "ISC", "SLF", "RUF012", "ERA001"] [tool.ruff.lint.pep8-naming] # Allow Pydantic's `@validator` decorator to trigger class method treatment. classmethod-decorators = [ "classmethod", "pydantic.validator", "pydantic.root_validator", ] [tool.ruff.lint.flake8-bugbear] extend-immutable-calls = ["fastapi.Depends", "fastapi.Query", "fastapi.Form", "fastapi.Body"]