Skip to content

Commit 14eb7e8

Browse files
authored
Django 5.2.x version and related dependencies upgrade (#312)
Signed-off-by: tdruez <[email protected]>
1 parent 1391a75 commit 14eb7e8

File tree

171 files changed

+796
-624
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

171 files changed

+796
-624
lines changed

component_catalog/tests/test_admin.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,10 @@ def test_component_admin_form_clean(self):
230230
del data["name"]
231231
response = self.client.post(url, data)
232232
self.assertContains(response, '<p class="errornote">Please correct the error below.</p>')
233-
self.assertContains(response, '<ul class="errorlist"><li>This field is required.</li>')
233+
self.assertContains(
234+
response,
235+
'<ul class="errorlist" id="id_name_error"><li>This field is required.</li></ul>',
236+
)
234237

235238
@override_settings(REFERENCE_DATASPACE="Dataspace")
236239
def test_component_admin_form_clean_validate_against_reference_data(self):

dejacode/settings.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -658,9 +658,8 @@ def get_fake_redis_connection(config, use_strict_redis):
658658
AXES_FAILURE_LIMIT = env.int("AXES_FAILURE_LIMIT", default=5)
659659
# If set, specifies a template to render when a user is locked out.
660660
AXES_LOCKOUT_TEMPLATE = env.str("AXES_LOCKOUT_TEMPLATE", default="axes_lockout.html")
661-
# If True, only lock based on username, and never lock based on IP
662-
# if attempts to exceed the limit.
663-
AXES_ONLY_USER_FAILURES = True
661+
# Lock based on username
662+
AXES_LOCKOUT_PARAMETERS = ["username"]
664663
# If True, a successful login will reset the number of failed logins.
665664
AXES_RESET_ON_SUCCESS = True
666665
# If True, disable writing login and logout access logs to database,

dje/tests/test_access.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ def test_user_locked_out_on_unsuccessful_login_attempts(self):
419419
self.assertEqual(1, attempt.failures_since_start)
420420

421421
response = self.client.post(login_url, data=credentials)
422-
self.assertContains(response, "Account locked", status_code=403)
422+
self.assertContains(response, "Account locked", status_code=429)
423423
attempt = AccessAttempt.objects.get(username=credentials["username"])
424424
self.assertEqual(2, attempt.failures_since_start)
425425

@@ -434,7 +434,7 @@ def test_user_locked_out_on_unsuccessful_login_attempts(self):
434434
self.assertEqual(1, attempt.failures_since_start)
435435

436436
response = self.client.post(login_url, data=credentials)
437-
self.assertContains(response, "Account locked", status_code=403)
437+
self.assertContains(response, "Account locked", status_code=429)
438438
attempt = AccessAttempt.objects.get(username=credentials["username"])
439439
self.assertEqual(2, attempt.failures_since_start)
440440

@@ -457,7 +457,7 @@ def test_notification_on_unsuccessful_login_attempts(self, method_mock):
457457
}
458458
self.client.post(login_url, data=credentials)
459459
response = self.client.post(login_url, data=credentials)
460-
self.assertEqual(403, response.status_code)
460+
self.assertEqual(429, response.status_code)
461461

462462
subject = "[DejaCode] Login attempt on locked account requires review!"
463463
self.assertEqual(1, len(mail.outbox))
@@ -487,7 +487,7 @@ def test_notification_on_unsuccessful_login_attempts(self, method_mock):
487487
response = self.client.post(login_url, data=credentials)
488488
self.assertEqual(200, response.status_code)
489489
response = self.client.post(login_url, data=credentials)
490-
self.assertEqual(403, response.status_code)
490+
self.assertEqual(429, response.status_code)
491491
self.assertIn(
492492
'"real_user" is an existing DejaCode user in Dataspace "nexB"', mail.outbox[2].body
493493
)

docker-compose.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,6 @@ services:
4646
condition: service_started
4747
clamav:
4848
condition: service_started
49-
chown:
50-
condition: service_completed_successfully
5149

5250
worker:
5351
build: .
@@ -65,7 +63,6 @@ services:
6563
- redis
6664
- db
6765
- web
68-
- chown
6966

7067
scheduler:
7168
build: .
@@ -81,7 +78,6 @@ services:
8178
- redis
8279
- db
8380
- web
84-
- chown
8581

8682
nginx:
8783
image: nginx:alpine

setup.cfg

Lines changed: 42 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -47,24 +47,24 @@ include_package_data = true
4747
zip_safe = false
4848
install_requires =
4949
# Base configuration tools
50-
setuptools==75.8.0
50+
setuptools==80.9.0
5151
wheel==0.45.1
52-
pip==25.0.1
52+
pip==25.1.1
5353
# Django
54-
Django==5.1.9
54+
Django==5.2.1
5555
asgiref==3.8.1
56-
typing_extensions==4.12.2
56+
typing_extensions==4.13.2
5757
sqlparse==0.5.3
5858
# Django apps
5959
django-crispy-forms==2.4
6060
crispy_bootstrap5==2025.4
61-
django-grappelli==4.0.1
61+
django-grappelli==4.0.2
6262
django-filter==24.3
6363
django-registration==3.4
6464
confusable_homoglyphs==3.3.1
65-
django-guardian==2.4.0
65+
django-guardian==3.0.0
6666
django-environ==0.12.0
67-
django-debug-toolbar==5.1.0
67+
django-debug-toolbar==5.2.0
6868
# CAPTCHA
6969
altcha==0.1.9
7070
django_altcha==0.1.3
@@ -77,21 +77,19 @@ install_requires =
7777
itypes==1.2.0
7878
Jinja2==3.1.6
7979
uritemplate==4.1.1
80-
# Access log
81-
django-axes==5.35.0
82-
django-appconf==1.1.0
83-
django-ipware==7.0.1
80+
# Track failed login attempts
81+
django-axes==8.0.0
8482
# Multi-factor authentication
85-
django-otp==1.5.4
86-
qrcode==8.0
83+
django-otp==1.6.0
84+
qrcode==8.2
8785
pypng==0.20220715.0
8886
# Database
89-
psycopg==3.2.6
87+
psycopg==3.2.9
9088
# Cache
9189
redis==6.2.0
9290
# redis dependencies:
93-
packaging==24.2
94-
pyparsing==3.2.1
91+
packaging==25.0
92+
pyparsing==3.2.3
9593
async-timeout==5.0.1
9694
Deprecated==1.2.18
9795
wrapt==1.17.2
@@ -100,30 +98,30 @@ install_requires =
10098
# Testing
10199
model_bakery==1.10.1
102100
# Task queue
103-
rq==2.3.2
104-
django-rq==3.0.0
105-
fakeredis==2.27.0
101+
rq==2.3.3
102+
django-rq==3.0.1
103+
fakeredis==2.29.0
106104
# Scheduler
107105
rq-scheduler==0.14.0
108106
crontab==1.0.4
109-
freezegun==1.5.1
107+
freezegun==1.5.2
110108
# Libs
111-
certifi==2025.1.31
112-
urllib3==2.3.0
109+
certifi==2025.4.26
110+
urllib3==2.4.0
113111
python-dateutil==2.9.0.post0
114112
python-mimeparse==2.0.0
115113
PyJWT==2.10.1
116114
natsort==8.4.0
117115
six==1.17.0
118116
requests==2.32.3
119117
idna==3.10
120-
charset-normalizer==3.4.1
118+
charset-normalizer==3.4.2
121119
PyYAML==6.0.2
122-
Cython==3.0.12
123-
zipp==3.21.0
124-
XlsxWriter==3.2.2
120+
cython==3.1.1
121+
zipp==3.22.0
122+
XlsxWriter==3.2.3
125123
# Markdown
126-
Markdown==3.7
124+
markdown==3.8
127125
bleach==6.2.0
128126
bleach_allowlist==1.0.3
129127
webencodings==0.5.1
@@ -135,13 +133,13 @@ install_requires =
135133
# LDAP Auth
136134
python-ldap==3.4.4
137135
pyasn1==0.6.1
138-
pyasn1-modules==0.4.1
139-
django-auth-ldap==5.1.0
136+
pyasn1-modules==0.4.2
137+
django-auth-ldap==5.2.0
140138
# LDAP Testing
141139
mockldap==0.3.0.post1
142140
funcparserlib==0.3.6
143141
# license expressions
144-
boolean.py==4.0
142+
boolean.py==5.0
145143
license-expression==30.4.1
146144
# Webhooks
147145
django-rest-hooks==1.6.1
@@ -151,7 +149,7 @@ install_requires =
151149
swapper==1.4.0
152150
# AboutCode Toolkit
153151
aboutcode_toolkit==11.1.1
154-
click==8.1.8
152+
click==8.2.1
155153
saneyaml==0.6.1
156154
openpyxl==3.1.5
157155
et-xmlfile==2.0.0
@@ -160,14 +158,14 @@ install_requires =
160158
# Gunicorn
161159
gunicorn==23.0.0
162160
# SPDX validation
163-
jsonschema==4.23.0
164-
jsonschema-specifications==2024.10.1
161+
jsonschema==4.24.0
162+
jsonschema-specifications==2025.4.1
165163
referencing==0.36.2
166-
rpds-py==0.22.3
167-
attrs==25.1.0
164+
rpds-py==0.25.1
165+
attrs==25.3.0
168166
pyrsistent==0.20.0
169167
# CycloneDX
170-
cyclonedx-python-lib==9.1.0
168+
cyclonedx-python-lib==10.0.2
171169
sortedcontainers==2.4.0
172170
toml==0.10.2
173171
py-serializable==2.0.0
@@ -176,26 +174,27 @@ install_requires =
176174
gitdb==4.0.12
177175
smmap==5.0.2
178176
# CSAF
179-
pydantic==2.10.6
180-
pydantic-core==2.27.2
181-
maturin==1.8.1
182-
setuptools-rust==1.10.2
177+
pydantic==2.11.5
178+
pydantic-core==2.33.2
179+
typing-inspection==0.4.1
180+
maturin==1.8.6
181+
setuptools-rust==1.11.1
183182
annotated-types==0.7.0
184183
semantic-version==2.10.0
185184

186185
[options.extras_require]
187186
dev =
188187
# Linter and Validation
189-
ruff==0.9.6
188+
ruff==0.11.12
190189
# Documentation
191190
doc8==1.1.2
192-
stevedore==5.4.0
191+
stevedore==5.4.1
193192
Pygments==2.19.1
194193
docutils==0.21.2
195194
restructuredtext-lint==1.4.0
196195
pbr==6.1.1
197196
# Parallel testing
198-
tblib==3.0.0
197+
tblib==3.1.0
199198

200199
[options.entry_points]
201200
console_scripts =
Binary file not shown.
-1.12 MB
Binary file not shown.

thirdparty/dist/Cython-3.0.12-py2.py3-none-any.whl.ABOUT

Lines changed: 0 additions & 15 deletions
This file was deleted.

thirdparty/dist/Markdown-3.7-py3-none-any.whl.ABOUT

Lines changed: 0 additions & 14 deletions
This file was deleted.
-161 KB
Binary file not shown.

0 commit comments

Comments
 (0)