I use two django packages - django-mptt (utilities for implementing a modified traversal of the order tree) and django-hvad (model translation).
I have a MenuItem model class and I want it to extend the TranslitableModel and MPTTModel, for example:
class MenuItem(TranslatableModel, MPTTModel):
but this causes a metaclass conflict:
(TypeError: Error when calling the metaclass bases metaclass conflict: the metaclass of a derived class must be a (non-strict) subclass of the metaclasses of all its bases)
What is the solution to this problem? I hope that I can use double inheritance.
David silva
source share