Ticket #414 (closed defect: fixed)
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: |
Description
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...
Thanks!
--
Manuel Aristarán
Attachments
Change History
Changed 3 years ago by jazzido@…
- Attachment django-objectpermissions-plugin.py added
comment:1 Changed 3 years ago by andrew
- Status changed from new to closed
- Resolution set to fixed
- Milestone set to 0.7.1
Committed in [758283ed1e6e].

objectpermissions introspection plugin