﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
23521	removal of concrete Model from bases doesn't remove it from ModelState bases	Sergey Fedoseev	Tom L.	"Steps to reproduce:

* add `test` app with `models.py`:
{{{
class Thing(models.Model):
    pass


class SuperThing(Thing):
    pass
}}}

* do

{{{
manage.py makemigrations test
}}}


* change `models.py` (remove `Thing`):
{{{
class SuperThing(models.Model):
    thing_ptr = models.AutoField(primary_key=True)
}}}

* do

{{{
manage.py makemigrations test
}}}

* do it one more time

{{{
manage.py makemigrations test
}}}

last command results in


{{{
django.db.migrations.state.InvalidBasesError: Cannot resolve bases for [<ModelState: 'test.SuperThing'>]
This can happen if you are inheriting models from an app with migrations (e.g. contrib.auth)
 in an app with no migrations; see https://docs.djangoproject.com/en/1.7/topics/migrations/#dependencies for more
}}}
"	Bug	assigned	Migrations	dev	Normal			info+coding@… bugs@… ericmills2@… Charlie Denton Ian Foote Daniel Rios	Accepted	1	0	0	1	0	0
