Skip to content

Commit 2801a47

Browse files
committed
Updated to Django 5.0.
1 parent 348ce68 commit 2801a47

File tree

5 files changed

+7
-5
lines changed

5 files changed

+7
-5
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ repos:
3535
rev: "1.22.1"
3636
hooks:
3737
- id: django-upgrade
38-
args: [--target-version, "4.2"]
38+
args: [--target-version, "5.0"]
3939
- repo: https://github.com/psf/black
4040
rev: 24.10.0
4141
hooks:

blog/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ class Entry(models.Model):
8383
"publication date must be in the past."
8484
),
8585
)
86-
content_format = models.CharField(choices=ContentFormat.choices, max_length=50)
86+
content_format = models.CharField(choices=ContentFormat, max_length=50)
8787
summary = models.TextField()
8888
summary_html = models.TextField()
8989
body = models.TextField()

djangoproject/settings/common.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,3 +306,5 @@
306306
TRAC_URL = "https://code.djangoproject.com/"
307307

308308
DEFAULT_AUTO_FIELD = "django.db.models.AutoField"
309+
310+
FORMS_URLFIELD_ASSUME_HTTPS = True

members/test_admin.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,12 @@ def test_status_filter(self):
6161
StatusFilter(**filter_args).queryset(request=None, queryset=members),
6262
[self.member],
6363
)
64-
filter_args["params"] = {"status": "inactive"}
64+
filter_args["params"] = {"status": ["inactive"]}
6565
self.assertCountEqual(
6666
StatusFilter(**filter_args).queryset(None, CorporateMember.objects.all()),
6767
[self.inactive_member],
6868
)
69-
filter_args["params"] = {"status": "all"}
69+
filter_args["params"] = {"status": ["all"]}
7070
self.assertCountEqual(
7171
StatusFilter(**filter_args).queryset(None, CorporateMember.objects.all()),
7272
[self.member, self.inactive_member],

requirements/common.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ django-push @ git+https://github.com/brutasse/django-push.git@22fda99641cfbd2f30
77
django-read-only==1.18.0
88
django-recaptcha==4.0.0
99
django-registration-redux==2.13
10-
Django==4.2.16
10+
Django==5.0.9
1111
docutils==0.21.2
1212
feedparser==6.0.11
1313
Jinja2==3.1.4

0 commit comments

Comments
 (0)