mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-08-14 00:44:53 +03:00
Merge branch 'master' into fix/cffi-build-raspberry-pi
This commit is contained in:
commit
356ac91cb9
9
.github/FUNDING.yml
vendored
9
.github/FUNDING.yml
vendored
|
@ -2,11 +2,4 @@
|
|||
|
||||
github: [pydanny, browniebroke]
|
||||
patreon: feldroy
|
||||
open_collective: # Replace with a single Open Collective username
|
||||
ko_fi: # Replace with a single Ko-fi username
|
||||
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
|
||||
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
|
||||
liberapay: # Replace with a single Liberapay username
|
||||
issuehunt: # Replace with a single IssueHunt username
|
||||
otechie: # Replace with a single Otechie username
|
||||
custom: ["https://www.patreon.com/browniebroke"]
|
||||
open_collective: cookiecutter-django
|
||||
|
|
16
.github/contributors.json
vendored
16
.github/contributors.json
vendored
|
@ -53,6 +53,12 @@
|
|||
"twitter_username": "sfdye",
|
||||
"is_core": true
|
||||
},
|
||||
{
|
||||
"name": "Jelmer Draaijer",
|
||||
"github_login": "foarsitter",
|
||||
"twitter_username": "",
|
||||
"is_core": true
|
||||
},
|
||||
{
|
||||
"name": "18",
|
||||
"github_login": "dezoito",
|
||||
|
@ -553,11 +559,6 @@
|
|||
"github_login": "jvanbrug",
|
||||
"twitter_username": ""
|
||||
},
|
||||
{
|
||||
"name": "Jelmer Draaijer",
|
||||
"github_login": "foarsitter",
|
||||
"twitter_username": ""
|
||||
},
|
||||
{
|
||||
"name": "Jerome Caisip",
|
||||
"github_login": "jeromecaisip",
|
||||
|
@ -1392,5 +1393,10 @@
|
|||
"name": "Birtibu",
|
||||
"github_login": "Birtibu",
|
||||
"twitter_username": ""
|
||||
},
|
||||
{
|
||||
"name": "Matheus Jardim Bernardes",
|
||||
"github_login": "matheusjardimb",
|
||||
"twitter_username": ""
|
||||
}
|
||||
]
|
|
@ -23,7 +23,7 @@ repos:
|
|||
args: ["--tab-width", "2"]
|
||||
|
||||
- repo: https://github.com/asottile/pyupgrade
|
||||
rev: v3.4.0
|
||||
rev: v3.7.0
|
||||
hooks:
|
||||
- id: pyupgrade
|
||||
args: [--py311-plus]
|
||||
|
|
228
CHANGELOG.md
228
CHANGELOG.md
|
@ -3,6 +3,234 @@ All enhancements and patches to Cookiecutter Django will be documented in this f
|
|||
|
||||
<!-- GENERATOR_PLACEHOLDER -->
|
||||
|
||||
## 2023.06.26
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update pytest to 7.4.0 ([#4412](https://github.com/cookiecutter/cookiecutter-django/pull/4412))
|
||||
|
||||
- Update redis to 4.6.0 ([#4415](https://github.com/cookiecutter/cookiecutter-django/pull/4415))
|
||||
|
||||
- Update mypy to 1.4.1 ([#4416](https://github.com/cookiecutter/cookiecutter-django/pull/4416))
|
||||
|
||||
## 2023.06.22
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update pygithub to 1.59.0 ([#4410](https://github.com/cookiecutter/cookiecutter-django/pull/4410))
|
||||
|
||||
- Update drf-spectacular to 0.26.3 ([#4411](https://github.com/cookiecutter/cookiecutter-django/pull/4411))
|
||||
|
||||
- Update sentry-sdk to 1.26.0 ([#4409](https://github.com/cookiecutter/cookiecutter-django/pull/4409))
|
||||
|
||||
## 2023.06.21
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Upgrade traefik to 2.10.3 ([#4408](https://github.com/cookiecutter/cookiecutter-django/pull/4408))
|
||||
|
||||
## 2023.06.19
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Auto-update pre-commit hooks ([#4405](https://github.com/cookiecutter/cookiecutter-django/pull/4405))
|
||||
|
||||
- Update celery to 5.3.1 ([#4404](https://github.com/cookiecutter/cookiecutter-django/pull/4404))
|
||||
|
||||
## 2023.06.18
|
||||
|
||||
|
||||
### Changed
|
||||
|
||||
- Fix missing celery env variable when running compilemessages ([#4403](https://github.com/cookiecutter/cookiecutter-django/pull/4403))
|
||||
|
||||
### Updated
|
||||
|
||||
- Update flower to 2.0.0 ([#4402](https://github.com/cookiecutter/cookiecutter-django/pull/4402))
|
||||
|
||||
## 2023.06.17
|
||||
|
||||
|
||||
## 2023.06.16
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update whitenoise to 6.5.0 ([#4400](https://github.com/cookiecutter/cookiecutter-django/pull/4400))
|
||||
|
||||
- Update django-redis to 5.3.0 ([#4399](https://github.com/cookiecutter/cookiecutter-django/pull/4399))
|
||||
|
||||
- Auto-update pre-commit hooks ([#4395](https://github.com/cookiecutter/cookiecutter-django/pull/4395))
|
||||
|
||||
## 2023.06.14
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update django-cors-headers to 4.1.0 ([#4391](https://github.com/cookiecutter/cookiecutter-django/pull/4391))
|
||||
|
||||
- Update django-upgrade to 1.14.0 ([#4394](https://github.com/cookiecutter/cookiecutter-django/pull/4394))
|
||||
|
||||
- Update django-webpack-loader to 2.0.1 ([#4392](https://github.com/cookiecutter/cookiecutter-django/pull/4392))
|
||||
|
||||
- Update pre-commit to 3.3.3 ([#4390](https://github.com/cookiecutter/cookiecutter-django/pull/4390))
|
||||
|
||||
## 2023.06.11
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update pytest to 7.3.2 ([#4384](https://github.com/cookiecutter/cookiecutter-django/pull/4384))
|
||||
|
||||
- Auto-update pre-commit hooks ([#4385](https://github.com/cookiecutter/cookiecutter-django/pull/4385))
|
||||
|
||||
## 2023.06.09
|
||||
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix missing `compilemessages` step before deploying to prod ([#4363](https://github.com/cookiecutter/cookiecutter-django/pull/4363))
|
||||
|
||||
## 2023.06.08
|
||||
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix failure in user view test caused by translations ([#4374](https://github.com/cookiecutter/cookiecutter-django/pull/4374))
|
||||
|
||||
### Updated
|
||||
|
||||
- Update to Python 3.11.4 in production Docker compose ([#4378](https://github.com/cookiecutter/cookiecutter-django/pull/4378))
|
||||
|
||||
- Update to Python 3.11.4 in docs Docker compose ([#4379](https://github.com/cookiecutter/cookiecutter-django/pull/4379))
|
||||
|
||||
- Update to Python 3.11.4 in local Docker compose ([#4380](https://github.com/cookiecutter/cookiecutter-django/pull/4380))
|
||||
|
||||
- Update celery to 5.3.0 ([#4369](https://github.com/cookiecutter/cookiecutter-django/pull/4369))
|
||||
|
||||
- Update werkzeug to 2.3.5 ([#4377](https://github.com/cookiecutter/cookiecutter-django/pull/4377))
|
||||
|
||||
## 2023.06.07
|
||||
|
||||
|
||||
### Changed
|
||||
|
||||
- Replace `runserver` with `runserver_plus` ([#4373](https://github.com/cookiecutter/cookiecutter-django/pull/4373))
|
||||
|
||||
- Add translations for Brazilian Portuguese ([#4367](https://github.com/cookiecutter/cookiecutter-django/pull/4367))
|
||||
|
||||
### Updated
|
||||
|
||||
- Update sentry-sdk to 1.25.1 ([#4376](https://github.com/cookiecutter/cookiecutter-django/pull/4376))
|
||||
|
||||
- Update django-extensions to 3.2.3 ([#4372](https://github.com/cookiecutter/cookiecutter-django/pull/4372))
|
||||
|
||||
- Update djangorestframework-stubs to 3.14.1 ([#4366](https://github.com/cookiecutter/cookiecutter-django/pull/4366))
|
||||
|
||||
- Update django-stubs to 4.2.1 ([#4365](https://github.com/cookiecutter/cookiecutter-django/pull/4365))
|
||||
|
||||
- Update mypy to 1.3.0 ([#4327](https://github.com/cookiecutter/cookiecutter-django/pull/4327))
|
||||
|
||||
## 2023.06.02
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update sentry-sdk to 1.25.0 ([#4364](https://github.com/cookiecutter/cookiecutter-django/pull/4364))
|
||||
|
||||
## 2023.05.30
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update hiredis to 2.2.3 ([#4360](https://github.com/cookiecutter/cookiecutter-django/pull/4360))
|
||||
|
||||
- Update django-debug-toolbar to 4.1.0 ([#4359](https://github.com/cookiecutter/cookiecutter-django/pull/4359))
|
||||
|
||||
- Update redis to 4.5.5 ([#4358](https://github.com/cookiecutter/cookiecutter-django/pull/4358))
|
||||
|
||||
- Update django-anymail to 10.0 ([#4357](https://github.com/cookiecutter/cookiecutter-django/pull/4357))
|
||||
|
||||
- Update coverage to 7.2.7 ([#4356](https://github.com/cookiecutter/cookiecutter-django/pull/4356))
|
||||
|
||||
## 2023.05.28
|
||||
|
||||
|
||||
## 2023.05.24
|
||||
|
||||
|
||||
### Fixed
|
||||
|
||||
- Prevent Celery restarts on media file changes ([#4352](https://github.com/cookiecutter/cookiecutter-django/pull/4352))
|
||||
|
||||
### Updated
|
||||
|
||||
- Update coverage to 7.2.6 ([#4351](https://github.com/cookiecutter/cookiecutter-django/pull/4351))
|
||||
|
||||
## 2023.05.23
|
||||
|
||||
|
||||
### Changed
|
||||
|
||||
- Fix compatibility webpack-bundle-tracker>=2.0.0 js library required after upgrade django-webpack-loader>=2.0.0 ([#4350](https://github.com/cookiecutter/cookiecutter-django/pull/4350))
|
||||
|
||||
### Updated
|
||||
|
||||
- Update sphinx-rtd-theme to 1.2.1 ([#4348](https://github.com/cookiecutter/cookiecutter-django/pull/4348))
|
||||
|
||||
- Update sentry-sdk to 1.24.0 ([#4349](https://github.com/cookiecutter/cookiecutter-django/pull/4349))
|
||||
|
||||
- Bump webpack-bundle-tracker from 1.8.1 to 2.0.0 in /{{cookiecutter.project_slug}} ([#4347](https://github.com/cookiecutter/cookiecutter-django/pull/4347))
|
||||
|
||||
- Update django-webpack-loader to 2.0.0 ([#4345](https://github.com/cookiecutter/cookiecutter-django/pull/4345))
|
||||
|
||||
- Update pytest-xdist to 3.3.1 ([#4344](https://github.com/cookiecutter/cookiecutter-django/pull/4344))
|
||||
|
||||
- Update requests to 2.31.0 ([#4346](https://github.com/cookiecutter/cookiecutter-django/pull/4346))
|
||||
|
||||
## 2023.05.18
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update pre-commit to 3.3.2 ([#4342](https://github.com/cookiecutter/cookiecutter-django/pull/4342))
|
||||
|
||||
## 2023.05.17
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update sentry-sdk to 1.23.1 ([#4341](https://github.com/cookiecutter/cookiecutter-django/pull/4341))
|
||||
|
||||
## 2023.05.15
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update django-cors-headers to 4.0.0 ([#4329](https://github.com/cookiecutter/cookiecutter-django/pull/4329))
|
||||
|
||||
- Update sentry-sdk to 1.23.0 ([#4337](https://github.com/cookiecutter/cookiecutter-django/pull/4337))
|
||||
|
||||
## 2023.05.09
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Update werkzeug to 2.3.4 ([#4325](https://github.com/cookiecutter/cookiecutter-django/pull/4325))
|
||||
|
||||
## 2023.05.08
|
||||
|
||||
|
||||
### Updated
|
||||
|
||||
- Auto-update pre-commit hooks ([#4320](https://github.com/cookiecutter/cookiecutter-django/pull/4320))
|
||||
|
||||
- Update sentry-sdk to 1.22.2 ([#4321](https://github.com/cookiecutter/cookiecutter-django/pull/4321))
|
||||
|
||||
## 2023.05.04
|
||||
|
||||
|
||||
|
|
|
@ -74,6 +74,13 @@ accept and merge pull requests.
|
|||
</td>
|
||||
<td>sfdye</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Jelmer Draaijer</td>
|
||||
<td>
|
||||
<a href="https://github.com/foarsitter">foarsitter</a>
|
||||
</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
_Audrey is also the creator of Cookiecutter. Audrey and Daniel are on
|
||||
|
@ -1006,13 +1013,6 @@ Listed in alphabetical order.
|
|||
</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Jelmer Draaijer</td>
|
||||
<td>
|
||||
<a href="https://github.com/foarsitter">foarsitter</a>
|
||||
</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Jens Nilsson</td>
|
||||
<td>
|
||||
|
@ -1314,6 +1314,13 @@ Listed in alphabetical order.
|
|||
</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Matheus Jardim Bernardes</td>
|
||||
<td>
|
||||
<a href="https://github.com/matheusjardimb">matheusjardimb</a>
|
||||
</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Mathijs Hoogland</td>
|
||||
<td>
|
||||
|
|
|
@ -56,10 +56,11 @@ _These features can be enabled during initial project setup._
|
|||
|
||||
## Support this Project!
|
||||
|
||||
This project is run by volunteers. Please support them in their efforts to maintain and improve Cookiecutter Django:
|
||||
This project is an open source project run by volunteers. You can sponsor us via [OpenCollective](https://opencollective.com/cookiecutter-django) or individually via GitHub Sponsors:
|
||||
|
||||
- Daniel Roy Greenfeld, Project Lead ([GitHub](https://github.com/pydanny), [Patreon](https://www.patreon.com/danielroygreenfeld)): expertise in Django and AWS ELB.
|
||||
- Fabio C. Barrionuevo, Core Developer ([GitHub](https://github.com/luzfcb)): expertise in Python/Django, hands-on DevOps and frontend experience.
|
||||
- Bruno Alla, Core Developer ([GitHub](https://github.com/browniebroke)): expertise in Python/Django and DevOps.
|
||||
- Nikita Shupeyko, Core Developer ([GitHub](https://github.com/webyneter)): expertise in Python/Django, hands-on DevOps and frontend experience.
|
||||
|
||||
Projects that provide financial support to the maintainers:
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
sphinx==6.2.1
|
||||
sphinx-rtd-theme==1.2.0
|
||||
myst-parser==1.0.0
|
||||
sphinx-rtd-theme==1.2.2
|
||||
myst-parser==2.0.0
|
||||
|
|
|
@ -96,10 +96,6 @@ def remove_heroku_files():
|
|||
# don't remove the file if we are using travisci but not using heroku
|
||||
continue
|
||||
os.remove(file_name)
|
||||
remove_heroku_build_hooks()
|
||||
|
||||
|
||||
def remove_heroku_build_hooks():
|
||||
shutil.rmtree("bin")
|
||||
|
||||
|
||||
|
@ -194,7 +190,9 @@ def handle_js_runner(choice, use_docker, use_async):
|
|||
"gulp-uglify-es",
|
||||
]
|
||||
if not use_docker:
|
||||
dev_django_cmd = "uvicorn config.asgi:application --reload" if use_async else "python manage.py runserver"
|
||||
dev_django_cmd = (
|
||||
"uvicorn config.asgi:application --reload" if use_async else "python manage.py runserver_plus"
|
||||
)
|
||||
scripts.update(
|
||||
{
|
||||
"dev": "concurrently npm:dev:*",
|
||||
|
@ -442,8 +440,6 @@ def main():
|
|||
|
||||
if "{{ cookiecutter.use_heroku }}".lower() == "n":
|
||||
remove_heroku_files()
|
||||
elif "{{ cookiecutter.frontend_pipeline }}" != "Django Compressor":
|
||||
remove_heroku_build_hooks()
|
||||
|
||||
if "{{ cookiecutter.use_docker }}".lower() == "n" and "{{ cookiecutter.use_heroku }}".lower() == "n":
|
||||
if "{{ cookiecutter.keep_local_envs_in_vcs }}".lower() == "y":
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
cookiecutter==2.1.1
|
||||
sh==2.0.3; sys_platform != "win32"
|
||||
sh==2.0.4; sys_platform != "win32"
|
||||
binaryornot==0.4.4
|
||||
|
||||
# Code quality
|
||||
|
@ -7,21 +7,21 @@ binaryornot==0.4.4
|
|||
black==23.3.0
|
||||
isort==5.12.0
|
||||
flake8==6.0.0
|
||||
django-upgrade==1.13.0
|
||||
pre-commit==3.3.1
|
||||
django-upgrade==1.14.0
|
||||
pre-commit==3.3.3
|
||||
|
||||
# Testing
|
||||
# ------------------------------------------------------------------------------
|
||||
tox==4.5.1
|
||||
pytest==7.3.1
|
||||
pytest-xdist==3.2.1
|
||||
tox==4.6.3
|
||||
pytest==7.4.0
|
||||
pytest-xdist==3.3.1
|
||||
pytest-cookies==0.7.0
|
||||
pytest-instafail==0.5.0
|
||||
pyyaml==6.0
|
||||
|
||||
# Scripting
|
||||
# ------------------------------------------------------------------------------
|
||||
PyGithub==1.58.1
|
||||
PyGithub==1.59.0
|
||||
gitpython==3.1.31
|
||||
jinja2==3.1.2
|
||||
requests==2.30.0
|
||||
requests==2.31.0
|
||||
|
|
2
setup.py
2
setup.py
|
@ -5,7 +5,7 @@ except ImportError:
|
|||
from distutils.core import setup
|
||||
|
||||
# We use calendar versioning
|
||||
version = "2023.05.04"
|
||||
version = "2023.06.26"
|
||||
|
||||
with open("README.rst") as readme_file:
|
||||
long_description = readme_file.read()
|
||||
|
|
|
@ -0,0 +1,33 @@
|
|||
<component name="ProjectRunConfigurationManager">
|
||||
<configuration default="false" name="runserver_plus" type="Python.DjangoServer" factoryName="Django server" singleton="true">
|
||||
<module name="{{ cookiecutter.project_slug }}" />
|
||||
<option name="INTERPRETER_OPTIONS" value="" />
|
||||
<option name="PARENT_ENVS" value="true" />
|
||||
<envs>
|
||||
<env name="PYTHONUNBUFFERED" value="1" />
|
||||
<env name="DJANGO_SETTINGS_MODULE" value="config.settings.local" />
|
||||
</envs>
|
||||
<option name="SDK_HOME" value="" />
|
||||
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
|
||||
<option name="IS_MODULE_SDK" value="true" />
|
||||
<option name="ADD_CONTENT_ROOTS" value="true" />
|
||||
<option name="ADD_SOURCE_ROOTS" value="true" />
|
||||
<PathMappingSettings>
|
||||
<option name="pathMappings">
|
||||
<list>
|
||||
<mapping local-root="$PROJECT_DIR$" remote-root="/app" />
|
||||
</list>
|
||||
</option>
|
||||
</PathMappingSettings>
|
||||
<option name="launchJavascriptDebuger" value="false" />
|
||||
<option name="port" value="8000" />
|
||||
<option name="host" value="0.0.0.0" />
|
||||
<option name="additionalOptions" value="" />
|
||||
<option name="browserUrl" value="" />
|
||||
<option name="runTestServer" value="false" />
|
||||
<option name="runNoReload" value="false" />
|
||||
<option name="useCustomRunCommand" value="true" />
|
||||
<option name="customRunCommand" value="runserver_plus" />
|
||||
<method />
|
||||
</configuration>
|
||||
</component>
|
|
@ -25,13 +25,13 @@ repos:
|
|||
exclude: '{{cookiecutter.project_slug}}/templates/'
|
||||
|
||||
- repo: https://github.com/adamchainz/django-upgrade
|
||||
rev: "1.13.0"
|
||||
rev: '1.14.0'
|
||||
hooks:
|
||||
- id: django-upgrade
|
||||
args: ["--target-version", "4.1"]
|
||||
args: ['--target-version', '4.1']
|
||||
|
||||
- repo: https://github.com/asottile/pyupgrade
|
||||
rev: v3.4.0
|
||||
rev: v3.7.0
|
||||
hooks:
|
||||
- id: pyupgrade
|
||||
args: [--py311-plus]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#!/usr/bin/env bash
|
||||
{%- if cookiecutter.frontend_pipeline == "Django Compressor" %}
|
||||
|
||||
compress_enabled() {
|
||||
python << END
|
||||
|
@ -19,4 +20,7 @@ if compress_enabled
|
|||
then
|
||||
python manage.py compress
|
||||
fi
|
||||
{%- endif %}
|
||||
|
||||
python manage.py collectstatic --noinput
|
||||
python manage.py compilemessages -i site-packages
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# define an alias for the specific python version used in this file.
|
||||
FROM python:3.11.3-slim-bullseye as python
|
||||
FROM python:3.11.4-slim-bullseye as python
|
||||
|
||||
# Python build stage
|
||||
FROM python as python-build-stage
|
||||
|
|
|
@ -5,4 +5,4 @@ set -o nounset
|
|||
|
||||
|
||||
rm -f './celerybeat.pid'
|
||||
exec watchfiles celery.__main__.main --args '-A config.celery_app beat -l INFO'
|
||||
exec watchfiles --filter python celery.__main__.main --args '-A config.celery_app beat -l INFO'
|
||||
|
|
|
@ -3,6 +3,6 @@
|
|||
set -o errexit
|
||||
set -o nounset
|
||||
|
||||
exec watchfiles celery.__main__.main \
|
||||
exec watchfiles --filter python celery.__main__.main \
|
||||
--args \
|
||||
"-A config.celery_app -b \"${CELERY_BROKER_URL}\" flower --basic_auth=\"${CELERY_FLOWER_USER}:${CELERY_FLOWER_PASSWORD}\""
|
||||
|
|
|
@ -4,4 +4,4 @@ set -o errexit
|
|||
set -o nounset
|
||||
|
||||
|
||||
exec watchfiles celery.__main__.main --args '-A config.celery_app worker -l INFO'
|
||||
exec watchfiles --filter python celery.__main__.main --args '-A config.celery_app worker -l INFO'
|
||||
|
|
|
@ -9,5 +9,5 @@ python manage.py migrate
|
|||
{%- if cookiecutter.use_async == 'y' %}
|
||||
exec uvicorn config.asgi:application --host 0.0.0.0 --reload --reload-include '*.html'
|
||||
{%- else %}
|
||||
exec python manage.py runserver 0.0.0.0:8000
|
||||
exec python manage.py runserver_plus 0.0.0.0:8000
|
||||
{%- endif %}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# define an alias for the specific python version used in this file.
|
||||
FROM python:3.11.3-slim-bullseye as python
|
||||
FROM python:3.11.4-slim-bullseye as python
|
||||
|
||||
|
||||
# Python build stage
|
||||
|
|
|
@ -25,7 +25,7 @@ RUN npm run build
|
|||
|
||||
{%- endif %}
|
||||
# define an alias for the specific python version used in this file.
|
||||
FROM python:3.11.3-slim-bullseye as python
|
||||
FROM python:3.11.4-slim-bullseye as python
|
||||
|
||||
# Python build stage
|
||||
FROM python as python-build-stage
|
||||
|
@ -123,4 +123,11 @@ RUN chown django:django ${APP_HOME}
|
|||
|
||||
USER django
|
||||
|
||||
RUN DATABASE_URL="" \
|
||||
{%- if cookiecutter.use_celery == "y" %}
|
||||
CELERY_BROKER_URL="" \
|
||||
{%- endif %}
|
||||
DJANGO_SETTINGS_MODULE="config.settings.test" \
|
||||
python manage.py compilemessages
|
||||
|
||||
ENTRYPOINT ["/entrypoint"]
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
FROM traefik:2.10.1
|
||||
FROM traefik:2.10.3
|
||||
RUN mkdir -p /etc/traefik/acme \
|
||||
&& touch /etc/traefik/acme/acme.json \
|
||||
&& chmod 600 /etc/traefik/acme/acme.json
|
||||
|
|
|
@ -26,6 +26,12 @@ DEBUG = env.bool("DJANGO_DEBUG", False)
|
|||
TIME_ZONE = "{{ cookiecutter.timezone }}"
|
||||
# https://docs.djangoproject.com/en/dev/ref/settings/#language-code
|
||||
LANGUAGE_CODE = "en-us"
|
||||
# https://docs.djangoproject.com/en/dev/ref/settings/#languages
|
||||
# from django.utils.translation import gettext_lazy as _
|
||||
# LANGUAGES = [
|
||||
# ('en', _('English')),
|
||||
# ('pt-br', _('Português')),
|
||||
# ]
|
||||
# https://docs.djangoproject.com/en/dev/ref/settings/#site-id
|
||||
SITE_ID = 1
|
||||
# https://docs.djangoproject.com/en/dev/ref/settings/#use-i18n
|
||||
|
|
32
{{cookiecutter.project_slug}}/locale/README.md
Normal file
32
{{cookiecutter.project_slug}}/locale/README.md
Normal file
|
@ -0,0 +1,32 @@
|
|||
# Translations
|
||||
|
||||
Start by configuring the `LANGUAGES` settings in `base.py`, by uncommenting languages you are willing to support. Then, translations strings will be placed in this folder when running:
|
||||
|
||||
```bash
|
||||
{% if cookiecutter.use_docker == 'y' %}docker-compose -f local.yml run --rm django {% endif %}python manage.py makemessages -all --no-location
|
||||
```
|
||||
|
||||
This should generate `django.po` (stands for Portable Object) files under each locale `<locale name>/LC_MESSAGES/django.po`. Each translatable string in the codebase is collected with its `msgid` and need to be translated as `msgstr`, for example:
|
||||
|
||||
```po
|
||||
msgid "users"
|
||||
msgstr "utilisateurs"
|
||||
```
|
||||
|
||||
Once all translations are done, they need to be compiled into `.mo` files (stands for Machine Object), which are the actual binary files used by the application:
|
||||
|
||||
```bash
|
||||
{% if cookiecutter.use_docker == 'y' %}docker-compose -f local.yml run --rm django {% endif %}python manage.py compilemessages
|
||||
```
|
||||
|
||||
Note that the `.po` files are NOT used by the application directly, so if the `.mo` files are out of dates, the content won't appear as translated even if the `.po` files are up-to-date.
|
||||
|
||||
## Production
|
||||
|
||||
The production image runs `compilemessages` automatically at build time, so as long as your translated source files (PO) are up-to-date, you're good to go.
|
||||
|
||||
## Add a new language
|
||||
|
||||
1. Update the [`LANGUAGES` setting](https://docs.djangoproject.com/en/stable/ref/settings/#std-setting-LANGUAGES) to your project's base settings.
|
||||
2. Create the locale folder for the language next to this file, e.g. `fr_FR` for French. Make sure the case is correct.
|
||||
3. Run `makemessages` (as instructed above) to generate the PO files for the new language.
|
|
@ -1,6 +0,0 @@
|
|||
Translations
|
||||
============
|
||||
|
||||
Translations will be placed in this folder when running::
|
||||
|
||||
python manage.py makemessages
|
|
@ -0,0 +1,12 @@
|
|||
# Translations for the {{ cookiecutter.project_name }} project
|
||||
# Copyright (C) {% now 'utc', '%Y' %} {{ cookiecutter.author_name }}
|
||||
# {{ cookiecutter.author_name }} <{{ cookiecutter.email }}>, {% now 'utc', '%Y' %}.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: {{ cookiecutter.version }}\n"
|
||||
"Language: en-US\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
315
{{cookiecutter.project_slug}}/locale/pt_BR/LC_MESSAGES/django.po
Normal file
315
{{cookiecutter.project_slug}}/locale/pt_BR/LC_MESSAGES/django.po
Normal file
|
@ -0,0 +1,315 @@
|
|||
# Translations for the {{ cookiecutter.project_name }} project
|
||||
# Copyright (C) {% now 'utc', '%Y' %} {{ cookiecutter.author_name }}
|
||||
# {{ cookiecutter.author_name }} <{{ cookiecutter.email }}>, {% now 'utc', '%Y' %}.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: {{ cookiecutter.version }}\n"
|
||||
"Language: pt-BR\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
|
||||
#: {{cookiecutter.project_slug}}/templates/account/account_inactive.html:5
|
||||
#: {{cookiecutter.project_slug}}/templates/account/account_inactive.html:8
|
||||
msgid "Account Inactive"
|
||||
msgstr "Conta Inativa"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/account_inactive.html:10
|
||||
msgid "This account is inactive."
|
||||
msgstr "Esta conta está inativa."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:7
|
||||
msgid "Account"
|
||||
msgstr "Conta"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:10
|
||||
msgid "E-mail Addresses"
|
||||
msgstr "Endereços de E-mail"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:13
|
||||
msgid "The following e-mail addresses are associated with your account:"
|
||||
msgstr "Os seguintes endereços de e-mail estão associados à sua conta:"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:27
|
||||
msgid "Verified"
|
||||
msgstr "Verificado"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:29
|
||||
msgid "Unverified"
|
||||
msgstr "Não verificado"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:31
|
||||
msgid "Primary"
|
||||
msgstr "Primário"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:37
|
||||
msgid "Make Primary"
|
||||
msgstr "Tornar Primário"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:38
|
||||
msgid "Re-send Verification"
|
||||
msgstr "Reenviar verificação"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:39
|
||||
msgid "Remove"
|
||||
msgstr "Remover"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:46
|
||||
msgid "Warning:"
|
||||
msgstr "Aviso:"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:46
|
||||
msgid ""
|
||||
"You currently do not have any e-mail address set up. You should really add "
|
||||
"an e-mail address so you can receive notifications, reset your password, etc."
|
||||
msgstr ""
|
||||
"No momento, você não tem nenhum endereço de e-mail configurado. Você "
|
||||
"realmente deve adicionar um endereço de e-mail para receber notificações, "
|
||||
"redefinir sua senha etc."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:51
|
||||
msgid "Add E-mail Address"
|
||||
msgstr "Adicionar Endereço de E-mail"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:56
|
||||
msgid "Add E-mail"
|
||||
msgstr "Adicionar E-mail"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email.html:66
|
||||
msgid "Do you really want to remove the selected e-mail address?"
|
||||
msgstr "Você realmente deseja remover o endereço de e-mail selecionado?"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email_confirm.html:6
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email_confirm.html:10
|
||||
msgid "Confirm E-mail Address"
|
||||
msgstr "Confirme o endereço de e-mail"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email_confirm.html:16
|
||||
#, python-format
|
||||
msgid ""
|
||||
"Please confirm that <a href=\"mailto:%(email)s\">%(email)s</a> is an e-mail "
|
||||
"address for user %(user_display)s."
|
||||
msgstr ""
|
||||
"Confirme se <a href=\"mailto:%(email)s\">%(email)s</a> é um endereço de "
|
||||
"e-mail do usuário %(user_display)s."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email_confirm.html:20
|
||||
msgid "Confirm"
|
||||
msgstr "Confirmar"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/email_confirm.html:27
|
||||
#, python-format
|
||||
msgid ""
|
||||
"This e-mail confirmation link expired or is invalid. Please <a href="
|
||||
"\"%(email_url)s\">issue a new e-mail confirmation request</a>."
|
||||
msgstr "Este link de confirmação de e-mail expirou ou é inválido. "
|
||||
"Por favor, <a href=\"%(email_url)s\">emita um novo pedido de confirmação por e-mail</a>."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/login.html:7
|
||||
#: {{cookiecutter.project_slug}}/templates/account/login.html:11
|
||||
#: {{cookiecutter.project_slug}}/templates/account/login.html:56
|
||||
#: {{cookiecutter.project_slug}}/templates/base.html:72
|
||||
msgid "Sign In"
|
||||
msgstr "Entrar"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/login.html:17
|
||||
msgid "Please sign in with one of your existing third party accounts:"
|
||||
msgstr "Faça login com uma de suas contas de terceiros existentes:"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/login.html:19
|
||||
#, python-format
|
||||
msgid ""
|
||||
"Or, <a href=\"%(signup_url)s\">sign up</a> for a %(site_name)s account and "
|
||||
"sign in below:"
|
||||
msgstr "Ou, <a href=\"%(signup_url)s\">cadastre-se</a> para uma conta em %(site_name)s e entre abaixo:"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/login.html:32
|
||||
msgid "or"
|
||||
msgstr "or"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/login.html:41
|
||||
#, python-format
|
||||
msgid ""
|
||||
"If you have not created an account yet, then please <a href=\"%(signup_url)s"
|
||||
"\">sign up</a> first."
|
||||
msgstr "Se você ainda não criou uma conta, <a href=\"%(signup_url)s"
|
||||
"\">registre-se primeiro</a>."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/login.html:55
|
||||
msgid "Forgot Password?"
|
||||
msgstr "Esqueceu sua senha?"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/logout.html:5
|
||||
#: {{cookiecutter.project_slug}}/templates/account/logout.html:8
|
||||
#: {{cookiecutter.project_slug}}/templates/account/logout.html:17
|
||||
#: {{cookiecutter.project_slug}}/templates/base.html:61
|
||||
msgid "Sign Out"
|
||||
msgstr "Sair"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/logout.html:10
|
||||
msgid "Are you sure you want to sign out?"
|
||||
msgstr "Você tem certeza que deseja sair?"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_change.html:6
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_change.html:9
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_change.html:14
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key.html:5
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key.html:8
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key_done.html:4
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key_done.html:7
|
||||
msgid "Change Password"
|
||||
msgstr "Alterar Senha"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset.html:7
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset.html:11
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_done.html:6
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_done.html:9
|
||||
msgid "Password Reset"
|
||||
msgstr "Redefinição de senha"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset.html:16
|
||||
msgid ""
|
||||
"Forgotten your password? Enter your e-mail address below, and we'll send you "
|
||||
"an e-mail allowing you to reset it."
|
||||
msgstr "Esqueceu sua senha? Digite seu endereço de e-mail abaixo e enviaremos um e-mail permitindo que você o redefina."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset.html:21
|
||||
msgid "Reset My Password"
|
||||
msgstr "Redefinir minha senha"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset.html:24
|
||||
msgid "Please contact us if you have any trouble resetting your password."
|
||||
msgstr "Entre em contato conosco se tiver algum problema para redefinir sua senha."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_done.html:15
|
||||
msgid ""
|
||||
"We have sent you an e-mail. Please contact us if you do not receive it "
|
||||
"within a few minutes."
|
||||
msgstr "Enviamos um e-mail para você. Entre em contato conosco se você não recebê-lo dentro de alguns minutos."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key.html:8
|
||||
msgid "Bad Token"
|
||||
msgstr "Token Inválido"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key.html:12
|
||||
#, python-format
|
||||
msgid ""
|
||||
"The password reset link was invalid, possibly because it has already been "
|
||||
"used. Please request a <a href=\"%(passwd_reset_url)s\">new password reset</"
|
||||
"a>."
|
||||
msgstr "O link de redefinição de senha era inválido, possivelmente porque já foi usado. "
|
||||
"<a href=\"%(passwd_reset_url)s\">Solicite uma nova redefinição de senha</a>."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key.html:18
|
||||
msgid "change password"
|
||||
msgstr "alterar senha"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key.html:21
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_reset_from_key_done.html:8
|
||||
msgid "Your password is now changed."
|
||||
msgstr "Sua senha agora foi alterada."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_set.html:6
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_set.html:9
|
||||
#: {{cookiecutter.project_slug}}/templates/account/password_set.html:14
|
||||
msgid "Set Password"
|
||||
msgstr "Definir Senha"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/signup.html:6
|
||||
msgid "Signup"
|
||||
msgstr "Cadastro"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/signup.html:9
|
||||
#: {{cookiecutter.project_slug}}/templates/account/signup.html:19
|
||||
#: {{cookiecutter.project_slug}}/templates/base.html:67
|
||||
msgid "Sign Up"
|
||||
msgstr "Cadastro"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/signup.html:11
|
||||
#, python-format
|
||||
msgid ""
|
||||
"Already have an account? Then please <a href=\"%(login_url)s\">sign in</a>."
|
||||
msgstr "já tem uma conta? Então, por favor, faça <a href=\"%(login_url)s\">login</a>."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/signup_closed.html:5
|
||||
#: {{cookiecutter.project_slug}}/templates/account/signup_closed.html:8
|
||||
msgid "Sign Up Closed"
|
||||
msgstr "Inscrições encerradas"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/signup_closed.html:10
|
||||
msgid "We are sorry, but the sign up is currently closed."
|
||||
msgstr "Lamentamos, mas as inscrições estão encerradas no momento."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/verification_sent.html:5
|
||||
#: {{cookiecutter.project_slug}}/templates/account/verification_sent.html:8
|
||||
#: {{cookiecutter.project_slug}}/templates/account/verified_email_required.html:5
|
||||
#: {{cookiecutter.project_slug}}/templates/account/verified_email_required.html:8
|
||||
msgid "Verify Your E-mail Address"
|
||||
msgstr "Verifique seu endereço de e-mail"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/verification_sent.html:10
|
||||
msgid ""
|
||||
"We have sent an e-mail to you for verification. Follow the link provided to "
|
||||
"finalize the signup process. Please contact us if you do not receive it "
|
||||
"within a few minutes."
|
||||
msgstr "Enviamos um e-mail para você para verificação. Siga o link fornecido para finalizar o processo de inscrição. Entre em contato conosco se você não recebê-lo dentro de alguns minutos."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/verified_email_required.html:12
|
||||
msgid ""
|
||||
"This part of the site requires us to verify that\n"
|
||||
"you are who you claim to be. For this purpose, we require that you\n"
|
||||
"verify ownership of your e-mail address. "
|
||||
msgstr "Esta parte do site exige que verifiquemos se você é quem afirma ser.\n"
|
||||
"Para esse fim, exigimos que você verifique a propriedade\n"
|
||||
"do seu endereço de e-mail."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/verified_email_required.html:16
|
||||
msgid ""
|
||||
"We have sent an e-mail to you for\n"
|
||||
"verification. Please click on the link inside this e-mail. Please\n"
|
||||
"contact us if you do not receive it within a few minutes."
|
||||
msgstr "Enviamos um e-mail para você para verificação.\n"
|
||||
"Por favor, clique no link dentro deste e-mail.\n"
|
||||
"Entre em contato conosco se você não recebê-lo dentro de alguns minutos."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/account/verified_email_required.html:20
|
||||
#, python-format
|
||||
msgid ""
|
||||
"<strong>Note:</strong> you can still <a href=\"%(email_url)s\">change your e-"
|
||||
"mail address</a>."
|
||||
msgstr "<strong>Nota</strong>: você ainda pode <a href=\"%(email_url)s\">alterar seu endereço de e-mail</a>."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/templates/base.html:57
|
||||
msgid "My Profile"
|
||||
msgstr "Meu perfil"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/users/admin.py:17
|
||||
msgid "Personal info"
|
||||
msgstr "Informação pessoal"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/users/admin.py:19
|
||||
msgid "Permissions"
|
||||
msgstr "Permissões"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/users/admin.py:30
|
||||
msgid "Important dates"
|
||||
msgstr "Datas importantes"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/users/apps.py:7
|
||||
msgid "Users"
|
||||
msgstr "Usuários"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/users/forms.py:24
|
||||
#: {{cookiecutter.project_slug}}/users/tests/test_forms.py:36
|
||||
msgid "This username has already been taken."
|
||||
msgstr "Este nome de usuário já foi usado."
|
||||
|
||||
#: {{cookiecutter.project_slug}}/users/models.py:15
|
||||
msgid "Name of User"
|
||||
msgstr "Nome do Usuário"
|
||||
|
||||
#: {{cookiecutter.project_slug}}/users/views.py:23
|
||||
msgid "Information successfully updated"
|
||||
msgstr "Informação atualizada com sucesso"
|
|
@ -29,7 +29,7 @@
|
|||
"sass": "^1.43.4",
|
||||
"sass-loader": "^13.2.0",
|
||||
"webpack": "^5.65.0",
|
||||
"webpack-bundle-tracker": "^1.4.0",
|
||||
"webpack-bundle-tracker": "^2.0.0",
|
||||
"webpack-cli": "^5.0.1",
|
||||
"webpack-dev-server": "^4.6.0",
|
||||
"webpack-merge": "^5.8.0"
|
||||
|
|
|
@ -9,17 +9,17 @@ rcssmin==1.1.1 # https://github.com/ndparker/rcssmin
|
|||
{%- endif %}
|
||||
argon2-cffi==21.3.0 # https://github.com/hynek/argon2_cffi
|
||||
{%- if cookiecutter.use_whitenoise == 'y' %}
|
||||
whitenoise==6.4.0 # https://github.com/evansd/whitenoise
|
||||
whitenoise==6.5.0 # https://github.com/evansd/whitenoise
|
||||
{%- endif %}
|
||||
redis==4.5.4 # https://github.com/redis/redis-py
|
||||
redis==4.6.0 # https://github.com/redis/redis-py
|
||||
{%- if cookiecutter.use_docker == "y" or cookiecutter.windows == "n" %}
|
||||
hiredis==2.2.2 # https://github.com/redis/hiredis-py
|
||||
hiredis==2.2.3 # https://github.com/redis/hiredis-py
|
||||
{%- endif %}
|
||||
{%- if cookiecutter.use_celery == "y" %}
|
||||
celery==5.2.7 # pyup: < 6.0 # https://github.com/celery/celery
|
||||
celery==5.3.1 # pyup: < 6.0 # https://github.com/celery/celery
|
||||
django-celery-beat==2.5.0 # https://github.com/celery/django-celery-beat
|
||||
{%- if cookiecutter.use_docker == 'y' %}
|
||||
flower==1.2.0 # https://github.com/mher/flower
|
||||
flower==2.0.0 # https://github.com/mher/flower
|
||||
{%- endif %}
|
||||
{%- endif %}
|
||||
{%- if cookiecutter.use_async == 'y' %}
|
||||
|
@ -37,14 +37,14 @@ crispy-bootstrap5==0.7 # https://github.com/django-crispy-forms/crispy-bootstra
|
|||
{%- if cookiecutter.frontend_pipeline == 'Django Compressor' %}
|
||||
django-compressor==4.3.1 # https://github.com/django-compressor/django-compressor
|
||||
{%- endif %}
|
||||
django-redis==5.2.0 # https://github.com/jazzband/django-redis
|
||||
django-redis==5.3.0 # https://github.com/jazzband/django-redis
|
||||
{%- if cookiecutter.use_drf == 'y' %}
|
||||
# Django REST Framework
|
||||
djangorestframework==3.14.0 # https://github.com/encode/django-rest-framework
|
||||
django-cors-headers==3.14.0 # https://github.com/adamchainz/django-cors-headers
|
||||
django-cors-headers==4.1.0 # https://github.com/adamchainz/django-cors-headers
|
||||
# DRF-spectacular for api documentation
|
||||
drf-spectacular==0.26.2 # https://github.com/tfranzel/drf-spectacular
|
||||
drf-spectacular==0.26.3 # https://github.com/tfranzel/drf-spectacular
|
||||
{%- endif %}
|
||||
{%- if cookiecutter.frontend_pipeline == 'Webpack' %}
|
||||
django-webpack-loader==1.8.1 # https://github.com/django-webpack/django-webpack-loader
|
||||
django-webpack-loader==2.0.1 # https://github.com/django-webpack/django-webpack-loader
|
||||
{%- endif %}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
-r base.txt
|
||||
|
||||
Werkzeug[watchdog]==2.3.3 # https://github.com/pallets/werkzeug
|
||||
Werkzeug[watchdog]==2.3.5 # https://github.com/pallets/werkzeug
|
||||
ipdb==0.13.13 # https://github.com/gotcha/ipdb
|
||||
{%- if cookiecutter.use_docker == 'y' %}
|
||||
psycopg2==2.9.6 # https://github.com/psycopg/psycopg2
|
||||
|
@ -13,12 +13,12 @@ watchfiles==0.19.0 # https://github.com/samuelcolvin/watchfiles
|
|||
|
||||
# Testing
|
||||
# ------------------------------------------------------------------------------
|
||||
mypy==1.2.0 # https://github.com/python/mypy
|
||||
django-stubs==4.2.0 # https://github.com/typeddjango/django-stubs
|
||||
pytest==7.3.1 # https://github.com/pytest-dev/pytest
|
||||
mypy==1.4.1 # https://github.com/python/mypy
|
||||
django-stubs==4.2.1 # https://github.com/typeddjango/django-stubs
|
||||
pytest==7.4.0 # https://github.com/pytest-dev/pytest
|
||||
pytest-sugar==0.9.7 # https://github.com/Frozenball/pytest-sugar
|
||||
{%- if cookiecutter.use_drf == "y" %}
|
||||
djangorestframework-stubs==3.14.0 # https://github.com/typeddjango/djangorestframework-stubs
|
||||
djangorestframework-stubs==3.14.1 # https://github.com/typeddjango/djangorestframework-stubs
|
||||
{%- endif %}
|
||||
|
||||
# Documentation
|
||||
|
@ -30,19 +30,19 @@ sphinx-autobuild==2021.3.14 # https://github.com/GaretJax/sphinx-autobuild
|
|||
# ------------------------------------------------------------------------------
|
||||
flake8==6.0.0 # https://github.com/PyCQA/flake8
|
||||
flake8-isort==6.0.0 # https://github.com/gforcada/flake8-isort
|
||||
coverage==7.2.5 # https://github.com/nedbat/coveragepy
|
||||
coverage==7.2.7 # https://github.com/nedbat/coveragepy
|
||||
black==23.3.0 # https://github.com/psf/black
|
||||
pylint-django==2.5.3 # https://github.com/PyCQA/pylint-django
|
||||
{%- if cookiecutter.use_celery == 'y' %}
|
||||
pylint-celery==0.3 # https://github.com/PyCQA/pylint-celery
|
||||
{%- endif %}
|
||||
pre-commit==3.3.1 # https://github.com/pre-commit/pre-commit
|
||||
pre-commit==3.3.3 # https://github.com/pre-commit/pre-commit
|
||||
|
||||
# Django
|
||||
# ------------------------------------------------------------------------------
|
||||
factory-boy==3.2.1 # https://github.com/FactoryBoy/factory_boy
|
||||
|
||||
django-debug-toolbar==4.0.0 # https://github.com/jazzband/django-debug-toolbar
|
||||
django-extensions==3.2.1 # https://github.com/django-extensions/django-extensions
|
||||
django-debug-toolbar==4.1.0 # https://github.com/jazzband/django-debug-toolbar
|
||||
django-extensions==3.2.3 # https://github.com/django-extensions/django-extensions
|
||||
django-coverage-plugin==3.0.0 # https://github.com/nedbat/django_coverage_plugin
|
||||
pytest-django==4.5.2 # https://github.com/pytest-dev/pytest-django
|
||||
|
|
|
@ -8,10 +8,10 @@ psycopg2==2.9.6 # https://github.com/psycopg/psycopg2
|
|||
Collectfast==2.2.0 # https://github.com/antonagestam/collectfast
|
||||
{%- endif %}
|
||||
{%- if cookiecutter.use_sentry == "y" %}
|
||||
sentry-sdk==1.22.2 # https://github.com/getsentry/sentry-python
|
||||
sentry-sdk==1.26.0 # https://github.com/getsentry/sentry-python
|
||||
{%- endif %}
|
||||
{%- if cookiecutter.use_docker == "n" and cookiecutter.windows == "y" %}
|
||||
hiredis==2.2.2 # https://github.com/redis/hiredis-py
|
||||
hiredis==2.2.3 # https://github.com/redis/hiredis-py
|
||||
{%- endif %}
|
||||
|
||||
# Django
|
||||
|
@ -24,21 +24,21 @@ django-storages[google]==1.13.2 # https://github.com/jschneier/django-storages
|
|||
django-storages[azure]==1.13.2 # https://github.com/jschneier/django-storages
|
||||
{%- endif %}
|
||||
{%- if cookiecutter.mail_service == 'Mailgun' %}
|
||||
django-anymail[mailgun]==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail[mailgun]==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- elif cookiecutter.mail_service == 'Amazon SES' %}
|
||||
django-anymail[amazon_ses]==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail[amazon-ses]==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- elif cookiecutter.mail_service == 'Mailjet' %}
|
||||
django-anymail[mailjet]==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail[mailjet]==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- elif cookiecutter.mail_service == 'Mandrill' %}
|
||||
django-anymail[mandrill]==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail[mandrill]==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- elif cookiecutter.mail_service == 'Postmark' %}
|
||||
django-anymail[postmark]==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail[postmark]==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- elif cookiecutter.mail_service == 'Sendgrid' %}
|
||||
django-anymail[sendgrid]==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail[sendgrid]==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- elif cookiecutter.mail_service == 'SendinBlue' %}
|
||||
django-anymail[sendinblue]==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail[sendinblue]==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- elif cookiecutter.mail_service == 'SparkPost' %}
|
||||
django-anymail[sparkpost]==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail[sparkpost]==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- elif cookiecutter.mail_service == 'Other SMTP' %}
|
||||
django-anymail==9.2 # https://github.com/anymail/django-anymail
|
||||
django-anymail==10.0 # https://github.com/anymail/django-anymail
|
||||
{%- endif %}
|
||||
|
|
|
@ -1 +1 @@
|
|||
python-3.11.3
|
||||
python-3.11.4
|
||||
|
|
|
@ -20,7 +20,8 @@ module.exports = {
|
|||
},
|
||||
plugins: [
|
||||
new BundleTracker({
|
||||
filename: path.resolve(__dirname, '../webpack-stats.json'),
|
||||
path: path.resolve(path.join(__dirname, '../')),
|
||||
filename: 'webpack-stats.json',
|
||||
}),
|
||||
new MiniCssExtractPlugin({ filename: 'css/[name].[contenthash].css' }),
|
||||
],
|
||||
|
|
|
@ -7,6 +7,7 @@ from django.contrib.sessions.middleware import SessionMiddleware
|
|||
from django.http import HttpRequest, HttpResponseRedirect
|
||||
from django.test import RequestFactory
|
||||
from django.urls import reverse
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
|
||||
from {{ cookiecutter.project_slug }}.users.forms import UserAdminChangeForm
|
||||
from {{ cookiecutter.project_slug }}.users.models import User
|
||||
|
@ -72,7 +73,7 @@ class TestUserUpdateView:
|
|||
view.form_valid(form)
|
||||
|
||||
messages_sent = [m.message for m in messages.get_messages(request)]
|
||||
assert messages_sent == ["Information successfully updated"]
|
||||
assert messages_sent == [_("Information successfully updated")]
|
||||
|
||||
|
||||
class TestUserRedirectView:
|
||||
|
|
Loading…
Reference in New Issue
Block a user