Hey there,

app labels (i.e. what you specify in your AppConfig or in AUTH_USER_MODEL) 
are case sensitive. Thus either change AccountConfig.label to "account" 
(this affects all migrations that depend on your account app) or 
AUTH_USER_MODEL to "Account.User". I'd recommend to use lower case app 
labels

/Markus

On Thursday, May 7, 2015 at 11:39:16 AM UTC+2, Алексей Широков wrote:
>
> I have custom user model.
>
> settings.py
> -----------
> ...
> AUTH_USER_MODEL = 'account.User'
> ...
>
>
> also I have following AppConfig
>
> account/apps.py
> ---------------
>
> class AccountConfig(AppConfig):
>     name = 'isar.account'
>     *label = 'Account'*
>     verbose_name = 'Аккаунт'
>
>
> and when I call command migrate I get the following exception:
>
> ...
> File 
> "/var/venvs/isar-future/local/lib/python2.7/site-packages/django/core/management/__init__.py",
>  
> line 120, in call_command
>   return command.execute(*args, **defaults)
> File 
> "/var/venvs/isar-future/local/lib/python2.7/site-packages/django/core/management/base.py",
>  
> line 441, in execute
>   output = self.handle(*args, **options)
> File 
> "/var/venvs/isar-future/local/lib/python2.7/site-packages/django/core/management/commands/migrate.py",
>  
> line 93, in handle
>   executor = MigrationExecutor(connection, 
> self.migration_progress_callback)
> File 
> "/var/venvs/isar-future/local/lib/python2.7/site-packages/django/db/migrations/executor.py",
>  
> line 19, in __init__
>   self.loader = MigrationLoader(self.connection)
> File 
> "/var/venvs/isar-future/local/lib/python2.7/site-packages/django/db/migrations/loader.py",
>  
> line 47, in __init__
>   self.build_graph()
> File 
> "/var/venvs/isar-future/local/lib/python2.7/site-packages/django/db/migrations/loader.py",
>  
> line 287, in build_graph
>   parent = self.check_key(parent, key[0])
> File 
> "/var/venvs/isar-future/local/lib/python2.7/site-packages/django/db/migrations/loader.py",
>  
> line 165, in check_key
>   raise ValueError("Dependency on unknown app: %s" % key[0])
> ValueError: Dependency on unknown app: account
>
> I think that the problem here 
> https://github.com/django/django/blob/stable/1.8.x/django/db/migrations/migration.py#L178
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/200c62a7-7c59-4962-bd02-5a4a0b65051a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to