Search code examples
djangodjango-southdjango-taggit

django-taggit-autocomplete and south


I use django-taggit-autocomplete, but when doing a schememigrating, I got an error

 ! Cannot freeze field 'main.hotels.tags'
 ! (this field has class taggit_autocomplete_modified.managers.TaggableManagerAutocomplete)
 ! Cannot freeze field 'main.rooms.tags'
 ! (this field has class taggit_autocomplete_modified.managers.TaggableManagerAutocomplete)

 ! South cannot introspect some fields; this is probably because they are custom
 ! fields. If they worked in 0.6 or below, this is because we have removed the
 ! models parser (it often broke things).
 ! To fix this, read http://south.aeracode.org/wiki/MyFieldsDontWork

So I search a little bit and found django-taggit-autocomplete-modified, which should solve the problem, but it doesn't.

What is the best way how to workaround it?


Solution

  • Finally I have solved the problem adding following code to models.py

    from south.modelsinspector import add_ignored_fields
    add_ignored_fields(["^taggit_autocomplete\.managers"])