8000 upgrade to Django 4.2 LTS · github/codespaces-django@5fbdccf · GitHub
[go: up one dir, main page]

Skip to content

Commit 5fbdccf

Browse files
committed
upgrade to Django 4.2 LTS
1 parent cd5c033 commit 5fbdccf

File tree

6 files changed

+27
-25
lines changed

6 files changed

+27
-25
lines changed

hello_world/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/4.1/howto/deployment/asgi/
7+
https://docs.djangoproject.com/en/4.2/howto/deployment/asgi/
88
"""
99

1010
import os

hello_world/settings.py

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
"""
22
Django settings for hello_world project.
33
4-
Generated by 'django-admin startproject' using Django 4.1.1.
4+
Generated by 'django-admin startproject' using Django 4.2.11.
55
66
For more information on this file, see
7-
https://docs.djangoproject.com/en/4.1/topics/settings/
7+
https://docs.djangoproject.com/en/4.2/topics/settings/
88
99
For the full list of settings and their values, see
10-
https://docs.djangoproject.com/en/4.1/ref/settings/
10+
https://docs.djangoproject.com/en/4.2/ref/settings/
1111
"""
12+
1213
import os
1314
from pathlib import Path
1415
from dotenv import load_dotenv
@@ -20,7 +21,7 @@
2021

2122

2223
# Quick-start development settings - unsuitable for production
23-
# See https://docs.djangoproject.com/en/4.1/howto/deployment/checklist/
24+
# See https://docs.djangoproject.com/en/4.2/howto/deployment/checklist/
2425

2526
# SECURITY WARNING: keep the secret key used in production secret!
2627
SECRET_KEY = os.getenv("SECRET_KEY")
@@ -82,7 +83,7 @@
8283

8384

8485
# Database
85-
# https://docs.djangoproject.com/en/4.1/ref/settings/#databases
86+
# https://docs.djangoproject.com/en/4.2/ref/settings/#databases
8687

8788
DATABASES = {
8889
"default": {
@@ -93,7 +94,7 @@
9394

9495

9596
# Password validation
96-
# https://docs.djangoproject.com/en/4.1/ref/settings/#auth-password-validators
97+
# https://docs.djangoproject.com/en/4.2/ref/settings/#auth-password-validators
9798

9899
AUTH_PASSWORD_VALIDATORS = [
99100
{
@@ -112,7 +113,7 @@
112113

113114

114115
# Internationalization
115-
# https://docs.djangoproject.com/en/4.1/topics/i18n/
116+
# https://docs.djangoproject.com/en/4.2/topics/i18n/
116117

117118
LANGUAGE_CODE = "en-us"
118119

@@ -124,7 +125,7 @@
124125

125126

126127
# Static files (CSS, JavaScript, Images)
127-
# https://docs.djangoproject.com/en/4.1/howto/static-files/
128+
# https://docs.djangoproject.com/en/4.2/howto/static-files/
128129

129130
STATICFILES_DIRS = [
130131
BASE_DIR / "hello_world" / "static",
@@ -138,6 +139,6 @@
138139

139140

140141
# Default primary key field type
141-
# https://docs.djangoproject.com/en/4.1/ref/settings/#default-auto-field
142+
# https://docs.djangoproject.com/en/4.2/ref/settings/#default-auto-field
142143

143144
DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField"

hello_world/urls.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
"""hello_world URL Configuration
1+
"""
2+
URL configuration for hello_world project.
23
34
The `urlpatterns` list routes URLs to views. For more information please see:
4-
https://docs.djangoproject.com/en/4.1/topics/http/urls/
5+
https://docs.djangoproject.com/en/4.2/topics/http/urls/
56
Examples:
67
Function views
78
1. Add an import: from my_app import views
@@ -13,6 +14,7 @@
1314
1. Import the include() function: from django.urls import include, path
1415
2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
1516
"""
17+
1618
from django.contrib import admin
1719
from django.urls import path, include
1820
from django.conf import settings

hello_world/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/4.1/howto/deployment/wsgi/
7+
https://docs.djangoproject.com/en/4.2/howto/deployment/wsgi/
88
"""
99

1010
import os

manage.py

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,18 @@
33
import os
44
import sys
55

6-
try:
7-
from django.core.management import execute_from_command_line
8-
except ImportError as exc:
9-
raise ImportError(
10-
"Couldn't import Django. Are you sure it's installed and "
11-
"available on your PYTHONPATH environment variable? Did you "
12-
"forget to activate a virtual environment?"
13-
) from exc
14-
156

167
def main():
178
"""Run administrative tasks."""
189
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "hello_world.settings")
10+
try:
11+
from django.core.management import execute_from_command_line
12+
except ImportError as exc:
13+
raise ImportError(
14+
"Couldn't import Django. Are you sure it's installed and "
15+
"available on your PYTHONPATH environment variable? Did you "
16+
"forget to activate a virtual environment?"
17+
) from exc
1918
execute_from_command_line(sys.argv)
2019

2120

requirements.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
Django==4.1.13
2-
django-browser-reload==1.6.0
3-
python-dotenv==1.0.0
1+
Django==4.2.11
2+
django-browser-reload==1.12.1
3+
python-dotenv==1.0.1

0 commit comments

Comments
 (0)
0