From 5a2629e971e14483232b18fd4746f6cc360bb299 Mon Sep 17 00:00:00 2001 From: Muhammad Umar Khan Date: Thu, 18 Apr 2024 14:54:51 +0500 Subject: [PATCH] feat: add python 3.11 support --- .github/workflows/ci.yml | 2 +- .github/workflows/mysql8-migrations-check.yml | 2 +- requirements/base.txt | 3 ++- requirements/constraints.txt | 7 +++++-- requirements/dev.txt | 3 ++- requirements/doc.txt | 3 ++- requirements/production.txt | 3 ++- requirements/quality.txt | 3 ++- requirements/test.txt | 3 ++- requirements/validation.txt | 3 ++- 10 files changed, 21 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b2578f84..bba6c40a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.8"] + python-version: ["3.8", "3.11"] django-version: ["pinned"] steps: - uses: actions/checkout@v2 diff --git a/.github/workflows/mysql8-migrations-check.yml b/.github/workflows/mysql8-migrations-check.yml index 13fce240..b9348156 100644 --- a/.github/workflows/mysql8-migrations-check.yml +++ b/.github/workflows/mysql8-migrations-check.yml @@ -53,7 +53,7 @@ jobs: pip uninstall -y mysqlclient pip install --no-binary mysqlclient mysqlclient pip uninstall -y xmlsec - pip install --no-binary xmlsec xmlsec + pip install --no-binary xmlsec xmlsec==1.3.13 - name: Initiate services run: | sudo /etc/init.d/mysql start diff --git a/requirements/base.txt b/requirements/base.txt index 1ecbbfa5..0a160676 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -23,8 +23,9 @@ backoff==1.10.0 # via # -r requirements/base.in # analytics-python -backports-zoneinfo[tzdata]==0.2.1 +backports-zoneinfo[tzdata]==0.2.1 ; python_version < "3.9" # via + # -c requirements/constraints.txt # celery # django # djangorestframework diff --git a/requirements/constraints.txt b/requirements/constraints.txt index a1a6a6a0..90106df7 100644 --- a/requirements/constraints.txt +++ b/requirements/constraints.txt @@ -24,7 +24,10 @@ edx-lint<5.3 pylint<2.15 astroid<2.12 -# Stay on LTS release -# This can be removed once all IDAs have been upgraded to Django 4.2 +# Stay on LTS release +# This can be removed once all IDAs have been upgraded to Django 4.2 # and the global constraint has been updated from Django<4.0 to Django<4.3 Django<4.3 + +# For python greater than or equal to 3.9 backports.zoneinfo is causing failures +backports.zoneinfo;python_version<"3.9" diff --git a/requirements/dev.txt b/requirements/dev.txt index c63351d8..1ca48765 100644 --- a/requirements/dev.txt +++ b/requirements/dev.txt @@ -35,8 +35,9 @@ backoff==1.10.0 # via # -r requirements/validation.txt # analytics-python -backports-zoneinfo[tzdata]==0.2.1 +backports-zoneinfo[tzdata]==0.2.1 ; python_version < "3.9" # via + # -c requirements/constraints.txt # -r requirements/validation.txt # celery # django diff --git a/requirements/doc.txt b/requirements/doc.txt index cca72fd3..a0a0b5a5 100644 --- a/requirements/doc.txt +++ b/requirements/doc.txt @@ -43,8 +43,9 @@ backoff==1.10.0 # via # -r requirements/test.txt # analytics-python -backports-zoneinfo[tzdata]==0.2.1 +backports-zoneinfo[tzdata]==0.2.1 ; python_version < "3.9" # via + # -c requirements/constraints.txt # -r requirements/test.txt # celery # django diff --git a/requirements/production.txt b/requirements/production.txt index d8731d6e..3d5f3070 100644 --- a/requirements/production.txt +++ b/requirements/production.txt @@ -29,8 +29,9 @@ backoff==1.10.0 # via # -r requirements/base.txt # analytics-python -backports-zoneinfo[tzdata]==0.2.1 +backports-zoneinfo[tzdata]==0.2.1 ; python_version < "3.9" # via + # -c requirements/constraints.txt # -r requirements/base.txt # celery # django diff --git a/requirements/quality.txt b/requirements/quality.txt index 474ab17d..3bf5c333 100644 --- a/requirements/quality.txt +++ b/requirements/quality.txt @@ -34,8 +34,9 @@ backoff==1.10.0 # via # -r requirements/base.txt # analytics-python -backports-zoneinfo[tzdata]==0.2.1 +backports-zoneinfo[tzdata]==0.2.1 ; python_version < "3.9" # via + # -c requirements/constraints.txt # -r requirements/base.txt # celery # django diff --git a/requirements/test.txt b/requirements/test.txt index 782214b8..8f784f9b 100644 --- a/requirements/test.txt +++ b/requirements/test.txt @@ -34,9 +34,10 @@ backoff==1.10.0 # via # -r requirements/base.txt # analytics-python -backports-zoneinfo[tzdata]==0.2.1 +backports-zoneinfo[tzdata]==0.2.1 ; python_version < "3.9" # via # -r requirements/base.txt + # -c requirements/constraints.txt # celery # django # djangorestframework diff --git a/requirements/validation.txt b/requirements/validation.txt index 669df1f6..2c43744a 100644 --- a/requirements/validation.txt +++ b/requirements/validation.txt @@ -43,8 +43,9 @@ backoff==1.10.0 # -r requirements/quality.txt # -r requirements/test.txt # analytics-python -backports-zoneinfo[tzdata]==0.2.1 +backports-zoneinfo[tzdata]==0.2.1 ; python_version < "3.9" # via + # -c requirements/constraints.txt # -r requirements/quality.txt # -r requirements/test.txt # celery