Drop django-tagging as dependency#13216
Conversation
🔴 Risk threshold exceeded.This pull request modifies a sensitive file (dojo/db_migrations/0066_django_tagulous.py) which the scanner flagged as a "Configured Codepaths Edit" at a failing risk threshold but not set to block. If the change is expected, update .dryrunsecurity.yaml to allow the path or authors; otherwise review the edit before merging.
🔴 Configured Codepaths Edit in
|
| Vulnerability | Configured Codepaths Edit |
|---|---|
| Description | Sensitive edits detected for this file. Sensitive file paths and allowed authors can be configured in .dryrunsecurity.yaml. |
We've notified @mtesauro.
All finding details can be found in the DryRun Security Dashboard.
e2fda62 to
f1fcb35
Compare
b66a250 to
ad7ee27
Compare
valentijnscholten
left a comment
There was a problem hiding this comment.
Thanks for the PR.
The reason why this data migration (and others) are not present in the squashed migration is:
I think the idea of the squash was that at some point we can remove individual migrations 0001-0090. But dropping django-tagging is a good start.
@fopina can you rebase/merge dev so we can see if all tests pass?
ad7ee27 to
649619d
Compare
@valentijnscholten I meant here to highlight the low impact of the change, not to question the decision to not include it 👍 no point having data migrations if there is no data 😄 rebased 🤞 |
Description
This PR addresses #13161
django-tagging has been replaced with tagulous long time ago, in #3333, including a migration (0066) to copy the tags over. All references later removed in #4419 (migration 0093)
Both of these are merged even before v2.0.0.
I believe this dependency can be safely removed at this point.
This PR removes it from
requirements.txtand removes the data-migration from 0066:Release notes v2 updated to highlight the new extra step, for those who haven't updated Dojo in over 5 years (if anyone).
Test results
Only test assertion done is that unit tests execute properly, including running all migrations on a clean database.
I've also temporarily removed the squashed 1-90 migration to make sure 66 was executed without any issues and it is.
I've tried adding some logic to the migration 0066 as in to check whether tags had been migrated or not (and fail otherwise), but I've been unable to "go back" to a version actively using django-tagging.
I have honestly tried in this branch of Dojo v1.11 and fought for quite some time with invalid debian packages and dependency issues (with conflicting requirements due to new versions and lack of transitive dependency pinning).
I ended up realizing that migration 66 (or any other) does not actually delete "tagging" data, so the check I had imagined wouldn't help anyway so I gave up trying this realistic (yet unlikely) scenario
Documentation
release notes for 2.0 updated
Checklist
This checklist is for your information.
dev.dev.bugfixbranch.