Skip to content

Commit

Permalink
feat!: Python 3.12 Upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
UsamaSadiq committed Oct 25, 2024
1 parent b38870a commit 2bc5f9c
Show file tree
Hide file tree
Showing 16 changed files with 113 additions and 149 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ jobs:
strategy:
matrix:
os:
- ubuntu-20.04
- ubuntu-22.04
python-version:
- 3.11
- 3.12
targets: [ 'quality','main.test','docs' ]

steps:
Expand All @@ -40,7 +40,7 @@ jobs:
&& export TOXENV=django42 && make test.requirements tox.requirements ${{ matrix.targets }}"

- name: Run Coverage
if: matrix.python-version == '3.11' && matrix.targets=='main.test'
if: matrix.python-version == '3.12' && matrix.targets=='main.test'
uses: codecov/codecov-action@v1
with:
fail_ci_if_error: true
4 changes: 2 additions & 2 deletions .github/workflows/mysql8-migrations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-20.04 ]
python-version: [ 3.11 ]
os: [ ubuntu-22.04 ]
python-version: [ 3.12 ]

steps:
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/upgrade-python-requirements.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
uses: openedx/.github/.github/workflows/upgrade-python-requirements.yml@master
with:
branch: ${{ github.event.inputs.branch || 'master' }}
python_version: "3.11"
python_version: "3.12"
# optional parameters below; fill in if you'd like github or email notifications
# user_reviewers: ""
# team_reviewers: ""
Expand Down
4 changes: 2 additions & 2 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
version: 2

build:
os: "ubuntu-20.04"
os: "ubuntu-22.04"
tools:
python: "3.8"
python: "3.12"

# Build documentation in the docs/ directory with Sphinx
sphinx:
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM ubuntu:focal as base

# System requirements.

# ENV variables for Python 3.11 support
# ENV variables for Python 3.12 support
ARG PYTHON_VERSION=3.11
ENV TZ=UTC
ENV TERM=xterm-256color
Expand Down
41 changes: 18 additions & 23 deletions requirements/base.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.11
# This file is autogenerated by pip-compile with Python 3.12
# by the following command:
#
# make upgrade
Expand All @@ -11,9 +11,9 @@ asgiref==3.8.1
# django-countries
boto==2.49.0
# via -r requirements/base.in
boto3==1.35.41
boto3==1.35.48
# via -r requirements/base.in
botocore==1.35.41
botocore==1.35.48
# via
# boto3
# s3transfer
Expand All @@ -31,7 +31,7 @@ coreapi==2.3.3
# via -r requirements/base.in
coreschema==0.0.4
# via coreapi
cryptography==43.0.1
cryptography==43.0.3
# via
# django-fernet-fields-v2
# pyjwt
Expand Down Expand Up @@ -71,10 +71,8 @@ django-model-utils==5.0.0
# via
# edx-enterprise-data
# edx-rbac
django-storages==1.10.1
# via
# -c requirements/constraints.txt
# -r requirements/base.in
django-storages==1.14.4
# via -r requirements/base.in
django-waffle==4.1.0
# via
# edx-django-utils
Expand All @@ -91,32 +89,30 @@ djangorestframework-csv==3.0.2
# via
# -r requirements/base.in
# edx-enterprise-data
dnspython==2.6.1
# via
# -c requirements/constraints.txt
# pymongo
dnspython==2.7.0
# via pymongo
drf-jwt==1.19.2
# via edx-drf-extensions
drf-yasg==1.21.7
drf-yasg==1.21.8
# via edx-api-doc-tools
edx-api-doc-tools==2.0.0
# via -r requirements/base.in
edx-ccx-keys==1.3.0
# via -r requirements/base.in
edx-django-release-util==1.4.0
# via -r requirements/base.in
edx-django-utils==6.1.0
edx-django-utils==7.0.0
# via
# -r requirements/base.in
# edx-drf-extensions
# edx-enterprise-data
# edx-rest-api-client
edx-drf-extensions==10.4.0
edx-drf-extensions==10.5.0
# via
# -r requirements/base.in
# edx-enterprise-data
# edx-rbac
edx-enterprise-data==9.6.0
edx-enterprise-data==10.0.1
# via -r requirements/base.in
edx-opaque-keys==2.11.0
# via
Expand All @@ -132,7 +128,7 @@ edx-rest-api-client==6.0.0
# edx-enterprise-data
factory-boy==3.3.1
# via edx-enterprise-data
faker==30.4.0
faker==30.8.1
# via factory-boy
html5lib==1.1
# via -r requirements/base.in
Expand All @@ -150,25 +146,25 @@ jmespath==1.0.1
# botocore
markdown==3.7
# via -r requirements/base.in
markupsafe==3.0.1
markupsafe==3.0.2
# via jinja2
mysql-connector-python==9.1.0
# via edx-enterprise-data
newrelic==10.2.0
# via edx-django-utils
numpy==1.24.4
numpy==2.1.2
# via
# edx-enterprise-data
# pandas
ordered-set==4.1.0
# via -r requirements/base.in
packaging==24.1
# via drf-yasg
pandas==2.0.3
pandas==2.2.3
# via edx-enterprise-data
pbr==6.1.0
# via stevedore
psutil==6.0.0
psutil==6.1.0
# via edx-django-utils
pycparser==2.22
# via cffi
Expand Down Expand Up @@ -236,9 +232,8 @@ uritemplate==4.1.1
# via
# coreapi
# drf-yasg
urllib3==1.26.20
urllib3==2.2.3
# via
# -c requirements/constraints.txt
# -r requirements/base.in
# botocore
# requests
Expand Down
2 changes: 1 addition & 1 deletion requirements/ci.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.11
# This file is autogenerated by pip-compile with Python 3.12
# by the following command:
#
# make upgrade
Expand Down
10 changes: 0 additions & 10 deletions requirements/constraints.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,11 @@
# TODO: Many pinned dependencies should be unpinned and/or moved to this constraints file.
django<4.3

# django-storages version 1.9 drops support for boto storage backend.
# pinning before django upgrade, will unpin after that
django-storages<1.11 # BSD

# elasticsearch library cannot be greater than 7.14.0. 7.14.0 library is not compatible with the 7.10 server in stage and prod
elasticsearch < 7.14.0

# elasticsearch-dsl depends on elasticsearch >=7.8.0,<8.0.0
elasticsearch-dsl>=7.2.1,<8.0.0

# botocore 1.35.14 has requirement urllib3<1.27,>=1.25.4; python_version < "3.10"
urllib3<2.0.0

# path>16.14.0 has removed the deprecated abspath function, which is breaking the docs build
path<16.15.0

# dnspython 2.7.0 Requires-Python >=3.9
dnspython<2.7.0
43 changes: 19 additions & 24 deletions requirements/dev.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.11
# This file is autogenerated by pip-compile with Python 3.12
# by the following command:
#
# make upgrade
Expand All @@ -11,9 +11,9 @@ asgiref==3.8.1
# django-countries
boto==2.49.0
# via -r requirements/base.in
boto3==1.35.41
boto3==1.35.48
# via -r requirements/base.in
botocore==1.35.41
botocore==1.35.48
# via
# boto3
# s3transfer
Expand All @@ -31,7 +31,7 @@ coreapi==2.3.3
# via -r requirements/base.in
coreschema==0.0.4
# via coreapi
cryptography==43.0.1
cryptography==43.0.3
# via
# django-fernet-fields-v2
# pyjwt
Expand Down Expand Up @@ -71,10 +71,8 @@ django-model-utils==5.0.0
# via
# edx-enterprise-data
# edx-rbac
django-storages==1.10.1
# via
# -c requirements/constraints.txt
# -r requirements/base.in
django-storages==1.14.4
# via -r requirements/base.in
django-waffle==4.1.0
# via
# edx-django-utils
Expand All @@ -91,32 +89,30 @@ djangorestframework-csv==3.0.2
# via
# -r requirements/base.in
# edx-enterprise-data
dnspython==2.6.1
# via
# -c requirements/constraints.txt
# pymongo
dnspython==2.7.0
# via pymongo
drf-jwt==1.19.2
# via edx-drf-extensions
drf-yasg==1.21.7
drf-yasg==1.21.8
# via edx-api-doc-tools
edx-api-doc-tools==2.0.0
# via -r requirements/base.in
edx-ccx-keys==1.3.0
# via -r requirements/base.in
edx-django-release-util==1.4.0
# via -r requirements/base.in
edx-django-utils==6.1.0
edx-django-utils==7.0.0
# via
# -r requirements/base.in
# edx-drf-extensions
# edx-enterprise-data
# edx-rest-api-client
edx-drf-extensions==10.4.0
edx-drf-extensions==10.5.0
# via
# -r requirements/base.in
# edx-enterprise-data
# edx-rbac
edx-enterprise-data==9.6.0
edx-enterprise-data==10.0.1
# via -r requirements/base.in
edx-opaque-keys==2.11.0
# via
Expand All @@ -132,7 +128,7 @@ edx-rest-api-client==6.0.0
# edx-enterprise-data
factory-boy==3.3.1
# via edx-enterprise-data
faker==30.4.0
faker==30.8.1
# via factory-boy
html5lib==1.1
# via -r requirements/base.in
Expand All @@ -150,27 +146,27 @@ jmespath==1.0.1
# botocore
markdown==3.7
# via -r requirements/base.in
markupsafe==3.0.1
markupsafe==3.0.2
# via jinja2
mysql-connector-python==9.1.0
# via edx-enterprise-data
mysqlclient==2.2.4
mysqlclient==2.2.5
# via -r requirements/dev.in
newrelic==10.2.0
# via edx-django-utils
numpy==1.24.4
numpy==2.1.2
# via
# edx-enterprise-data
# pandas
ordered-set==4.1.0
# via -r requirements/base.in
packaging==24.1
# via drf-yasg
pandas==2.0.3
pandas==2.2.3
# via edx-enterprise-data
pbr==6.1.0
# via stevedore
psutil==6.0.0
psutil==6.1.0
# via edx-django-utils
pycparser==2.22
# via cffi
Expand Down Expand Up @@ -238,9 +234,8 @@ uritemplate==4.1.1
# via
# coreapi
# drf-yasg
urllib3==1.26.20
urllib3==2.2.3
# via
# -c requirements/constraints.txt
# -r requirements/base.in
# botocore
# requests
Expand Down
Loading

0 comments on commit 2bc5f9c

Please sign in to comment.