InvalidBasesError when running migrate in Django -
i'm trying discover django-cms.
i've made fresh project (following these steps). when django migrate
, following issue:
>>>python manage.py migrate operations perform: synchronize unmigrated apps: treebeard, menus, sekizai, cms, djangocms_admin_style apply migrations: sessions, reversion, auth, admin, contenttypes, sites, djangocms_picture synchronizing apps without migrations: creating tables... installing custom sql... installing indexes... running migrations: applying djangocms_picture.0001_initial...traceback (most recent call last): file "manage.py", line 10, in <module> execute_from_command_line(sys.argv) file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/core/management/__init__.py", line 385, in execute_from_command_line utility.execute() file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/core/management/__init__.py", line 377, in execute self.fetch_command(subcommand).run_from_argv(self.argv) file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/core/management/base.py", line 288, in run_from_argv self.execute(*args, **options.__dict__) file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/core/management/base.py", line 338, in execute output = self.handle(*args, **options) file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/core/management/commands/migrate.py", line 161, in handle executor.migrate(targets, plan, fake=options.get("fake", false)) file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/db/migrations/executor.py", line 68, in migrate self.apply_migration(migration, fake=fake) file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/db/migrations/executor.py", line 96, in apply_migration if self.detect_soft_applied(migration): file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/db/migrations/executor.py", line 140, in detect_soft_applied apps = project_state.render() file "/home/vmonteco/.envs/django-cms/lib/python3.4/site-packages/django/db/migrations/state.py", line 75, in render "for more" % new_unrendered_models django.db.migrations.state.invalidbaseserror: cannot resolve bases [<modelstate: 'cms.pageuser'>, <modelstate: 'cms.pageusergroup'>] can happen if inheriting models app migrations (e.g. contrib.auth) in app no migrations; see https://docs.djangoproject.com/en/1.7/topics/migrations/#dependencies more
here installed_apps :
installed_apps = ( 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', 'django.contrib.auth', 'django.contrib.sites', 'djangocms_admin_style', # admin skin. must before 'django.contrib.admin' 'django.contrib.admin', 'cms', # django cms 'treebeard', # utilities implementing tree (replaces mptt) 'menus', # helper model independent herarchical website navigation 'sekizai', # js , css management. 'reversion', # versionize content #'djangocms_file', #'djangocms_picture', #'djangocms_video', #'djangocms_link', #'djangocms_text_ckeditor', # django text plugin )
this error occurs when uncomment 1 of last lines. why? how fix this?
i found solution here.
you have change migration_modules
in project settings, removing _django
of values. linked page mentions cms
, menus
, had remove djangocms_link
, djangocms_text_ckeditor
too.
Comments
Post a Comment