Tuesday, April 2, 2013

Using Django proxy = True..

If you're using Django's proxy=True and see this error message:

  File "/usr/local/lib/python2.7/dist-packages/django/db/models/base.py", line 89, in __new__
    new_class._base_manager = new_class._base_manager._copy_to_model(new_class)
AttributeError: 'NoneType' object has no attribute '_copy_to_model'

... chances are you're assigning proxy = True to the base class instead of the inherited classes.

No comments:

Post a Comment