Automatic content types removal

27 views
Skip to first unread message

marcin....@gmail.com

unread,
May 5, 2017, 8:41:18 AM5/5/17
to Django users
Hi.

Why Django automatically removes content types? 

Due to lack of flexibility in auth system I was forced to create custom content type for custom perms.
Now I've realized that my custom content type is missing.
I am not sure, of course, but I think that Django removed my CT silently.

I know that clearing content types is OK, maybe required, but it SHOULD NOT to be run automatically!
Deleting the data is a risky operation and should be called on demand.

Is possible to disable automatic CT deletion?


Marcin

Tim Graham

unread,
May 5, 2017, 9:18:21 AM5/5/17
to Django users
From the Django 1.11 release notes:
  • The prompt for stale content type deletion no longer occurs after running the migrate command. Use the new remove_stale_contenttypes command instead.
In older versions of Django, stale content type deletion doesn't happen unless you type "yes" to the prompt that happens after migrate.

marcin....@gmail.com

unread,
May 5, 2017, 11:06:09 AM5/5/17
to Django users
Thanks, Tim. I'll take a look at this.  
Reply all
Reply to author
Forward
0 new messages