I have been walking through the Tutorial for Django, and upon reaching part 5 and introducing the first test case, I get this output (the directory I put the tutorial in is called 'demo')
RuntimeError: Model class demo.polls.models.Question doesn't declare an explicit app_label and isn't in an application in INSTALLED_APPS.
I tried adding a Meta section to the Question model, after doing some poking around in the docs.
class Question(models.Model):
question_text = models.CharField(max_length=200)
pub_date = models.DateTimeField('date published')
class Meta:
app_label='polls'
But then I get this:
RuntimeError: Conflicting 'question' models in application 'polls': <class 'polls.models.Question'> and <class 'demo.polls.models.Question'>.
What modifications would I have to make to the standard Tutorial code so the Models are correctly bound to the polls app? Do I have to add something else to the installed_apps besides 'polls.apps.PollsConfig'? That's the only thing the tutorial says to add.
Thanks,
Eric