From 28acc9516dc0daf04e6d992569f916c31a70effc Mon Sep 17 00:00:00 2001 From: Akita Noek Date: Fri, 1 Apr 2016 15:18:48 -0400 Subject: [PATCH] Hopefully fix ContentType problem hit during 2.4 -> 3.0 upgrade migration #1380 --- awx/main/migrations/_rbac.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/awx/main/migrations/_rbac.py b/awx/main/migrations/_rbac.py index d6f202e75a..318c6d4667 100644 --- a/awx/main/migrations/_rbac.py +++ b/awx/main/migrations/_rbac.py @@ -1,6 +1,5 @@ import logging -from django.contrib.contenttypes.models import ContentType from django.utils.encoding import smart_text from django.db.models import Q @@ -31,6 +30,7 @@ def migrate_users(apps, schema_editor): User = apps.get_model('auth', "User") Role = apps.get_model('main', "Role") RolePermission = apps.get_model('main', "RolePermission") + ContentType = apps.get_model('contenttypes', "ContentType") for user in User.objects.iterator(): try: