[Answer]-Django-taggit inserting

1👍

I just had a similar problem and looked into the taggit tests. The only thing I got working is adding the tags after creation like so:

defaults = {
    'owner': user,
    'title': obj.title,
    'abstract': obj.abstract,
    'url': obj.url,
}
obj_instance, created = Obj.objects.get_or_create(title=obj.title, defaults=defaults)
obj_instance.add(*obj.keywords)
👤ramiro

Leave a comment