diff --git a/.github/workflows/bumpversion.yml b/.github/workflows/bumpversion.yml index 3a3f9b8..e133ab3 100644 --- a/.github/workflows/bumpversion.yml +++ b/.github/workflows/bumpversion.yml @@ -22,10 +22,10 @@ jobs: default_bump: false default_prerelease_bump: false dry_run: true - - name: Set up Python 3.8 + - name: Set up Python 3.11 uses: actions/setup-python@v5 with: - python-version: "3.8" + python-version: "3.11" - name: Create bumpversion if: steps.tag_version.outputs.new_version run: | diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index 37d92d2..34c1ade 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -25,7 +25,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v5 with: - python-version: '3.10' + python-version: '3.11' - name: Install dependencies run: | python -m pip install --upgrade pip diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d34c260..bd8ae2b 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -11,7 +11,7 @@ jobs: strategy: max-parallel: 2 matrix: - python-version: ["3.8", "3.11"] + python-version: ["3.11"] django: ["42"] steps: diff --git a/CHANGELOG.md b/CHANGELOG.md index 8808743..a32b518 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,14 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [v9.0.0](https://github.com/eduNEXT/eox-theming/compare/v8.1.0...v9.0.0) - (2025-02-04) + +### Changed + +* Removed support for Python 3.8. +* Replaced deprecated `pkg_resources` with `importlib.resources` for better compatibility with newer Django and Python versions. +* Starting with this version, this package is no longer compatible with releases older than Redwood. + ## [v8.1.0](https://github.com/eduNEXT/eox-theming/compare/v8.0.0...v8.1.0) - (2024-11-27) ### Changed diff --git a/README.rst b/README.rst index 4377356..cadc268 100644 --- a/README.rst +++ b/README.rst @@ -40,7 +40,7 @@ Compatibility Notes +------------------+---------------+ | Palm | >= 6.0 < 8.0 | +------------------+---------------+ -| Quince | >= 7.0 | +| Quince | >= 7.0 < 9.0 | +------------------+---------------+ | Redwood | >= 7.2.0 | +------------------+---------------+ diff --git a/eox_theming/__init__.py b/eox_theming/__init__.py index 3f7ec08..68a5b25 100644 --- a/eox_theming/__init__.py +++ b/eox_theming/__init__.py @@ -4,4 +4,4 @@ from __future__ import unicode_literals -__version__ = '8.1.0' +__version__ = '9.0.0' diff --git a/eox_theming/theming/paths.py b/eox_theming/theming/paths.py index 12d739c..f3879dc 100644 --- a/eox_theming/theming/paths.py +++ b/eox_theming/theming/paths.py @@ -4,10 +4,10 @@ See: common.djangoapps.edxmako.paths """ +import importlib.resources import os import re -import pkg_resources from django.conf import settings from mako.exceptions import TopLevelLookupException @@ -91,7 +91,7 @@ def add_lookup(namespace, directory, package=None, prepend=False): encoding_errors='replace', ) if package: - directory = pkg_resources.resource_filename(package, directory) + directory = importlib.resources.files(package) / directory templates.add_directory(directory, prepend=prepend) diff --git a/requirements/base.txt b/requirements/base.txt index 707855e..b2219a1 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -1,24 +1,18 @@ # -# This file is autogenerated by pip-compile with Python 3.8 +# This file is autogenerated by pip-compile with Python 3.11 # by the following command: # # make upgrade # asgiref==3.8.1 # via django -backports-zoneinfo==0.2.1 ; python_version < "3.9" - # via - # -c requirements/constraints.txt - # django -django==4.2.16 +django==4.2.18 # via # -c https://raw.githubusercontent.com/openedx/edx-lint/master/edx_lint/files/common_constraints.txt # -r requirements/base.in -eox-tenant==12.1.0 +eox-tenant==13.0.0 # via -r requirements/base.in -six==1.16.0 +six==1.17.0 # via -r requirements/base.in -sqlparse==0.5.2 +sqlparse==0.5.3 # via django -typing-extensions==4.12.2 - # via asgiref diff --git a/requirements/constraints.txt b/requirements/constraints.txt index 25e4da6..d81d1df 100644 --- a/requirements/constraints.txt +++ b/requirements/constraints.txt @@ -10,6 +10,3 @@ # Common constraints for Open edX repos -c https://raw.githubusercontent.com/openedx/edx-lint/master/edx_lint/files/common_constraints.txt - -# backports.zoneinfo is only needed for Python < 3.9 -backports.zoneinfo; python_version<'3.9' diff --git a/requirements/django42.txt b/requirements/django42.txt index 64aaf99..697db5b 100644 --- a/requirements/django42.txt +++ b/requirements/django42.txt @@ -1 +1 @@ -django==4.2.16 +django==4.2.18 diff --git a/requirements/pip-tools.txt b/requirements/pip-tools.txt index 24fe753..5461e43 100644 --- a/requirements/pip-tools.txt +++ b/requirements/pip-tools.txt @@ -1,15 +1,13 @@ # -# This file is autogenerated by pip-compile with Python 3.8 +# This file is autogenerated by pip-compile with Python 3.11 # by the following command: # # make upgrade # build==1.2.2.post1 # via pip-tools -click==8.1.7 +click==8.1.8 # via pip-tools -importlib-metadata==8.5.0 - # via build packaging==24.2 # via build pip-tools==7.4.1 @@ -18,14 +16,8 @@ pyproject-hooks==1.2.0 # via # build # pip-tools -tomli==2.1.0 - # via - # build - # pip-tools wheel==0.45.1 # via pip-tools -zipp==3.20.2 - # via importlib-metadata # The following packages are considered to be unsafe in a requirements file: # pip diff --git a/requirements/test.txt b/requirements/test.txt index ed2a1cc..8650877 100644 --- a/requirements/test.txt +++ b/requirements/test.txt @@ -1,5 +1,5 @@ # -# This file is autogenerated by pip-compile with Python 3.8 +# This file is autogenerated by pip-compile with Python 3.11 # by the following command: # # make upgrade @@ -8,21 +8,15 @@ asgiref==3.8.1 # via # -r requirements/base.txt # django -astroid==3.2.4 +astroid==3.3.8 # via # -r requirements/test.in # pylint -backports-zoneinfo==0.2.1 ; python_version < "3.9" - # via - # -c requirements/constraints.txt - # -r requirements/base.txt - # django - # djangorestframework -certifi==2024.8.30 +certifi==2025.1.31 # via requests -charset-normalizer==3.4.0 +charset-normalizer==3.4.1 # via requests -coverage==7.6.1 +coverage==7.6.10 # via -r requirements/test.in dill==0.3.9 # via pylint @@ -33,19 +27,17 @@ dill==0.3.9 # djangorestframework djangorestframework==3.15.2 # via -r requirements/test.in -eox-tenant==12.1.0 +eox-tenant==13.0.0 # via -r requirements/base.txt -exceptiongroup==1.2.2 - # via pytest idna==3.10 # via requests iniconfig==2.0.0 # via pytest -isort==5.13.2 +isort==6.0.0 # via pylint -mako==1.3.6 +mako==1.3.9 # via -r requirements/test.in -markupsafe==2.1.5 +markupsafe==3.0.2 # via mako mccabe==0.7.0 # via pylint @@ -53,7 +45,7 @@ mock==5.1.0 # via -r requirements/test.in packaging==24.2 # via pytest -path==17.0.0 +path==17.1.0 # via path-py path-py==12.5.0 # via -r requirements/test.in @@ -63,9 +55,9 @@ pluggy==1.5.0 # via pytest pycodestyle==2.12.1 # via -r requirements/test.in -pylint==3.2.7 +pylint==3.3.4 # via -r requirements/test.in -pytest==8.3.3 +pytest==8.3.4 # via # -r requirements/test.in # pytest-django @@ -75,25 +67,17 @@ pyyaml==6.0.2 # via -r requirements/test.in requests==2.32.3 # via -r requirements/test.in -six==1.16.0 +six==1.17.0 # via -r requirements/base.txt -sqlparse==0.5.2 +sqlparse==0.5.3 # via # -r requirements/base.txt # django testfixtures==8.3.0 # via -r requirements/test.in -tomli==2.1.0 - # via - # pylint - # pytest tomlkit==0.13.2 # via pylint -typing-extensions==4.12.2 - # via - # -r requirements/base.txt - # asgiref - # astroid - # pylint urllib3==2.2.3 - # via requests + # via + # -c https://raw.githubusercontent.com/openedx/edx-lint/master/edx_lint/files/common_constraints.txt + # requests diff --git a/requirements/tox.txt b/requirements/tox.txt index 67daf78..aebf440 100644 --- a/requirements/tox.txt +++ b/requirements/tox.txt @@ -1,10 +1,10 @@ # -# This file is autogenerated by pip-compile with Python 3.8 +# This file is autogenerated by pip-compile with Python 3.11 # by the following command: # # make upgrade # -cachetools==5.5.0 +cachetools==5.5.1 # via tox chardet==5.2.0 # via tox @@ -12,7 +12,7 @@ colorama==0.4.6 # via tox distlib==0.3.9 # via virtualenv -filelock==3.16.1 +filelock==3.17.0 # via # tox # virtualenv @@ -26,15 +26,9 @@ platformdirs==4.3.6 # virtualenv pluggy==1.5.0 # via tox -pyproject-api==1.8.0 +pyproject-api==1.9.0 # via tox -tomli==2.1.0 - # via - # pyproject-api - # tox -tox==4.23.2 +tox==4.24.1 # via -r requirements/tox.in -typing-extensions==4.12.2 - # via tox -virtualenv==20.28.0 +virtualenv==20.29.1 # via tox diff --git a/setup.cfg b/setup.cfg index 1d80743..25811e2 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 8.1.0 +current_version = 9.0.0 commit = False tag = False diff --git a/setup.py b/setup.py index 021bd1f..a873011 100644 --- a/setup.py +++ b/setup.py @@ -72,7 +72,6 @@ def is_requirement(line): 'Intended Audience :: Developers', 'License :: OSI Approved :: GNU Affero General Public License v3', 'Operating System :: OS Independent', - 'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: 3.11', ], license='AGPL', diff --git a/tox.ini b/tox.ini index 4ca3226..8ab9e7e 100644 --- a/tox.ini +++ b/tox.ini @@ -1,10 +1,9 @@ [tox] -envlist = py{38, 311}-django{42} +envlist = py{311}-django{42} [testenv] envdir= - py38: {toxworkdir}/py38 py311: {toxworkdir}/py311 deps = django42: -r requirements/django42.txt