Ticket #414 (closed defect: fixed)

Opened 6 years ago

Last modified 6 years ago

Classes that inherit from django.contrib.contenttypes.generic.GenericRelation are not ignored

Reported by: jazzido@… Owned by: andrew
Priority: major Milestone: 0.7.1
Component: commands Version: 0.7
Keywords: Cc:


django-objectpermissions (http://github.com/washingtontimes/django-objectpermissions) implements two classes (models.UserPermissionRelation and models.GroupPermissionRelation) that inherit from django.contrib.contenttypes.generic.GenericRelation.

South's modelsinspector ignores GenericRelation by default, but doesn't check if a field inherits from it causing an error in instrospection.

Here's a patch to include an introspection plugin for django-objectpermission (a quite popular Django app) to ignore models.UserPermissionRelation and models.GroupPermissionRelation.

More generally, modelsinspector.can_ignore could be modified to check a field's base class. I'm not sure if that'd be correct...


Manuel Aristarán


django-objectpermissions-plugin.py (891 bytes) - added by jazzido@… 6 years ago.
objectpermissions introspection plugin

Change History

Changed 6 years ago by jazzido@…

objectpermissions introspection plugin

comment:1 Changed 6 years ago by andrew

  • Status changed from new to closed
  • Resolution set to fixed
  • Milestone set to 0.7.1

Committed in [758283ed1e6e].

Note: See TracTickets for help on using tickets.