Hello,

I had this issue too, I found the solution in a stackoverflow (sorry I 
dont' have the URL)

Basically what you have to do after  syncdb is:

$ ./manage.py migrate
$ ./manage.py convert_to_south app

I've got this error: don't worry is part of the procedure :)

CommandError: One or more models did not validate:
auth.user: Model has been swapped out for 'app.MyUser' which has not been 
installed or is abstract.

After the error, I created a fake migration:

$ ./manage.py migrate app 0001 --fake

I changed my models (including MyUser):

$ ./manage.py schemamigration app --auto

No errors so far

$ ./manage.py migrate app

Done!!!


Hope this helps

JF

PS: I have 'django.contrib.auth' in INSTALLED_APPS

El viernes, 1 de febrero de 2013 08:28:01 UTC-3, Tejinder Singh escribió:
>
> I have a custom app in my project named 'profiles' which contains a custom 
> User model. Here is the declaration of the same:
>
> class CustomUser(AbstractUser):
>     image = models.ImageField(_('Image Field'), upload_to='user_images')
>
> I have pointed this in my settings module, AUTH_USER_MODEL = 
> 'profiles.CustomUser'
>
> and in my settings i have 2 installed apps only, 1. South and 2. profiles.
>
> when i do syncdb, everything seems to work fine, but when I 
> django-admin.py convert_to_south profiles, it gives me following error:
> Creating migrations directory at 
> '/Users/tejinder/Projects/basidia/apps/profiles/migrations'...
> Creating __init__.py in 
> '/Users/tejinder/Projects/basidia/apps/profiles/migrations'...
>  + Added model profiles.CustomUser
>  + Added M2M table for groups on profiles.CustomUser
>  + Added M2M table for user_permissions on profiles.CustomUser
> Created 0001_initial.py. You can now apply this migration with: 
> ./manage.py migrate profiles
> CommandError: One or more models did not validate:
> auth.user: Model has been swapped out for 'profiles.CustomUser' which has 
> not been installed or is abstract.
>
> What could have been gone wrong? Thanks in advance.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to