Skip to content

chore: drop Django 4.2 support#377

Open
aznszn wants to merge 2 commits intoopenedx:masterfrom
aznszn:chore/make-upgrade-remove-django4.2
Open

chore: drop Django 4.2 support#377
aznszn wants to merge 2 commits intoopenedx:masterfrom
aznszn:chore/make-upgrade-remove-django4.2

Conversation

@aznszn
Copy link

@aznszn aznszn commented Mar 25, 2026

Description: Dropped Django 4.2 support. Removed Django 4.2 from CI matrix, tox environments, and setup.py classifiers.

Issue: openedx/public-engineering#458

JIRA: N/A

Dependencies: N/A

Merge deadline: N/A

Installation instructions: N/A

Reviewers:

  • tag reviewer
  • tag reviewer

Merge checklist:

  • All reviewers approved
  • CI build is green
  • Version bumped
  • Changelog record added
  • Documentation updated (not only docstrings)
  • Commits are squashed

Post merge:

  • Create a tag
  • Create a new release (can be done here https://github.com/edx/edx-ace/releases)
  • Check new version is pushed to PyPI after tag-triggered build is finished.
  • Delete working branch (if not needed anymore)

@openedx-webhooks openedx-webhooks added the open-source-contribution PR author is not from Axim or 2U label Mar 25, 2026
@openedx-webhooks
Copy link

Thanks for the pull request, @aznszn!

This repository is currently maintained by @jawad-khan.

Once you've gone through the following steps feel free to tag them in a comment and let them know that your changes are ready for engineering review.

🔘 Get product approval

If you haven't already, check this list to see if your contribution needs to go through the product review process.

  • If it does, you'll need to submit a product proposal for your contribution, and have it reviewed by the Product Working Group.
    • This process (including the steps you'll need to take) is documented here.
  • If it doesn't, simply proceed with the next step.
🔘 Provide context

To help your reviewers and other members of the community understand the purpose and larger context of your changes, feel free to add as much of the following information to the PR description as you can:

  • Dependencies

    This PR must be merged before / after / at the same time as ...

  • Blockers

    This PR is waiting for OEP-1234 to be accepted.

  • Timeline information

    This PR must be merged by XX date because ...

  • Partner information

    This is for a course on edx.org.

  • Supporting documentation
  • Relevant Open edX discussion forum threads
🔘 Submit a signed contributor agreement (CLA)

⚠️ We ask all contributors to the Open edX project to submit a signed contributor agreement or indicate their institutional affiliation.
Please see the CONTRIBUTING file for more information.

If you've signed an agreement in the past, you may need to re-sign.
See The New Home of the Open edX Codebase for details.

Once you've signed the CLA, please allow 1 business day for it to be processed.
After this time, you can re-run the CLA check by adding a comment below that you have signed it.
If the CLA check continues to fail, you can tag the @openedx/cla-problems team in a comment for further assistance.

🔘 Get a green build

If one or more checks are failing, continue working on your changes until this is no longer the case and your build turns green.

Details
Where can I find more information?

If you'd like to get more details on all aspects of the review process for open source pull requests (OSPRs), check out the following resources:

When can I expect my changes to be merged?

Our goal is to get community contributions seen and reviewed as efficiently as possible.

However, the amount of time that it takes to review and merge a PR can vary significantly based on factors such as:

  • The size and impact of the changes that it introduces
  • The need for product review
  • Maintenance status of the parent repository

💡 As a result it may take up to several weeks or months to complete a review and merge your PR.

@github-project-automation github-project-automation bot moved this to Needs Triage in Contributions Mar 25, 2026
@aznszn aznszn changed the title ran make upgrade and removed django 4.2 references Dropped django 4.2 support. Bumped dependencies Mar 25, 2026
@aznszn aznszn force-pushed the chore/make-upgrade-remove-django4.2 branch from 2ad9ce4 to bd84eb1 Compare March 25, 2026 10:01
@aznszn aznszn changed the title Dropped django 4.2 support. Bumped dependencies chore: drop Django 4.2 support Mar 25, 2026
@jawad-khan jawad-khan requested a review from Copilot March 25, 2026 10:14
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes Django 4.2 as a supported/tested framework version for the project, updating CI, tox environments, and package metadata accordingly.

Changes:

  • Removed the Django 4.2 tox factor/env and CI job entry, leaving Django 5.2 as the tested Django version.
  • Updated package classifiers to no longer advertise Django 4.2 support.
  • Added a changelog entry noting the support drop.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
tox.ini Removes django42 factor and narrows the envlist to Django 5.2.
.github/workflows/ci.yml Drops django42 from the GitHub Actions matrix.
setup.py Removes the Framework :: Django :: 4.2 classifier.
CHANGELOG.rst Documents the removal of Django 4.2 support under Unreleased.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 1 to +2
[tox]
envlist = py{312}-django{42, 52}, docs, quality
envlist = py{312}-django{52}, docs, quality
Copy link

Copilot AI Mar 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The tox envlist defines a single Django test environment named py312-django52, but the CI workflow matrix uses TOXENV=django52. django52 is not a defined tox environment in this repo (no [testenv:django52]), so tox will error in CI. Align the env naming by either updating envlist/adding a django52 env, or updating CI to run py312-django52.

Copilot uses AI. Check for mistakes.
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed in 3ec662e

Comment on lines 16 to 20
matrix:
os: [ubuntu-latest]
python-version: ['3.12']
toxenv: [quality, docs, django42, django52]
toxenv: [quality, docs, django52]

Copy link

Copilot AI Mar 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The workflow matrix uses toxenv: ... django52, but tox.ini doesn't define a django52 environment (it defines py312-django52). With TOXENV=django52, tox will fail due to an unknown environment. Align the matrix value with the tox env name (and update the later coverage if that checks matrix.toxenv=='django52' accordingly), or add a matching django52 tox env.

Copilot uses AI. Check for mistakes.
Comment on lines 150 to 154
classifiers=[
'Development Status :: 3 - Alpha',
'Framework :: Django',
'Framework :: Django :: 4.2',
'Framework :: Django :: 5.2',
'Intended Audience :: Developers',
Copy link

Copilot AI Mar 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR drops Django 4.2 support and the package classifiers now only advertise Django 5.2, but install_requires is still loaded from requirements/base.in, which currently allows Django>=2.2. That means pip can install this project alongside unsupported Django versions despite the advertised support. Consider updating the Django requirement (in requirements/base.in and/or via constraints) to enforce the minimum supported Django version for releases that drop 4.2.

Copilot uses AI. Check for mistakes.
- Pin Django requirement to >=5.2,<5.3 in base.in
- Update CI toxenv from 'django52' to 'py312-django52' to match tox config
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

open-source-contribution PR author is not from Axim or 2U

Projects

Status: Needs Triage

Development

Successfully merging this pull request may close these issues.

3 participants