diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 63add8bf..7c9e6eca 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,7 +9,7 @@ repos: - id: check-yaml - repo: https://github.com/psf/black - rev: 21.12b0 + rev: 22.1.0 hooks: - id: black diff --git a/requirements.txt b/requirements.txt index 763fe10e..c878932c 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,7 +4,7 @@ binaryornot==0.4.4 # Code quality # ------------------------------------------------------------------------------ -black==21.12b0 +black==22.1.0 isort==5.10.1 flake8==4.0.1 flake8-isort==4.1.1 diff --git a/tests/test_cookiecutter_generation.py b/tests/test_cookiecutter_generation.py index 49a0d2cc..ada1809f 100755 --- a/tests/test_cookiecutter_generation.py +++ b/tests/test_cookiecutter_generation.py @@ -179,7 +179,12 @@ def test_black_passes(cookies, context_override): try: sh.black( - "--check", "--diff", "--exclude", "migrations", _cwd=str(result.project) + "--check", + "--diff", + "--exclude", + "migrations", + ".", + _cwd=str(result.project), ) except sh.ErrorReturnCode as e: pytest.fail(e.stdout.decode()) diff --git a/{{cookiecutter.project_slug}}/.pre-commit-config.yaml b/{{cookiecutter.project_slug}}/.pre-commit-config.yaml index 301f8b74..5ea57c56 100644 --- a/{{cookiecutter.project_slug}}/.pre-commit-config.yaml +++ b/{{cookiecutter.project_slug}}/.pre-commit-config.yaml @@ -10,7 +10,7 @@ repos: - id: check-yaml - repo: https://github.com/psf/black - rev: 21.12b0 + rev: 22.1.0 hooks: - id: black diff --git a/{{cookiecutter.project_slug}}/config/settings/base.py b/{{cookiecutter.project_slug}}/config/settings/base.py index 1598373d..bbaff230 100644 --- a/{{cookiecutter.project_slug}}/config/settings/base.py +++ b/{{cookiecutter.project_slug}}/config/settings/base.py @@ -44,7 +44,10 @@ LOCALE_PATHS = [str(ROOT_DIR / "locale")] DATABASES = {"default": env.db("DATABASE_URL")} {%- else %} DATABASES = { - "default": env.db("DATABASE_URL", default="postgres://{% if cookiecutter.windows == 'y' %}localhost{% endif %}/{{cookiecutter.project_slug}}"), + "default": env.db( + "DATABASE_URL", + default="postgres://{% if cookiecutter.windows == 'y' %}localhost{% endif %}/{{cookiecutter.project_slug}}", + ), } {%- endif %} DATABASES["default"]["ATOMIC_REQUESTS"] = True diff --git a/{{cookiecutter.project_slug}}/requirements/local.txt b/{{cookiecutter.project_slug}}/requirements/local.txt index 4ed5f609..deb7e0bd 100644 --- a/{{cookiecutter.project_slug}}/requirements/local.txt +++ b/{{cookiecutter.project_slug}}/requirements/local.txt @@ -31,7 +31,7 @@ sphinx-autobuild==2021.3.14 # https://github.com/GaretJax/sphinx-autobuild flake8==4.0.1 # https://github.com/PyCQA/flake8 flake8-isort==4.1.1 # https://github.com/gforcada/flake8-isort coverage==6.3.1 # https://github.com/nedbat/coveragepy -black==21.12b0 # https://github.com/psf/black +black==22.1.0 # https://github.com/psf/black pylint-django==2.5.0 # https://github.com/PyCQA/pylint-django {%- if cookiecutter.use_celery == 'y' %} pylint-celery==0.3 # https://github.com/PyCQA/pylint-celery