Monday, May 23, 2016

Post doesn't declare an explicit app_label and either isn't in an application in INSTALLED_APPS

Performing system checks...

System check identified no issues (0 silenced).

You have unapplied migrations; your app may not work properly until they are applied.
Run 'python manage.py migrate' to apply them.

May 24, 2016 - 05:07:14
Django version 1.8.7, using settings 'site1.settings'
Starting development server at http://127.0.0.1:8081/
Quit the server with CONTROL-C.
/home/martin/Downloads/site1/site1/reg/models.py:30: RemovedInDjango19Warning: Model class site1.reg.models.Post doesn't declare an explicit app_label and either isn't in an application in INSTALLED_APPS or else was imported before its application was loaded. This will no longer be supported in Django 1.9.
  class Post(models.Model):

[24/May/2016 05:07:18] "GET /reg/ HTTP/1.1" 200 2260
[24/May/2016 05:07:29] "POST /reg/ HTTP/1.1" 200 2260

after set

INSTALLED_APPS = (
    'django.contrib.admin',
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles',
    'django.contrib.sites',
)

MIDDLEWARE_CLASSES = (
    'django.contrib.sessions.middleware.SessionMiddleware',
    'django.middleware.common.CommonMiddleware',
    'django.middleware.csrf.CsrfViewMiddleware',
    'django.contrib.auth.middleware.AuthenticationMiddleware',
    'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
    'django.contrib.messages.middleware.MessageMiddleware',
    'django.middleware.clickjacking.XFrameOptionsMiddleware',
    'django.middleware.security.SecurityMiddleware',
    'site1.reg.models.Post',
)

--
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/af8d104b-6f40-4183-86d1-278d137f4501%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment