Files
brewman/brewman/pyproject.toml
2026-02-18 10:08:27 +00:00

126 lines
2.9 KiB
TOML

[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.mypy]
# --strict
# Good safety defaults
warn_return_any = true
warn_unused_configs = true
warn_redundant_casts = true
warn_unused_ignores = true
no_implicit_optional = true
strict_equality = true
# Practical ergonomics
pretty = true
show_error_codes = true
show_column_numbers = true
error_summary = true
# These keep signal high in real-world FastAPI projects
disallow_any_generics = true
check_untyped_defs = true
# Start here; tighten later
disallow_untyped_calls = true
disallow_incomplete_defs = true
disallow_subclassing_any = true
disallow_untyped_defs = true
disallow_untyped_decorators = true
plugins = ["sqlalchemy.ext.mypy.plugin", "pydantic.mypy"]
# --strict end
[tool.poetry]
name = "brewman"
version = "14.0.0"
description = "Accounting plus inventory management for a restaurant."
authors = ["tanshu <git@tanshu.com>"]
[tool.poetry.dependencies]
PyJWT = "^2.11.0"
SQLAlchemy = "^2.0.46"
alembic = "^1.18.4"
arq = "^0.27.0"
cryptography = "^46.0.5"
fastapi = { extras = ["all"], version = "^0.129.0" }
gunicorn = "^25.1.0"
itsdangerous = "^2.2.0"
openpyxl = "^3.1.5"
pandas = "^3.0.1"
passlib = { extras = ["bcrypt"], version = "^1.7.4" }
psycopg = { extras = ["binary", "pool"], version = "^3.3.2" }
pydantic = { extras = ["dotenv"], version = "^2.12.5" }
python = "^3.14"
python-dotenv = "^1.2.1"
python-multipart = "^0.0.22"
uvicorn = { extras = ["standard"], version = "^0.41.0" }
[tool.poetry.group.dev.dependencies]
bandit = "^1.9.3"
mypy = "^1.19.1"
pre-commit = "^4.5.1"
ruff = "^0.15.1"
# safety = "^3.7.0"
types-openpyxl = "^3.1.5.20250919"
[tool.pydantic-mypy]
init_forbid_extra = true
init_typed = true
warn_required_dynamic_aliases = true
[tool.ruff]
line-length = 120
# Assume Python 3.14.
target-version = "py314"
exclude = [
".eggs",
".git",
".hg",
".mypy_cache",
".tox",
".venv",
"_build",
"buck-out",
"build",
]
[tool.ruff.lint]
# Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default.
# Unlike Flake8, Ruff doesn't enable pycodestyle warnings (`W`) or
# McCabe complexity (`C901`) by default.
# select = ["E4", "E7", "E9", "F"]
select = [
# pycodestyle
"E",
# Pyflakes
"F",
# pyupgrade
"UP",
# flake8-bugbear
# "B",
# flake8-simplify
"SIM",
# isort
"I",
]
ignore = ["E203", "E501"]
# Allow fix for all enabled rules (when `--fix`) is provided.
fixable = ["ALL"]
# Avoid trying to fix flake8-bugbear (`B`) violations.
unfixable = ["B", "F401"]
[tool.ruff.lint.isort]
# include-trailing-comma = true
lines-after-imports = 2
lines-between-types = 1
# use-parentheses = true
[tool.ruff.format]
# Like Black, use double quotes for strings.
quote-style = "double"
# Like Black, indent with spaces, rather than tabs.
indent-style = "space"
# Like Black, respect magic trailing commas.
skip-magic-trailing-comma = false
# Like Black, automatically detect the appropriate line ending.
line-ending = "auto"