Thursday, May 7, 2015

Little trouble with migration.

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+unsubscribe@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/82ddf759-57f0-418d-9e3f-959a87f88491%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment