build: tox pin django 5.2-5.3 - #2677
Closed
marlonkeating wants to merge 1 commit into
Closed
Conversation
Contributor
Author
|
Fixed by #2551 |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #2677 +/- ##
==========================================
+ Coverage 86.97% 87.02% +0.04%
==========================================
Files 261 262 +1
Lines 17143 17228 +85
Branches 1693 1705 +12
==========================================
+ Hits 14910 14992 +82
- Misses 1896 1897 +1
- Partials 337 339 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The
pii_checkCI job fails with:Why
requirements/test.txtdeliberately omits theDjango==pin — theMakefilestrips it out (
# Let tox control the Django version for tests) so that each[testenv]factor (e.g.django52) can supply its ownDjango>=5.2,<5.3constraint before installing
test.txt.[testenv:pii_check]is a standalone tox section that never inherited thatconstraint, so Django was left completely unpinned in that one job. Once
Django 6.1 landed on PyPI, pip resolved to it for
pii_check, but 6.1 removedcc_delim_refromdjango.utils.cache, which the pinneddjangorestframework==3.17.1still imports — breakingenterprise/admin/views.py's import chain duringdjango_find_annotations.This isn't caused by any recent requirements upgrade —
requirements/*.txtare unchanged; it's a latent gap in
tox.inithat surfaced only once a newDjango release appeared. The
edx-requirements-botPR #2675 hits the samefailure for the same reason.
Fix
Add the same
Django>=5.2,<5.3pin already used by thedjango52env to[testenv:pii_check]'sdeps.Testing
Ran
tox -e pii_checklocally against this branch:cc_delim_reImportError5.2.16;django_find_annotationslinting andPII coverage checks (85.1%) pass