diff --git a/.github/contributors.json b/.github/contributors.json index eebde5e91..40a7d26d6 100644 --- a/.github/contributors.json +++ b/.github/contributors.json @@ -1553,5 +1553,15 @@ "name": "David Păcioianu", "github_login": "DavidPacioianu", "twitter_username": "" + }, + { + "name": "farwill", + "github_login": "farwill", + "twitter_username": "" + }, + { + "name": "quroom", + "github_login": "quroom", + "twitter_username": "" } ] \ No newline at end of file diff --git a/.github/workflows/update-contributors.yml b/.github/workflows/update-contributors.yml index e814039db..c77bc5e8f 100644 --- a/.github/workflows/update-contributors.yml +++ b/.github/workflows/update-contributors.yml @@ -33,7 +33,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Commit changes - uses: stefanzweifel/git-auto-commit-action@v5.0.0 + uses: stefanzweifel/git-auto-commit-action@v5.0.1 with: commit_message: Update Contributors file_pattern: CONTRIBUTORS.md .github/contributors.json diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 61924dfad..97cad833b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: exclude: hooks/ - repo: https://github.com/psf/black - rev: 24.3.0 + rev: 24.4.0 hooks: - id: black diff --git a/CHANGELOG.md b/CHANGELOG.md index 8a542d9f1..781dfc848 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,24 @@ All enhancements and patches to Cookiecutter Django will be documented in this f +## 2024.04.10 + + +### Updated + +- Bump python from 3.12.2 to 3.12.3 in docs ([#4979](https://github.com/cookiecutter/cookiecutter-django/pull/4979)) + +- Bump python from 3.12.2 to 3.12.3 in local ([#4981](https://github.com/cookiecutter/cookiecutter-django/pull/4981)) + +- Bump python from 3.12.2 to 3.12.3 in production ([#4980](https://github.com/cookiecutter/cookiecutter-django/pull/4980)) + +## 2024.04.09 + + +### Documentation + +- Fix start command for docs ([#4978](https://github.com/cookiecutter/cookiecutter-django/pull/4978)) + ## 2024.04.07 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 753e827aa..8d2025e37 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -66,13 +66,13 @@ $ source venv/bin/activate These tests are slower and can be run with or without Docker: -- Without Docker: `scripts/test_bare.sh` (for bare metal) -- With Docker: `scripts/test_docker.sh` +- Without Docker: `tests/test_bare.sh` (for bare metal) +- With Docker: `tests/test_docker.sh` All arguments to these scripts will be passed to the `cookiecutter` CLI, letting you set options, for example: ```bash -$ scripts/test_bare.sh use_celery=y +$ tests/test_bare.sh use_celery=y ``` ## Submitting a pull request diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index b30e27e7b..bf4896dc8 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -817,6 +817,13 @@ Listed in alphabetical order. fabaff + + farwill + + farwill + + + Fateme Fouladkar @@ -1748,6 +1755,13 @@ Listed in alphabetical order. + + quroom + + quroom + + + Raony Guimarães Corrêa diff --git a/README.md b/README.md index 995303b42..c38eec277 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/ambv/black) [![Updates](https://pyup.io/repos/github/cookiecutter/cookiecutter-django/shield.svg)](https://pyup.io/repos/github/cookiecutter/cookiecutter-django/) -[![Join our Discord](https://img.shields.io/badge/Discord-cookiecutter-5865F2?style=flat&logo=discord&logoColor=white)](https://discord.gg/uFXweDQc5a) +[![Join our Discord](https://img.shields.io/badge/Discord-cookiecutter-5865F2?style=flat&logo=discord&logoColor=white)](https://discord.gg/rAWFUP47d2) [![Code Helpers Badge](https://www.codetriage.com/cookiecutter/cookiecutter-django/badges/users.svg)](https://www.codetriage.com/cookiecutter/cookiecutter-django) Powered by [Cookiecutter](https://github.com/cookiecutter/cookiecutter), Cookiecutter Django is a framework for jumpstarting diff --git a/docs/document.rst b/docs/document.rst index 26f5d56a1..f93f2b60e 100644 --- a/docs/document.rst +++ b/docs/document.rst @@ -11,7 +11,7 @@ After you have set up to `develop locally`_, run the following command from the If you set up your project to `develop locally with docker`_, run the following command: :: - $ docker compose -f local.yml up docs + $ docker compose -f docs.yml up Navigate to port 9000 on your host to see the documentation. This will be opened automatically at `localhost`_ for local, non-docker development. diff --git a/requirements.txt b/requirements.txt index 0a43ec95f..5da67bc34 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,7 +4,7 @@ binaryornot==0.4.4 # Code quality # ------------------------------------------------------------------------------ -ruff==0.3.5 +ruff==0.3.7 django-upgrade==1.16.0 djlint==1.34.1 pre-commit==3.7.0 diff --git a/setup.py b/setup.py index de4fd53b4..9cd064a0f 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ except ImportError: from distutils.core import setup # We use calendar versioning -version = "2024.04.07" +version = "2024.04.10" with open("README.md") as readme_file: long_description = readme_file.read() diff --git a/{{cookiecutter.project_slug}}/.pre-commit-config.yaml b/{{cookiecutter.project_slug}}/.pre-commit-config.yaml index b1725ebc4..df0e358c7 100644 --- a/{{cookiecutter.project_slug}}/.pre-commit-config.yaml +++ b/{{cookiecutter.project_slug}}/.pre-commit-config.yaml @@ -35,7 +35,7 @@ repos: # Run the Ruff linter. - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.3.5 + rev: v0.3.7 hooks: # Linter - id: ruff diff --git a/{{cookiecutter.project_slug}}/compose/local/django/Dockerfile b/{{cookiecutter.project_slug}}/compose/local/django/Dockerfile index 0897ab95d..88ccb7491 100644 --- a/{{cookiecutter.project_slug}}/compose/local/django/Dockerfile +++ b/{{cookiecutter.project_slug}}/compose/local/django/Dockerfile @@ -1,5 +1,5 @@ # define an alias for the specific python version used in this file. -FROM docker.io/python:3.12.2-slim-bookworm as python +FROM docker.io/python:3.12.3-slim-bookworm as python # Python build stage FROM python as python-build-stage diff --git a/{{cookiecutter.project_slug}}/compose/local/docs/Dockerfile b/{{cookiecutter.project_slug}}/compose/local/docs/Dockerfile index 9251effba..35565042d 100644 --- a/{{cookiecutter.project_slug}}/compose/local/docs/Dockerfile +++ b/{{cookiecutter.project_slug}}/compose/local/docs/Dockerfile @@ -1,5 +1,5 @@ # define an alias for the specific python version used in this file. -FROM docker.io/python:3.12.2-slim-bookworm as python +FROM docker.io/python:3.12.3-slim-bookworm as python # Python build stage diff --git a/{{cookiecutter.project_slug}}/compose/production/django/Dockerfile b/{{cookiecutter.project_slug}}/compose/production/django/Dockerfile index 19b2cb0aa..671eb4635 100644 --- a/{{cookiecutter.project_slug}}/compose/production/django/Dockerfile +++ b/{{cookiecutter.project_slug}}/compose/production/django/Dockerfile @@ -25,7 +25,7 @@ RUN npm run build {%- endif %} # define an alias for the specific python version used in this file. -FROM docker.io/python:3.12.2-slim-bookworm as python +FROM docker.io/python:3.12.3-slim-bookworm as python # Python build stage FROM python as python-build-stage diff --git a/{{cookiecutter.project_slug}}/config/settings/base.py b/{{cookiecutter.project_slug}}/config/settings/base.py index b7eb7e80f..f1039b748 100644 --- a/{{cookiecutter.project_slug}}/config/settings/base.py +++ b/{{cookiecutter.project_slug}}/config/settings/base.py @@ -372,6 +372,7 @@ SPECTACULAR_SETTINGS = { "DESCRIPTION": "Documentation of API endpoints of {{ cookiecutter.project_name }}", "VERSION": "1.0.0", "SERVE_PERMISSIONS": ["rest_framework.permissions.IsAdminUser"], + "SCHEMA_PATH_PREFIX": "/api/", } {%- endif %} {%- if cookiecutter.frontend_pipeline == 'Webpack' %} diff --git a/{{cookiecutter.project_slug}}/config/settings/local.py b/{{cookiecutter.project_slug}}/config/settings/local.py index 3d429afb9..bd47bf3d1 100644 --- a/{{cookiecutter.project_slug}}/config/settings/local.py +++ b/{{cookiecutter.project_slug}}/config/settings/local.py @@ -86,6 +86,15 @@ if env("USE_DOCKER") == "yes": # The node container isn't started (yet?) pass {%- endif %} + {%- if cookiecutter.windows == 'y' %} + # RunServerPlus + # ------------------------------------------------------------------------------ + # This is a custom setting for RunServerPlus to fix reloader issue in Windows docker environment + # Werkzeug reloader type [auto, watchdog, or stat] + RUNSERVERPLUS_POLLER_RELOADER_TYPE = 'stat' + # If you have CPU and IO load issues, you can increase this poller interval e.g) 5 + RUNSERVERPLUS_POLLER_RELOADER_INTERVAL = 1 + {%- endif %} {%- endif %} # django-extensions diff --git a/{{cookiecutter.project_slug}}/config/urls.py b/{{cookiecutter.project_slug}}/config/urls.py index 5d9301b67..aca4352e6 100644 --- a/{{cookiecutter.project_slug}}/config/urls.py +++ b/{{cookiecutter.project_slug}}/config/urls.py @@ -43,7 +43,7 @@ urlpatterns += [ # API base url path("api/", include("config.api_router")), # DRF auth token - path("auth-token/", obtain_auth_token), + path("api/auth-token/", obtain_auth_token), path("api/schema/", SpectacularAPIView.as_view(), name="api-schema"), path( "api/docs/", diff --git a/{{cookiecutter.project_slug}}/requirements/local.txt b/{{cookiecutter.project_slug}}/requirements/local.txt index d290b0213..f0918bf86 100644 --- a/{{cookiecutter.project_slug}}/requirements/local.txt +++ b/{{cookiecutter.project_slug}}/requirements/local.txt @@ -24,11 +24,11 @@ djangorestframework-stubs[compatible-mypy]==3.14.5 # https://github.com/typeddj # Documentation # ------------------------------------------------------------------------------ sphinx==7.2.6 # https://github.com/sphinx-doc/sphinx -sphinx-autobuild==2024.2.4 # https://github.com/GaretJax/sphinx-autobuild +sphinx-autobuild==2024.4.13 # https://github.com/GaretJax/sphinx-autobuild # Code quality # ------------------------------------------------------------------------------ -ruff==0.3.5 # https://github.com/astral-sh/ruff +ruff==0.3.7 # https://github.com/astral-sh/ruff coverage==7.4.4 # https://github.com/nedbat/coveragepy djlint==1.34.1 # https://github.com/Riverside-Healthcare/djLint pre-commit==3.7.0 # https://github.com/pre-commit/pre-commit diff --git a/{{cookiecutter.project_slug}}/requirements/production.txt b/{{cookiecutter.project_slug}}/requirements/production.txt index f16975053..a88351ffe 100644 --- a/{{cookiecutter.project_slug}}/requirements/production.txt +++ b/{{cookiecutter.project_slug}}/requirements/production.txt @@ -8,7 +8,7 @@ psycopg[c]==3.1.18 # https://github.com/psycopg/psycopg Collectfast==2.2.0 # https://github.com/antonagestam/collectfast {%- endif %} {%- if cookiecutter.use_sentry == "y" %} -sentry-sdk==1.44.1 # https://github.com/getsentry/sentry-python +sentry-sdk==1.45.0 # https://github.com/getsentry/sentry-python {%- endif %} {%- if cookiecutter.use_docker == "n" and cookiecutter.windows == "y" %} hiredis==2.3.2 # https://github.com/redis/hiredis-py diff --git a/{{cookiecutter.project_slug}}/runtime.txt b/{{cookiecutter.project_slug}}/runtime.txt index 6e797d468..4ddc7cd66 100644 --- a/{{cookiecutter.project_slug}}/runtime.txt +++ b/{{cookiecutter.project_slug}}/runtime.txt @@ -1 +1 @@ -python-3.12.2 +python-3.12.3