diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 080d811..b258cea 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -4,7 +4,7 @@ repos: # Apply a consistent format to pyproject.toml files. # https://pyproject-fmt.readthedocs.io/en/latest/ - repo: https://github.com/tox-dev/pyproject-fmt - rev: "1.8.0" + rev: "2.1.3" hooks: - id: pyproject-fmt @@ -42,7 +42,7 @@ repos: # An extremely fast Python linter and formatter. - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.4.2 + rev: v0.4.7 hooks: - id: ruff-format - id: ruff @@ -50,6 +50,6 @@ repos: # Static checker for GitHub Actions workflow files. - repo: https://github.com/rhysd/actionlint - rev: v1.6.27 + rev: v1.7.1 hooks: - id: actionlint diff --git a/pyproject.toml b/pyproject.toml index 8b75559..ae90e36 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,8 +1,16 @@ +[build-system] +build-backend = "poetry.core.masonry.api" +requires = [ + "poetry-core>=1", +] + [tool.poetry] name = "discord-embed" version = "1.0.0" description = "Make nice embeds for Discord" -authors = ["Joakim Hellsén "] +authors = [ + "Joakim Hellsén ", +] license = "GPL-3.0-or-later" [tool.poetry.dependencies] @@ -13,32 +21,33 @@ discord-webhook = "^1.3.1" python-multipart = "^0.0.9" python-dotenv = "^1.0.1" Jinja2 = "^3.1.3" -uvicorn = { extras = ["standard"], version = "^0.30.0" } +uvicorn = { extras = [ + "standard", +], version = "^0.30.0" } [tool.poetry.group.dev.dependencies] httpx = "^0.27.0" pytest = "^8.2.0" pre-commit = "^3.7.0" -[build-system] -build-backend = "poetry.core.masonry.api" -requires = [ - "poetry-core>=1", -] - [tool.ruff] +preview = true fix = true unsafe-fixes = true -preview = true -select = ["ALL"] -ignore = ["D100", "D104", "CPY001", "ANN201", "RUF029"] - -[tool.ruff.pydocstyle] -convention = "google" +select = [ + "ALL", +] +ignore = [ + "D100", + "D104", + "CPY001", + "ANN201", + "RUF029", +] -[tool.ruff.per-file-ignores] -"tests/**/*.py" = [ +per-file-ignores."tests/**/*.py" = [ "S101", # asserts allowed in tests... "ARG", # Unused function args -> fixtures nevertheless are functionally relevant... "FBT", # Don't care about booleans as positional arguments in tests, e.g. via @pytest.mark.parametrize() ] +pydocstyle.convention = "google"