-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Drop unused django-taggit dependency (#14241)
This drops the django-taggit dependency and drops the relevant fields from old migrations. Signed-off-by: Rick Elrod <[email protected]>
- Loading branch information
Showing
13 changed files
with
28 additions
and
158 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# -*- coding: utf-8 -*- | ||
from __future__ import unicode_literals | ||
|
||
from django.db import migrations | ||
|
||
|
||
def delete_taggit_contenttypes(apps, schema_editor): | ||
ContentType = apps.get_model('contenttypes', 'ContentType') | ||
ContentType.objects.filter(app_label='taggit').delete() | ||
|
||
|
||
def delete_taggit_migration_records(apps, schema_editor): | ||
recorder = migrations.recorder.MigrationRecorder(connection=schema_editor.connection) | ||
recorder.migration_qs.filter(app='taggit').delete() | ||
|
||
|
||
class Migration(migrations.Migration): | ||
dependencies = [ | ||
('main', '0185_move_JSONBlob_to_JSONField'), | ||
] | ||
|
||
operations = [ | ||
migrations.RunSQL("DROP TABLE IF EXISTS taggit_tag CASCADE;"), | ||
migrations.RunSQL("DROP TABLE IF EXISTS taggit_taggeditem CASCADE;"), | ||
migrations.RunPython(delete_taggit_contenttypes), | ||
migrations.RunPython(delete_taggit_migration_records), | ||
] |
This file contains 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
This file contains 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
This file contains 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
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.