Skip to content

Commit e04fe7e

Browse files
committed
build: Upgrade django-stubs even further, to fix mypy
Rather than constraining django-stubs' major version to our django major version (4.x.x), we are going to go one ahead (5.x.x), as recommended by python/mypy#17958 Also includes an unrelated common_constraints update.
1 parent 41c25cf commit e04fe7e

File tree

9 files changed

+22
-11
lines changed

9 files changed

+22
-11
lines changed

requirements/common_constraints.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,7 @@ elasticsearch<7.14.0
2828
# Cause: https://github.com/openedx/edx-lint/issues/458
2929
# This can be unpinned once https://github.com/openedx/edx-lint/issues/459 has been resolved.
3030
pip<24.3
31+
32+
# Cause: https://github.com/openedx/edx-lint/issues/475
33+
# This can be unpinned once https://github.com/openedx/edx-lint/issues/476 has been resolved.
34+
urllib3<2.3.0

requirements/constraints.txt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,13 @@ django-webpack-loader==0.7.0
6161
djangorestframework<3.15.0
6262

6363
# Date: 2024-07-19
64-
# Generally speaking, the major version of django-stubs should match the major version of django.
65-
# Specifically, we need to perpetually constrain django-stubs to a compatible version based on:
64+
# Generally speaking, the major version of django-stubs either match the major version
65+
# of django, or exceed it by 1. So, we will need toperpetually constrain django-stubs and
66+
# update it as we perform django upgrades. For more details, see:
6667
# https://github.com/typeddjango/django-stubs?tab=readme-ov-file#version-compatibility
68+
# including the note on "Partial Support".
6769
# Issue: https://github.com/openedx/edx-platform/issues/35275
68-
django-stubs<5
70+
django-stubs<6
6971

7072
# Date: 2024-07-23
7173
# django-storages==1.14.4 breaks course imports

requirements/edx/base.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1212,6 +1212,7 @@ uritemplate==4.1.1
12121212
# google-api-python-client
12131213
urllib3==2.2.3
12141214
# via
1215+
# -c requirements/edx/../common_constraints.txt
12151216
# botocore
12161217
# elasticsearch
12171218
# py2neo

requirements/edx/development.txt

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ asgiref==3.8.1
7676
# django
7777
# django-cors-headers
7878
# django-countries
79+
# django-stubs
7980
asn1crypto==1.5.1
8081
# via
8182
# -r requirements/edx/doc.txt
@@ -577,7 +578,7 @@ django-storages==1.14.3
577578
# -r requirements/edx/doc.txt
578579
# -r requirements/edx/testing.txt
579580
# edxval
580-
django-stubs==4.2.7
581+
django-stubs==5.1.1
581582
# via
582583
# -c requirements/edx/../constraints.txt
583584
# -r requirements/edx/development.in
@@ -625,7 +626,7 @@ djangorestframework==3.14.0
625626
# openedx-learning
626627
# ora2
627628
# super-csv
628-
djangorestframework-stubs==3.14.5
629+
djangorestframework-stubs==3.15.2
629630
# via -r requirements/edx/development.in
630631
djangorestframework-xml==2.0.0
631632
# via
@@ -1292,9 +1293,7 @@ multidict==6.1.0
12921293
# aiohttp
12931294
# yarl
12941295
mypy==1.14.1
1295-
# via
1296-
# -c requirements/edx/../constraints.txt
1297-
# -r requirements/edx/development.in
1296+
# via -r requirements/edx/development.in
12981297
mypy-extensions==1.0.0
12991298
# via mypy
13001299
mysqlclient==2.2.6
@@ -2118,8 +2117,6 @@ tqdm==4.67.1
21182117
# -r requirements/edx/testing.txt
21192118
# nltk
21202119
# openai
2121-
types-pytz==2024.2.0.20241003
2122-
# via django-stubs
21232120
types-pyyaml==6.0.12.20240917
21242121
# via
21252122
# django-stubs
@@ -2170,6 +2167,7 @@ uritemplate==4.1.1
21702167
# google-api-python-client
21712168
urllib3==2.2.3
21722169
# via
2170+
# -c requirements/edx/../common_constraints.txt
21732171
# -r requirements/edx/doc.txt
21742172
# -r requirements/edx/testing.txt
21752173
# botocore

requirements/edx/doc.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1526,6 +1526,7 @@ uritemplate==4.1.1
15261526
# google-api-python-client
15271527
urllib3==2.2.3
15281528
# via
1529+
# -c requirements/edx/../common_constraints.txt
15291530
# -r requirements/edx/base.txt
15301531
# botocore
15311532
# elasticsearch

requirements/edx/semgrep.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@ typing-extensions==4.12.2
126126
# semgrep
127127
urllib3==2.2.3
128128
# via
129+
# -c requirements/edx/../common_constraints.txt
129130
# requests
130131
# semgrep
131132
wcmatch==8.5.2

requirements/edx/testing.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1612,6 +1612,7 @@ uritemplate==4.1.1
16121612
# google-api-python-client
16131613
urllib3==2.2.3
16141614
# via
1615+
# -c requirements/edx/../common_constraints.txt
16151616
# -r requirements/edx/base.txt
16161617
# botocore
16171618
# elasticsearch

scripts/user_retirement/requirements/base.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,7 @@ uritemplate==4.1.1
158158
# via google-api-python-client
159159
urllib3==1.26.20
160160
# via
161+
# -c scripts/user_retirement/requirements/../../../requirements/common_constraints.txt
161162
# -r scripts/user_retirement/requirements/base.in
162163
# botocore
163164
# requests

scripts/xblock/requirements.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,6 @@ idna==3.10
1515
requests==2.32.3
1616
# via -r scripts/xblock/requirements.in
1717
urllib3==2.2.3
18-
# via requests
18+
# via
19+
# -c scripts/xblock/../../requirements/common_constraints.txt
20+
# requests

0 commit comments

Comments
 (0)