shortener/pyproject.toml

79 lines
1.6 KiB
TOML

[tool.poetry]
name = "shortener"
version = "0.1.0"
description = ""
authors = ["Gabriel Augendre <gabriel@augendre.info>"]
[tool.poetry.dependencies]
python = "^3.10"
requests = "^2.25.1"
gunicorn = "^20.1.0"
Django = "^4.0"
model-bakery = "^1.3.1"
django-environ = "^0.9.0"
whitenoise = {extras = ["brotli"], version = "^6.0"}
[tool.poetry.dev-dependencies]
pytest = "^7.0"
pytest-django = "^4.4.0"
pre-commit = "^2.13.0"
invoke = "^1.6.0"
pytest-cov = "^3.0.0"
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.black]
target-version = ['py310']
[tool.isort]
profile = "black"
[tool.pytest.ini_options]
addopts = "--color=yes"
minversion = "6.0"
DJANGO_SETTINGS_MODULE = "shortener.settings"
junit_family = "xunit1"
norecursedirs = [
".git",
".pytest_cache",
]
testpaths = [
"src",
]
python_files = [
"test_*.py",
"tests.py",
]
###############################################################################
# flake8 / flakeheaven
###############################################################################
[tool.flakeheaven]
max_complexity = 10
format = "grouped"
# Base rules
#############################
[tool.flakeheaven.plugins]
"*" = [
"+*",
"-E501", # long lines
"-E203", # conflict with black on PEP8 interpretation
"-W503", # deprecated rule: https://www.flake8rules.com/rules/W503.html
]
flake8-docstrings = [
"+*",
"-D1??", # missing docstring
]
# Exceptions
#############################
[tool.flakeheaven.exceptions."**/tests/*"]
flake8-bandit = [
"+*",
"-S101", # Use of assert detected.
]