Skip to content

Commit 461f1ac

Browse files

File tree

7 files changed

+26
-27
lines changed

7 files changed

+26
-27
lines changed

Procfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ web: gunicorn --config gunicorn.conf.py gettingstarted.wsgi
22

33
# Uncomment this `release` process if you are using a database, so that Django's model
44
# migrations are run as part of app deployment, using Heroku's Release Phase feature:
5-
# https://docs.djangoproject.com/en/5.1/topics/migrations/
5+
# https://docs.djangoproject.com/en/5.2/topics/migrations/
66
# https://devcenter.heroku.com/articles/release-phase
77
#release: ./manage.py migrate --no-input

gettingstarted/asgi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
It exposes the ASGI callable as a module-level variable named ``application``.
55
66
For more information on this file, see
7-
https://docs.djangoproject.com/en/5.1/howto/deployment/asgi/
7+
https://docs.djangoproject.com/en/5.2/howto/deployment/asgi/
88
"""
99

1010
import os

gettingstarted/settings.py

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
"""
22
Django settings for gettingstarted project.
33
4-
Generated by 'django-admin startproject' using Django 5.1.
4+
Generated by 'django-admin startproject' using Django 5.2.
55
66
For more information on this file, see
7-
https://docs.djangoproject.com/en/5.1/topics/settings/
7+
https://docs.djangoproject.com/en/5.2/topics/settings/
88
99
For the full list of settings and their values, see
10-
https://docs.djangoproject.com/en/5.1/ref/settings/
10+
https://docs.djangoproject.com/en/5.2/ref/settings/
1111
"""
1212

1313
import os
@@ -21,15 +21,15 @@
2121

2222

2323
# Before using your Heroku app in production, make sure to review Django's deployment checklist:
24-
# See https://docs.djangoproject.com/en/5.1/howto/deployment/checklist/
24+
# See https://docs.djangoproject.com/en/5.2/howto/deployment/checklist/
2525

2626
# Django requires a unique secret key for each Django app, that is used by several of its
2727
# security features. To simplify initial setup (without hardcoding the secret in the source
2828
# code) we set this to a random value every time the app starts. However, this will mean many
2929
# Django features break whenever an app restarts (for example, sessions will be logged out).
3030
# In your production Heroku apps you should set the `DJANGO_SECRET_KEY` config var explicitly.
3131
# Make sure to use a long unique value, like you would for a password. See:
32-
# https://docs.djangoproject.com/en/5.1/ref/settings/#std-setting-SECRET_KEY
32+
# https://docs.djangoproject.com/en/5.2/ref/settings/#std-setting-SECRET_KEY
3333
# https://devcenter.heroku.com/articles/config-vars
3434
# SECURITY WARNING: Keep the secret key used in production secret!
3535
SECRET_KEY = os.environ.get(
@@ -40,7 +40,7 @@
4040
# Django has a debug mode which shows more detailed error messages and also means static assets
4141
# can be served without having to run the production `collectstatic` command. However, this
4242
# debug mode *must only be enabled in development* for security and performance reasons:
43-
# https://docs.djangoproject.com/en/5.1/ref/settings/#std-setting-DEBUG
43+
# https://docs.djangoproject.com/en/5.2/ref/settings/#std-setting-DEBUG
4444
# Debug mode will be automatically enabled when the project is run via `heroku local` (which
4545
# loads the environment variables set in the `.env` file, where `ENVIRONMENT=development`).
4646
# SECURITY WARNING: Don't run with debug turned on in production!
@@ -55,7 +55,7 @@
5555
# On Heroku, it's safe to use a wildcard for `ALLOWED_HOSTS`, since the Heroku router performs
5656
# validation of the Host header in the incoming HTTP request. On other platforms you may need to
5757
# list the expected hostnames explicitly in production to prevent HTTP Host header attacks. See:
58-
# https://docs.djangoproject.com/en/5.1/ref/settings/#std-setting-ALLOWED_HOSTS
58+
# https://docs.djangoproject.com/en/5.2/ref/settings/#std-setting-ALLOWED_HOSTS
5959
ALLOWED_HOSTS = ["*"]
6060

6161
# Redirect all non-HTTPS requests to HTTPS. This requires that:
@@ -67,7 +67,7 @@
6767
# app's `gunicorn.conf.py` for how this is done when using gunicorn.
6868
#
6969
# For maximum security, consider enabling HTTP Strict Transport Security (HSTS) headers too:
70-
# https://docs.djangoproject.com/en/5.1/ref/middleware/#http-strict-transport-security
70+
# https://docs.djangoproject.com/en/5.2/ref/middleware/#http-strict-transport-security
7171
SECURE_SSL_REDIRECT = True
7272
else:
7373
ALLOWED_HOSTS = [".localhost", "127.0.0.1", "[::1]", "0.0.0.0", "[::]"]
@@ -78,11 +78,11 @@
7878
# Several optional Django features that are present in the default `startproject` template have
7979
# been disabled since they are not used by this example app. To use them, uncomment the relevant
8080
# entries in `INSTALLED_APPS`, `MIDDLEWARE`, `TEMPLATES` and `urls.py`. See:
81-
# https://docs.djangoproject.com/en/5.1/ref/contrib/admin/
82-
# https://docs.djangoproject.com/en/5.1/topics/auth/
83-
# https://docs.djangoproject.com/en/5.1/ref/contrib/contenttypes/
84-
# https://docs.djangoproject.com/en/5.1/topics/http/sessions/
85-
# https://docs.djangoproject.com/en/5.1/ref/contrib/messages/
81+
# https://docs.djangoproject.com/en/5.2/ref/contrib/admin/
82+
# https://docs.djangoproject.com/en/5.2/topics/auth/
83+
# https://docs.djangoproject.com/en/5.2/ref/contrib/contenttypes/
84+
# https://docs.djangoproject.com/en/5.2/topics/http/sessions/
85+
# https://docs.djangoproject.com/en/5.2/ref/contrib/messages/
8686
INSTALLED_APPS = [
8787
# Use WhiteNoise's runserver implementation instead of the Django default, for dev-prod parity.
8888
"whitenoise.runserver_nostatic",
@@ -119,7 +119,6 @@
119119
"APP_DIRS": True,
120120
"OPTIONS": {
121121
"context_processors": [
122-
"django.template.context_processors.debug",
123122
"django.template.context_processors.request",
124123
# "django.contrib.auth.context_processors.auth",
125124
# "django.contrib.messages.context_processors.messages",
@@ -132,7 +131,7 @@
132131

133132

134133
# Database
135-
# https://docs.djangoproject.com/en/5.1/ref/settings/#databases
134+
# https://docs.djangoproject.com/en/5.2/ref/settings/#databases
136135

137136
if IS_HEROKU_APP:
138137
# In production on Heroku the database configuration is derived from the `DATABASE_URL`
@@ -160,7 +159,7 @@
160159

161160

162161
# Password validation
163-
# https://docs.djangoproject.com/en/5.1/ref/settings/#auth-password-validators
162+
# https://docs.djangoproject.com/en/5.2/ref/settings/#auth-password-validators
164163

165164
AUTH_PASSWORD_VALIDATORS = [
166165
{
@@ -179,7 +178,7 @@
179178

180179

181180
# Internationalization
182-
# https://docs.djangoproject.com/en/5.1/topics/i18n/
181+
# https://docs.djangoproject.com/en/5.2/topics/i18n/
183182

184183
LANGUAGE_CODE = "en-us"
185184

@@ -191,7 +190,7 @@
191190

192191

193192
# Static files (CSS, JavaScript, Images)
194-
# https://docs.djangoproject.com/en/5.1/howto/static-files/
193+
# https://docs.djangoproject.com/en/5.2/howto/static-files/
195194

196195
STATIC_ROOT = BASE_DIR / "staticfiles"
197196
STATIC_URL = "static/"
@@ -210,13 +209,13 @@
210209

211210

212211
# Default primary key field type
213-
# https://docs.djangoproject.com/en/5.1/ref/settings/#default-auto-field
212+
# https://docs.djangoproject.com/en/5.2/ref/settings/#default-auto-field
214213

215214
DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField"
216215

217216
# Customise the default logging config, since by default full Django logs are only emitted when
218217
# `DEBUG=True` (which otherwise makes diagnosing errors much harder in production):
219-
# https://docs.djangoproject.com/en/5.1/ref/logging/#default-logging-configuration
218+
# https://docs.djangoproject.com/en/5.2/ref/logging/#default-logging-configuration
220219
# For more advanced logging you may want to try: https://django-structlog.readthedocs.io
221220
LOGGING = {
222221
"version": 1,

gettingstarted/urls.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
URL configuration for gettingstarted project.
33
44
The `urlpatterns` list routes URLs to views. For more information please see:
5-
https://docs.djangoproject.com/en/5.1/topics/http/urls/
5+
https://docs.djangoproject.com/en/5.2/topics/http/urls/
66
Examples:
77
Function views
88
1. Add an import: from my_app import views
@@ -24,6 +24,6 @@
2424
path("", hello.views.index, name="index"),
2525
path("db/", hello.views.db, name="db"),
2626
# Uncomment this and the entry in `INSTALLED_APPS` if you wish to use the Django admin feature:
27-
# https://docs.djangoproject.com/en/5.1/ref/contrib/admin/
27+
# https://docs.djangoproject.com/en/5.2/ref/contrib/admin/
2828
# path("admin/", admin.site.urls),
2929
]

gettingstarted/wsgi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
It exposes the WSGI callable as a module-level variable named ``application``.
55
66
For more information on this file, see
7-
https://docs.djangoproject.com/en/5.1/howto/deployment/wsgi/
7+
https://docs.djangoproject.com/en/5.2/howto/deployment/wsgi/
88
"""
99

1010
import os

hello/migrations/0001_initial.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Generated by Django 5.1 on 2024-08-09 09:38
1+
# Generated by Django 5.2 on 2025-04-06 14:54
22

33
from django.db import migrations, models
44

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
django>=5.1,<5.2
1+
django>=5.2,<5.3
22
gunicorn>=23,<24
33
dj-database-url>=2,<3
44
whitenoise[brotli]>=6,<7

0 commit comments

Comments
 (0)