From aa84a7ff2b99b3d92217b9f17f99069277d5f64d Mon Sep 17 00:00:00 2001 From: Nick Sweeting Date: Mon, 1 Feb 2021 05:13:23 -0500 Subject: [PATCH] fix migration creating conflicting tags based on slug --- archivebox/core/migrations/0006_auto_20201012_1520.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/archivebox/core/migrations/0006_auto_20201012_1520.py b/archivebox/core/migrations/0006_auto_20201012_1520.py index 694c9908..dc96c8da 100644 --- a/archivebox/core/migrations/0006_auto_20201012_1520.py +++ b/archivebox/core/migrations/0006_auto_20201012_1520.py @@ -17,7 +17,7 @@ def forwards_func(apps, schema_editor): tag_set.discard("") for tag in tag_set: - to_add, _ = TagModel.objects.get_or_create(name=tag, slug=slugify(tag)) + to_add, _ = TagModel.objects.get_or_create(name=tag, defaults={'slug': slugify(tag)}) snapshot.tags.add(to_add)