Merge branch 'master' into bootstrap5

This commit is contained in:
Andrew Chen Wang 2021-07-27 01:16:15 -04:00 committed by GitHub
commit cc28195e38
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
26 changed files with 295 additions and 89 deletions

View File

@ -14,12 +14,38 @@ labels: bug
* Host system configuration: * Host system configuration:
* Version of cookiecutter CLI (get it with `cookiecutter --version`): * Version of cookiecutter CLI (get it with `cookiecutter --version`):
* OS: * OS name and version:
* Python version:
* Docker versions (if using Docker): On Linux, run
```bash
lsb_release -a 2> /dev/null || cat /etc/redhat-release 2> /dev/null || cat /etc/*-release 2> /dev/null || cat /etc/issue 2> /dev/null
```
On MacOs, run
```bash
sw_vers
```
On Windows, via CMD, run
```
systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
```
```bash
# Insert here the OS name and version
```
* Python version, run `python3 -V`:
* Docker version (if using Docker), run `docker --version`:
* docker-compose version (if using Docker), run `docker-compose --version`:
* ... * ...
* Options selected and/or [replay file](https://cookiecutter.readthedocs.io/en/latest/advanced/replay.html): * Options selected and/or [replay file](https://cookiecutter.readthedocs.io/en/latest/advanced/replay.html):
``` On Linux and MacOS: `cat ${HOME}/.cookiecutter_replay/cookiecutter-django.json`
(Please, take care to remove sensitive information)
```json
# Insert here the replay file content
``` ```
<summary> <summary>
Logs: Logs:

View File

@ -1082,5 +1082,30 @@
"name": "Tames McTigue", "name": "Tames McTigue",
"github_login": "Tamerz", "github_login": "Tamerz",
"twitter_username": "" "twitter_username": ""
},
{
"name": "Ray Besiga",
"github_login": "raybesiga",
"twitter_username": "raybesiga"
},
{
"name": "Grant McLean",
"github_login": "grantm",
"twitter_username": "grantmnz"
},
{
"name": "Kuo Chao Cheng",
"github_login": "wwwtony5488",
"twitter_username": ""
},
{
"name": "LECbg",
"github_login": "LECbg",
"twitter_username": ""
},
{
"name": "Haseeb ur Rehman",
"github_login": "professorhaseeb",
"twitter_username": "professorhaseeb"
} }
] ]

View File

@ -17,7 +17,7 @@ jobs:
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2.2.2
with: with:
python-version: 3.9 python-version: 3.9
- name: Install dependencies - name: Install dependencies
@ -44,7 +44,7 @@ jobs:
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2.2.2
with: with:
python-version: 3.9 python-version: 3.9
- name: Docker ${{ matrix.script.name }} - name: Docker ${{ matrix.script.name }}
@ -78,7 +78,7 @@ jobs:
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2.2.2
with: with:
python-version: 3.9 python-version: 3.9
- name: Bare Metal ${{ matrix.script.name }} - name: Bare Metal ${{ matrix.script.name }}

View File

@ -23,7 +23,7 @@ jobs:
issue-manager: issue-manager:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: tiangolo/issue-manager@0.3.0 - uses: tiangolo/issue-manager@0.4.0
with: with:
token: ${{ secrets.GITHUB_TOKEN }} token: ${{ secrets.GITHUB_TOKEN }}

View File

@ -14,7 +14,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2.2.2
with: with:
python-version: 3.9 python-version: 3.9
@ -26,7 +26,7 @@ jobs:
run: pre-commit autoupdate run: pre-commit autoupdate
- name: Create Pull Request - name: Create Pull Request
uses: peter-evans/create-pull-request@v3.8.2 uses: peter-evans/create-pull-request@v3.10.0
with: with:
token: ${{ secrets.GITHUB_TOKEN }} token: ${{ secrets.GITHUB_TOKEN }}
branch: update/pre-commit-autoupdate branch: update/pre-commit-autoupdate

View File

@ -15,7 +15,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v2 uses: actions/setup-python@v2.2.2
with: with:
python-version: 3.9 python-version: 3.9
- name: Install dependencies - name: Install dependencies
@ -28,7 +28,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Commit changes - name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v4.10.0 uses: stefanzweifel/git-auto-commit-action@v4.11.0
with: with:
commit_message: Update Changelog commit_message: Update Changelog
file_pattern: CHANGELOG.md file_pattern: CHANGELOG.md

View File

@ -13,7 +13,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v2 uses: actions/setup-python@v2.2.2
with: with:
python-version: 3.9 python-version: 3.9
- name: Install dependencies - name: Install dependencies
@ -24,7 +24,7 @@ jobs:
run: python scripts/update_contributors.py run: python scripts/update_contributors.py
- name: Commit changes - name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v4.10.0 uses: stefanzweifel/git-auto-commit-action@v4.11.0
with: with:
commit_message: Update Contributors commit_message: Update Contributors
file_pattern: CONTRIBUTORS.md .github/contributors.json file_pattern: CONTRIBUTORS.md .github/contributors.json

View File

@ -3,6 +3,117 @@ All enhancements and patches to Cookiecutter Django will be documented in this f
<!-- GENERATOR_PLACEHOLDER --> <!-- GENERATOR_PLACEHOLDER -->
## [2021-07-12]
### Changed
- Define REMAP_SIGTERM=SIGQUIT on Profile of Celery on Heroku ([#3263](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3263))
## [2021-07-08]
### Updated
- Update django to 3.1.13 ([#3247](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3247))
## [2021-06-29]
### Changed
- Improve github bug report template ([#3243](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3243))
## [2021-06-28]
### Changed
- Revert &#34;Fix Celery ports error on local Docker&#34; ([#3242](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3242))
### Fixed
- Fix Celery ports error on local Docker ([#3241](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3241))
## [2021-06-25]
### Changed
- Update `.gitignore` file for VSCode ([#3238](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3238))
### Fixed
- Wrap jQuery call in `DOMContentLoaded` event listener on account email page ([#3239](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3239))
## [2021-06-22]
### Changed
- Update docs/howto.rst ([#3230](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3230))
- Add support for PG 13. Drop PG 9. Update all minor versions ([#3154](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3154))
### Updated
- Update isort to 5.9.1 ([#3236](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3236))
- Auto-update pre-commit hooks ([#3235](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3235))
## [2021-06-21]
### Updated
- Update isort to 5.9.0 ([#3234](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3234))
- Update django-anymail to 8.4 ([#3225](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3225))
- Update django-redis to 5.0.0 ([#3205](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3205))
- Update pylint-django to 2.4.4 ([#3233](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3233))
- Auto-update pre-commit hooks ([#3220](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3220))
- Bump peter-evans/create-pull-request from 3.9.2 to 3.10.0 ([#3197](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3197))
- Update black to 21.6b0 ([#3232](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3232))
- Update pytest to 6.2.4 ([#3231](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3231))
- Update django-crispy-forms to 1.12.0 ([#3221](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3221))
- Update mypy to 0.902 ([#3219](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3219))
- Update django-coverage-plugin to 2.0.0 ([#3217](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3217))
- Update ipdb to 0.13.9 ([#3210](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3210))
- Update uvicorn to 0.14.0 ([#3207](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3207))
- Update pytest-cookies to 0.6.1 ([#3196](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3196))
- Update sphinx to 4.0.2 ([#3193](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3193))
- Update jinja2 to 3.0.1 ([#3189](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3189))
## [2021-06-19]
### Updated
- Update psycopg2 to 2.9.1 ([#3227](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3227))
- Update psycopg2-binary to 2.9.1 ([#3228](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3228))
## [2021-06-14]
### Changed
- Update black GitHub link in requirements ([#3222](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3222))
## [2021-06-09]
### Changed
- Fix link format in developing-locally.rst ([#3214](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3214))
### Updated
- Update pre-commit to 2.13.0 ([#3195](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3195))
- Update pytest-django to 4.4.0 ([#3212](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3212))
- Update mypy to 0.901 ([#3215](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3215))
- Auto-update pre-commit hooks ([#3206](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3206))
- Update black to 21.5b2 ([#3204](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3204))
## [2021-06-06]
### Changed
- Updated .pre-commit-config.yaml to self-update its dependencies ([#3208](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3208))
## [2021-06-05]
### Changed
- Shorthand for the officially supported buildpack ([#3211](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3211))
## [2021-06-02]
### Updated
- Update django to 3.1.12 ([#3209](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3209))
## [2021-05-18]
### Changed
- Move ARG PYTHON_VERSION=3.9-slim-buster to the global scope ([#3188](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3188))
## [2021-05-17]
### Updated
- Bump tiangolo/issue-manager from 0.3.0 to 0.4.0 ([#3186](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3186))
- Auto-update pre-commit hooks ([#3185](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3185))
## [2021-05-15]
### Changed
- Update watchgod to 0.7 ([#3177](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3177))
### Updated
- Auto-update pre-commit hooks ([#3184](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3184))
- Update black to 21.5b1 ([#3167](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3167))
- Update flake8 to 3.9.2 ([#3164](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3164))
- Update pytest-django to 4.3.0 ([#3182](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3182))
- Auto-update pre-commit hooks ([#3157](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3157))
- Update python-slugify to 5.0.2 ([#3161](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3161))
- Bump stefanzweifel/git-auto-commit-action from 4.10.0 to 4.11.0 ([#3171](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3171))
- Update sentry-sdk to 1.1.0 ([#3163](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3163))
- Bump actions/setup-python from 2 to 2.2.2 ([#3173](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3173))
- Update tox to 3.23.1 ([#3160](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3160))
- Update pytest to 6.2.4 ([#3156](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3156))
- Bump peter-evans/create-pull-request from 3.8.2 to 3.9.2 ([#3179](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3179))
- Update sphinx to 4.0.1 ([#3169](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3169))
- Update cookiecutter to 1.7.3 ([#3180](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3180))
- Update django to 3.1.11 ([#3178](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3178))
## [2021-05-06] ## [2021-05-06]
### Updated ### Updated
- Update django to 3.1.10 ([#3162](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3162)) - Update django to 3.1.10 ([#3162](https://api.github.com/repos/pydanny/cookiecutter-django/pulls/3162))

View File

@ -712,6 +712,13 @@ Listed in alphabetical order.
</td> </td>
<td></td> <td></td>
</tr> </tr>
<tr>
<td>Grant McLean</td>
<td>
<a href="https://github.com/grantm">grantm</a>
</td>
<td>grantmnz</td>
</tr>
<tr> <tr>
<td>Guilherme Guy</td> <td>Guilherme Guy</td>
<td> <td>
@ -754,6 +761,13 @@ Listed in alphabetical order.
</td> </td>
<td></td> <td></td>
</tr> </tr>
<tr>
<td>Haseeb ur Rehman</td>
<td>
<a href="https://github.com/professorhaseeb">professorhaseeb</a>
</td>
<td>professorhaseeb</td>
</tr>
<tr> <tr>
<td>Hendrik Schneider</td> <td>Hendrik Schneider</td>
<td> <td>
@ -978,6 +992,13 @@ Listed in alphabetical order.
</td> </td>
<td></td> <td></td>
</tr> </tr>
<tr>
<td>Kuo Chao Cheng</td>
<td>
<a href="https://github.com/wwwtony5488">wwwtony5488</a>
</td>
<td></td>
</tr>
<tr> <tr>
<td>lcd1232</td> <td>lcd1232</td>
<td> <td>
@ -985,6 +1006,13 @@ Listed in alphabetical order.
</td> </td>
<td></td> <td></td>
</tr> </tr>
<tr>
<td>LECbg</td>
<td>
<a href="https://github.com/LECbg">LECbg</a>
</td>
<td></td>
</tr>
<tr> <tr>
<td>Leo won</td> <td>Leo won</td>
<td> <td>
@ -1251,6 +1279,13 @@ Listed in alphabetical order.
</td> </td>
<td></td> <td></td>
</tr> </tr>
<tr>
<td>Ray Besiga</td>
<td>
<a href="https://github.com/raybesiga">raybesiga</a>
</td>
<td>raybesiga</td>
</tr>
<tr> <tr>
<td>Reggie Riser</td> <td>Reggie Riser</td>
<td> <td>

View File

@ -96,7 +96,7 @@ Constraints
----------- -----------
* Only maintained 3rd party libraries are used. * Only maintained 3rd party libraries are used.
* Uses PostgreSQL everywhere (9.4 - 12.3) * Uses PostgreSQL everywhere (10.16 - 13.2)
* Environment variables for configuration (This won't work with Apache/mod_wsgi). * Environment variables for configuration (This won't work with Apache/mod_wsgi).
Support this Project! Support this Project!
@ -177,11 +177,10 @@ Answer the prompts with your own desired options_. For example::
use_heroku [n]: y use_heroku [n]: y
use_compressor [n]: y use_compressor [n]: y
Select postgresql_version: Select postgresql_version:
1 - 12.3 1 - 13.2
2 - 11.8 2 - 12.6
3 - 10.8 3 - 11.11
4 - 9.6 4 - 10.16
5 - 9.5
Choose from 1, 2, 3, 4, 5 [1]: 1 Choose from 1, 2, 3, 4, 5 [1]: 1
Select js_task_runner: Select js_task_runner:
1 - None 1 - None

View File

@ -18,11 +18,10 @@
"use_pycharm": "n", "use_pycharm": "n",
"use_docker": "n", "use_docker": "n",
"postgresql_version": [ "postgresql_version": [
"12.3", "13.2",
"11.8", "12.6",
"10.8", "11.11",
"9.6", "10.16"
"9.5"
], ],
"js_task_runner": [ "js_task_runner": [
"None", "None",

View File

@ -10,7 +10,7 @@ Run these commands to deploy the project to Heroku:
.. code-block:: bash .. code-block:: bash
heroku create --buildpack https://github.com/heroku/heroku-buildpack-python heroku create --buildpack heroku/python
heroku addons:create heroku-postgresql:hobby-dev heroku addons:create heroku-postgresql:hobby-dev
# On Windows use double quotes for the time zone, e.g. # On Windows use double quotes for the time zone, e.g.

View File

@ -36,8 +36,8 @@ First things first.
.. note:: .. note::
the `pre-commit` exists in the generated project as default. the `pre-commit` hook exists in the generated project as default.
for the details of `pre-commit`, follow the [site of pre-commit](https://pre-commit.com/). For the details of `pre-commit`, follow the `pre-commit`_ site.
#. Create a new PostgreSQL database using createdb_: :: #. Create a new PostgreSQL database using createdb_: ::
@ -88,6 +88,7 @@ or if you're running asynchronously: ::
.. _createdb: https://www.postgresql.org/docs/current/static/app-createdb.html .. _createdb: https://www.postgresql.org/docs/current/static/app-createdb.html
.. _initial PostgreSQL set up: http://suite.opengeo.org/docs/latest/dataadmin/pgGettingStarted/firstconnect.html .. _initial PostgreSQL set up: http://suite.opengeo.org/docs/latest/dataadmin/pgGettingStarted/firstconnect.html
.. _postgres documentation: https://www.postgresql.org/docs/current/static/auth-pg-hba-conf.html .. _postgres documentation: https://www.postgresql.org/docs/current/static/auth-pg-hba-conf.html
.. _pre-commit: https://pre-commit.com/
.. _direnv: https://direnv.net/ .. _direnv: https://direnv.net/

View File

@ -1,24 +1,24 @@
cookiecutter==1.7.2 cookiecutter==1.7.3
sh==1.14.1 sh==1.14.2
binaryornot==0.4.4 binaryornot==0.4.4
# Code quality # Code quality
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
black==21.4b2 black==21.6b0
isort==5.8.0 isort==5.9.1
flake8==3.9.1 flake8==3.9.2
flake8-isort==4.0.0 flake8-isort==4.0.0
pre-commit==2.12.1 pre-commit==2.13.0
# Testing # Testing
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
tox==3.23.0 tox==3.23.1
pytest==5.4.3 # pyup: <6 # https://github.com/hackebrot/pytest-cookies/issues/51 pytest==6.2.4
pytest-cookies==0.5.1 pytest-cookies==0.6.1
pytest-instafail==0.4.2 pytest-instafail==0.4.2
pyyaml==5.4.1 pyyaml==5.4.1
# Scripting # Scripting
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
PyGithub==1.55 PyGithub==1.55
jinja2==2.11.3 jinja2==3.0.1

View File

@ -10,7 +10,7 @@ except ImportError:
# Our version ALWAYS matches the version of Django we support # Our version ALWAYS matches the version of Django we support
# If Django has a new release, we branch, tag, then update this setting after the tag. # If Django has a new release, we branch, tag, then update this setting after the tag.
version = "3.1.8" version = "3.1.12"
if sys.argv[-1] == "tag": if sys.argv[-1] == "tag":
os.system(f'git tag -a {version} -m "version {version}"') os.system(f'git tag -a {version} -m "version {version}"')

View File

@ -37,11 +37,10 @@ SUPPORTED_COMBINATIONS = [
{"use_pycharm": "n"}, {"use_pycharm": "n"},
{"use_docker": "y"}, {"use_docker": "y"},
{"use_docker": "n"}, {"use_docker": "n"},
{"postgresql_version": "12.3"}, {"postgresql_version": "13.2"},
{"postgresql_version": "11.8"}, {"postgresql_version": "12.6"},
{"postgresql_version": "10.8"}, {"postgresql_version": "11.11"},
{"postgresql_version": "9.6"}, {"postgresql_version": "10.16"},
{"postgresql_version": "9.5"},
{"cloud_provider": "AWS", "use_whitenoise": "y"}, {"cloud_provider": "AWS", "use_whitenoise": "y"},
{"cloud_provider": "AWS", "use_whitenoise": "n"}, {"cloud_provider": "AWS", "use_whitenoise": "n"},
{"cloud_provider": "GCP", "use_whitenoise": "y"}, {"cloud_provider": "GCP", "use_whitenoise": "y"},

View File

@ -7,3 +7,4 @@
.pre-commit-config.yaml .pre-commit-config.yaml
.readthedocs.yml .readthedocs.yml
.travis.yml .travis.yml
venv

View File

@ -159,6 +159,10 @@ typings/
!.vscode/tasks.json !.vscode/tasks.json
!.vscode/launch.json !.vscode/launch.json
!.vscode/extensions.json !.vscode/extensions.json
*.code-workspace
# Local History for Visual Studio Code
.history/
{% if cookiecutter.use_pycharm == 'y' -%} {% if cookiecutter.use_pycharm == 'y' -%}

View File

@ -4,25 +4,32 @@ fail_fast: true
repos: repos:
- repo: https://github.com/pre-commit/pre-commit-hooks - repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.4.0 rev: v4.0.1
hooks: hooks:
- id: trailing-whitespace - id: trailing-whitespace
- id: end-of-file-fixer - id: end-of-file-fixer
- id: check-yaml - id: check-yaml
- repo: https://github.com/psf/black - repo: https://github.com/psf/black
rev: 21.4b2 rev: 21.6b0
hooks: hooks:
- id: black - id: black
- repo: https://github.com/timothycrosley/isort - repo: https://github.com/timothycrosley/isort
rev: 5.8.0 rev: 5.9.1
hooks: hooks:
- id: isort - id: isort
- repo: https://gitlab.com/pycqa/flake8 - repo: https://gitlab.com/pycqa/flake8
rev: 3.9.1 rev: 3.9.2
hooks: hooks:
- id: flake8 - id: flake8
args: ['--config=setup.cfg'] args: ['--config=setup.cfg']
additional_dependencies: [flake8-isort] additional_dependencies: [flake8-isort]
# sets up .pre-commit-ci.yaml to ensure pre-commit dependencies stay up to date
ci:
autoupdate_schedule: weekly
skip: []
submodules: false

View File

@ -5,6 +5,6 @@ web: gunicorn config.asgi:application -k uvicorn.workers.UvicornWorker
web: gunicorn config.wsgi:application web: gunicorn config.wsgi:application
{%- endif %} {%- endif %}
{%- if cookiecutter.use_celery == "y" -%} {%- if cookiecutter.use_celery == "y" -%}
worker: celery worker --app=config.celery_app --loglevel=info worker: REMAP_SIGTERM=SIGQUIT celery worker --app=config.celery_app --loglevel=info
beat: celery beat --app=config.celery_app --loglevel=info beat: REMAP_SIGTERM=SIGQUIT celery beat --app=config.celery_app --loglevel=info
{%- endif %} {%- endif %}

View File

@ -1,3 +1,5 @@
ARG PYTHON_VERSION=3.9-slim-buster
{% if cookiecutter.js_task_runner == 'Gulp' -%} {% if cookiecutter.js_task_runner == 'Gulp' -%}
FROM node:10-stretch-slim as client-builder FROM node:10-stretch-slim as client-builder
@ -11,8 +13,6 @@ RUN npm run build
{%- endif %} {%- endif %}
ARG PYTHON_VERSION=3.9-slim-buster
# define an alias for the specfic python version used in this file. # define an alias for the specfic python version used in this file.
FROM python:${PYTHON_VERSION} as python FROM python:${PYTHON_VERSION} as python

View File

@ -4,20 +4,19 @@ How To - Project Documentation
Get Started Get Started
---------------------------------------------------------------------- ----------------------------------------------------------------------
Documentation can be written as rst files in the `{{cookiecutter.project_slug}}/docs/_source`. Documentation can be written as rst files in `{{cookiecutter.project_slug}}/docs`.
{% if cookiecutter.use_docker == 'n' %} {% if cookiecutter.use_docker == 'n' %}
To build and serve docs, use the command: To build and serve docs, use the command::
::
make livehtml make livehtml
from inside the `{{cookiecutter.project_slug}}/docs` directory. from inside the `{{cookiecutter.project_slug}}/docs` directory.
{% else %} {% else %}
To build and serve docs, use the commands: To build and serve docs, use the commands::
::
docker-compose -f local.yml up docs docker-compose -f local.yml up docs
{% endif %} {% endif %}
Changes to files in `docs/_source` will be picked up and reloaded automatically. Changes to files in `docs/_source` will be picked up and reloaded automatically.

View File

@ -1,5 +1,5 @@
pytz==2021.1 # https://github.com/stub42/pytz pytz==2021.1 # https://github.com/stub42/pytz
python-slugify==4.0.1 # https://github.com/un33k/python-slugify python-slugify==5.0.2 # https://github.com/un33k/python-slugify
Pillow==8.2.0 # https://github.com/python-pillow/Pillow Pillow==8.2.0 # https://github.com/python-pillow/Pillow
{%- if cookiecutter.use_compressor == "y" %} {%- if cookiecutter.use_compressor == "y" %}
{%- if cookiecutter.windows == 'y' and cookiecutter.use_docker == 'n' %} {%- if cookiecutter.windows == 'y' and cookiecutter.use_docker == 'n' %}
@ -24,21 +24,21 @@ flower==0.9.7 # https://github.com/mher/flower
{%- endif %} {%- endif %}
{%- endif %} {%- endif %}
{%- if cookiecutter.use_async == 'y' %} {%- if cookiecutter.use_async == 'y' %}
uvicorn[standard]==0.13.4 # https://github.com/encode/uvicorn uvicorn[standard]==0.14.0 # https://github.com/encode/uvicorn
{%- endif %} {%- endif %}
# Django # Django
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
django==3.1.10 # pyup: < 3.2 # https://www.djangoproject.com/ django==3.1.13 # pyup: < 3.2 # https://www.djangoproject.com/
django-environ==0.4.5 # https://github.com/joke2k/django-environ django-environ==0.4.5 # https://github.com/joke2k/django-environ
django-model-utils==4.1.1 # https://github.com/jazzband/django-model-utils django-model-utils==4.1.1 # https://github.com/jazzband/django-model-utils
django-allauth==0.44.0 # https://github.com/pennersr/django-allauth django-allauth==0.44.0 # https://github.com/pennersr/django-allauth
django-crispy-forms==1.11.2 # https://github.com/django-crispy-forms/django-crispy-forms django-crispy-forms==1.12.0 # https://github.com/django-crispy-forms/django-crispy-forms
crispy-bootstrap5==0.4 # https://github.com/django-crispy-forms/crispy-bootstrap5 crispy-bootstrap5==0.4 # https://github.com/django-crispy-forms/crispy-bootstrap5
{%- if cookiecutter.use_compressor == "y" %} {%- if cookiecutter.use_compressor == "y" %}
django-compressor==2.4.1 # https://github.com/django-compressor/django-compressor django-compressor==2.4.1 # https://github.com/django-compressor/django-compressor
{%- endif %} {%- endif %}
django-redis==4.12.1 # https://github.com/jazzband/django-redis django-redis==5.0.0 # https://github.com/jazzband/django-redis
{%- if cookiecutter.use_drf == "y" %} {%- if cookiecutter.use_drf == "y" %}
# Django REST Framework # Django REST Framework
djangorestframework==3.12.4 # https://github.com/encode/django-rest-framework djangorestframework==3.12.4 # https://github.com/encode/django-rest-framework

View File

@ -1,39 +1,39 @@
-r base.txt -r base.txt
Werkzeug==1.0.1 # https://github.com/pallets/werkzeug Werkzeug==1.0.1 # https://github.com/pallets/werkzeug
ipdb==0.13.7 # https://github.com/gotcha/ipdb ipdb==0.13.9 # https://github.com/gotcha/ipdb
{%- if cookiecutter.use_docker == 'y' %} {%- if cookiecutter.use_docker == 'y' %}
psycopg2==2.8.6 # https://github.com/psycopg/psycopg2 psycopg2==2.9.1 # https://github.com/psycopg/psycopg2
{%- else %} {%- else %}
psycopg2-binary==2.8.6 # https://github.com/psycopg/psycopg2 psycopg2-binary==2.9.1 # https://github.com/psycopg/psycopg2
{%- endif %} {%- endif %}
{%- if cookiecutter.use_async == 'y' or cookiecutter.use_celery == 'y' %} {%- if cookiecutter.use_async == 'y' or cookiecutter.use_celery == 'y' %}
watchgod==0.6 # https://github.com/samuelcolvin/watchgod watchgod==0.7 # https://github.com/samuelcolvin/watchgod
{%- endif %} {%- endif %}
# Testing # Testing
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
mypy==0.812 # https://github.com/python/mypy mypy==0.902 # https://github.com/python/mypy
django-stubs==1.8.0 # https://github.com/typeddjango/django-stubs django-stubs==1.8.0 # https://github.com/typeddjango/django-stubs
pytest==6.2.3 # https://github.com/pytest-dev/pytest pytest==6.2.4 # https://github.com/pytest-dev/pytest
pytest-sugar==0.9.4 # https://github.com/Frozenball/pytest-sugar pytest-sugar==0.9.4 # https://github.com/Frozenball/pytest-sugar
# Documentation # Documentation
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
sphinx==3.5.4 # https://github.com/sphinx-doc/sphinx sphinx==4.0.2 # https://github.com/sphinx-doc/sphinx
sphinx-autobuild==2021.3.14 # https://github.com/GaretJax/sphinx-autobuild sphinx-autobuild==2021.3.14 # https://github.com/GaretJax/sphinx-autobuild
# Code quality # Code quality
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
flake8==3.9.1 # https://github.com/PyCQA/flake8 flake8==3.9.2 # https://github.com/PyCQA/flake8
flake8-isort==4.0.0 # https://github.com/gforcada/flake8-isort flake8-isort==4.0.0 # https://github.com/gforcada/flake8-isort
coverage==5.5 # https://github.com/nedbat/coveragepy coverage==5.5 # https://github.com/nedbat/coveragepy
black==21.4b2 # https://github.com/ambv/black black==21.6b0 # https://github.com/psf/black
pylint-django==2.4.3 # https://github.com/PyCQA/pylint-django pylint-django==2.4.4 # https://github.com/PyCQA/pylint-django
{%- if cookiecutter.use_celery == 'y' %} {%- if cookiecutter.use_celery == 'y' %}
pylint-celery==0.3 # https://github.com/PyCQA/pylint-celery pylint-celery==0.3 # https://github.com/PyCQA/pylint-celery
{%- endif %} {%- endif %}
pre-commit==2.12.1 # https://github.com/pre-commit/pre-commit pre-commit==2.13.0 # https://github.com/pre-commit/pre-commit
# Django # Django
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
@ -41,5 +41,5 @@ factory-boy==3.2.0 # https://github.com/FactoryBoy/factory_boy
django-debug-toolbar==3.2.1 # https://github.com/jazzband/django-debug-toolbar django-debug-toolbar==3.2.1 # https://github.com/jazzband/django-debug-toolbar
django-extensions==3.1.3 # https://github.com/django-extensions/django-extensions django-extensions==3.1.3 # https://github.com/django-extensions/django-extensions
django-coverage-plugin==1.8.0 # https://github.com/nedbat/django_coverage_plugin django-coverage-plugin==2.0.0 # https://github.com/nedbat/django_coverage_plugin
pytest-django==4.2.0 # https://github.com/pytest-dev/pytest-django pytest-django==4.4.0 # https://github.com/pytest-dev/pytest-django

View File

@ -3,12 +3,12 @@
-r base.txt -r base.txt
gunicorn==20.1.0 # https://github.com/benoitc/gunicorn gunicorn==20.1.0 # https://github.com/benoitc/gunicorn
psycopg2==2.8.6 # https://github.com/psycopg/psycopg2 psycopg2==2.9.1 # https://github.com/psycopg/psycopg2
{%- if cookiecutter.use_whitenoise == 'n' %} {%- if cookiecutter.use_whitenoise == 'n' %}
Collectfast==2.2.0 # https://github.com/antonagestam/collectfast Collectfast==2.2.0 # https://github.com/antonagestam/collectfast
{%- endif %} {%- endif %}
{%- if cookiecutter.use_sentry == "y" %} {%- if cookiecutter.use_sentry == "y" %}
sentry-sdk==1.0.0 # https://github.com/getsentry/sentry-python sentry-sdk==1.1.0 # https://github.com/getsentry/sentry-python
{%- endif %} {%- endif %}
{%- if cookiecutter.use_docker == "n" and cookiecutter.windows == "y" %} {%- if cookiecutter.use_docker == "n" and cookiecutter.windows == "y" %}
hiredis==1.1.0 # https://github.com/redis/hiredis-py hiredis==1.1.0 # https://github.com/redis/hiredis-py
@ -22,21 +22,21 @@ django-storages[boto3]==1.11.1 # https://github.com/jschneier/django-storages
django-storages[google]==1.11.1 # https://github.com/jschneier/django-storages django-storages[google]==1.11.1 # https://github.com/jschneier/django-storages
{%- endif %} {%- endif %}
{%- if cookiecutter.mail_service == 'Mailgun' %} {%- if cookiecutter.mail_service == 'Mailgun' %}
django-anymail[mailgun]==8.2 # https://github.com/anymail/django-anymail django-anymail[mailgun]==8.4 # https://github.com/anymail/django-anymail
{%- elif cookiecutter.mail_service == 'Amazon SES' %} {%- elif cookiecutter.mail_service == 'Amazon SES' %}
django-anymail[amazon_ses]==8.2 # https://github.com/anymail/django-anymail django-anymail[amazon_ses]==8.4 # https://github.com/anymail/django-anymail
{%- elif cookiecutter.mail_service == 'Mailjet' %} {%- elif cookiecutter.mail_service == 'Mailjet' %}
django-anymail[mailjet]==8.2 # https://github.com/anymail/django-anymail django-anymail[mailjet]==8.4 # https://github.com/anymail/django-anymail
{%- elif cookiecutter.mail_service == 'Mandrill' %} {%- elif cookiecutter.mail_service == 'Mandrill' %}
django-anymail[mandrill]==8.2 # https://github.com/anymail/django-anymail django-anymail[mandrill]==8.4 # https://github.com/anymail/django-anymail
{%- elif cookiecutter.mail_service == 'Postmark' %} {%- elif cookiecutter.mail_service == 'Postmark' %}
django-anymail[postmark]==8.2 # https://github.com/anymail/django-anymail django-anymail[postmark]==8.4 # https://github.com/anymail/django-anymail
{%- elif cookiecutter.mail_service == 'Sendgrid' %} {%- elif cookiecutter.mail_service == 'Sendgrid' %}
django-anymail[sendgrid]==8.2 # https://github.com/anymail/django-anymail django-anymail[sendgrid]==8.4 # https://github.com/anymail/django-anymail
{%- elif cookiecutter.mail_service == 'SendinBlue' %} {%- elif cookiecutter.mail_service == 'SendinBlue' %}
django-anymail[sendinblue]==8.2 # https://github.com/anymail/django-anymail django-anymail[sendinblue]==8.4 # https://github.com/anymail/django-anymail
{%- elif cookiecutter.mail_service == 'SparkPost' %} {%- elif cookiecutter.mail_service == 'SparkPost' %}
django-anymail[sparkpost]==8.2 # https://github.com/anymail/django-anymail django-anymail[sparkpost]==8.4 # https://github.com/anymail/django-anymail
{%- elif cookiecutter.mail_service == 'Other SMTP' %} {%- elif cookiecutter.mail_service == 'Other SMTP' %}
django-anymail==8.2 # https://github.com/anymail/django-anymail django-anymail==8.4 # https://github.com/anymail/django-anymail
{%- endif %} {%- endif %}

View File

@ -2,7 +2,7 @@
Module for all Form Tests. Module for all Form Tests.
""" """
import pytest import pytest
from django.utils.translation import ugettext_lazy as _ from django.utils.translation import gettext_lazy as _
from {{ cookiecutter.project_slug }}.users.forms import UserCreationForm from {{ cookiecutter.project_slug }}.users.forms import UserCreationForm
from {{ cookiecutter.project_slug }}.users.models import User from {{ cookiecutter.project_slug }}.users.models import User