Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 13 additions & 13 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ ci:
repos:
# Best Practices
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
rev: v6.0.0
hooks:
- id: check-builtin-literals
- id: check-executables-have-shebangs
Expand All @@ -32,13 +32,13 @@ repos:
args: [--markdown-linebreak-ext=md]

# Formatting
- repo: https://github.com/psf/black
rev: 25.1.0
- repo: https://github.com/psf/black-pre-commit-mirror
rev: 26.5.1
hooks:
- id: black

- repo: https://github.com/PyCQA/isort
rev: 6.0.1
rev: 9.0.0b5
hooks:
- id: isort
args: [
Expand All @@ -49,60 +49,60 @@ repos:
]

- repo: https://github.com/maxwinterstein/shfmt-py
rev: v3.7.0.1
rev: v4.0.0
hooks:
- id: shfmt

# Linting
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.9.9
rev: v0.16.3
hooks:
- id: ruff
args: [--fix]
exclude: ^(test_utils/|migrations/|setup\.py)$

- repo: https://github.com/AleksaC/hadolint-py
rev: v2.12.1b3
rev: v2.15.1
hooks:
- id: hadolint
args: [--config, .hadolint.yaml]

- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.10.0.1
rev: v0.11.0.1
hooks:
- id: shellcheck

# Code Quality
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.15.0
rev: v2.3.1
hooks:
- id: mypy
args: [--config-file, pyproject.toml, --warn-unused-configs]

# Security
- repo: https://github.com/PyCQA/bandit
rev: 1.8.3
rev: 1.9.4
hooks:
- id: bandit
args: [-c, pyproject.toml, -r]
additional_dependencies: ["bandit[toml]"]

# Documentation, Spelling
- repo: https://github.com/alessandrojcm/commitlint-pre-commit-hook
rev: v9.21.0
rev: v9.26.0
hooks:
- id: commitlint
stages: [commit-msg]
additional_dependencies: ['@commitlint/config-conventional']

- repo: https://github.com/igorshubovych/markdownlint-cli
rev: 'v0.44.0'
rev: 'v0.49.1'
hooks:
- id: markdownlint
args: ['-f']

- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
rev: v2.4.3
hooks:
- id: codespell
files: \.(py|sh|md|rst|yml|yaml)$
Expand Down
4 changes: 2 additions & 2 deletions src/config/settings/develop.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# ruff: noqa: F401, F405
# ruff: noqa: F401
"""Django `development` settings for config project.

Development target settings for the Django project inherited
Expand All @@ -8,7 +8,7 @@
https://docs.djangoproject.com/en/4.2/topics/settings/
"""

from config.settings.common.base import * # noqa: F403
from config.settings.common.base import *
from config.settings.common.base import INSTALLED_APPS, MIDDLEWARE
from config.settings.common.database import DATABASES
from config.settings.environment.django import (
Expand Down
4 changes: 2 additions & 2 deletions src/config/settings/production.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# ruff: noqa: F401, F405
# ruff: noqa: F401
"""Django `production` settings for config project.

For more information on this file, see
Expand All @@ -14,7 +14,7 @@
from dj_database_url import DEFAULT_ENV
from django.core.exceptions import ImproperlyConfigured

from config.settings.common.base import * # noqa: F403
from config.settings.common.base import *
from config.settings.common.database import DATABASES
from config.settings.common.security import (
CSRF_COOKIE_SECURE,
Expand Down
4 changes: 2 additions & 2 deletions src/config/settings/staging.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# ruff: noqa: F401, F405
# ruff: noqa: F401
"""Django `staging` settings for config project.

For more information on this file, see
Expand All @@ -8,7 +8,7 @@
https://docs.djangoproject.com/en/4.2/ref/settings/
"""

from config.settings.common.base import * # noqa: F403
from config.settings.common.base import *
from config.settings.common.database import DATABASES
from config.settings.environment.django import (
ALLOWED_HOSTS,
Expand Down
4 changes: 2 additions & 2 deletions src/config/settings/testing.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# ruff: noqa: F401, F405
# ruff: noqa: F401
"""Django `test` settings for config project.

Testing target settings for the Django project inherited
Expand All @@ -16,7 +16,7 @@

import os

from config.settings.common.base import * # noqa: F403
from config.settings.common.base import *
from config.settings.common.database import DATABASES
from config.settings.environment.django import (
ALLOWED_HOSTS,
Expand Down
1 change: 1 addition & 0 deletions src/manage.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#!/usr/bin/env python
# mypy: ignore-errors
"""Django's command-line utility for administrative tasks."""

import os
import sys

Expand Down
1 change: 0 additions & 1 deletion src/orders/apps.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ def ready(self) -> None:
# Implicitly connect signal handlers decorated with @receiver.
from orders import signals # noqa: F401

...
1 change: 0 additions & 1 deletion tests/accounts/test_account_serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ class TCustomer(TypedDict):
class TUserAndCustomer(TUser, TCustomer):
"""Type union structure for a single user and customer data."""

...


@pytest.fixture
Expand Down
1 change: 0 additions & 1 deletion tests/accounts/test_account_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ class TCustomer(TypedDict):
class TUserAndCustomer(TUser, TCustomer):
"""Type union structure for a single user and customer data."""

...


@pytest.fixture
Expand Down
1 change: 0 additions & 1 deletion tests/config/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

import pytest
from django.core.exceptions import ImproperlyConfigured

from src.config.constants import SETTINGS_MODULE
from src.config.enums import Environment
from src.config.utils import get_target_settings
Expand Down
1 change: 0 additions & 1 deletion tests/orders/test_order_services.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
class IncompatibleClient:
"""Stub to represent an unexpected client for the Order SMS service."""

...


@pytest.mark.unit
Expand Down
Loading