Django 1.7 upgrade error: AppRegistryNotReady: Apps aren't loaded yet

前端 未结 14 770
耶瑟儿~
耶瑟儿~ 2020-12-08 00:13

I am trying to upgrade a project from Django 1.6 to 1.7. I get the following error:

[Thu Oct 09 14:16:41 2014] [error] [client 95.79.172.156] mod_wsgi (pid=1         


        
相关标签:
14条回答
  • 2020-12-08 00:20

    INSTALLED_APPS Had an missing comma in the array, that caused the error for me.

    0 讨论(0)
  • 2020-12-08 00:22

    I had a similar (the same?) isssue when upgrading to Django 1.7. In may case, it was enough to update the wsgi file: replace

    import django.core.handlers.wsgi
    application = django.core.handlers.wsgi.WSGIHandler()
    

    with

    from django.core.wsgi import get_wsgi_application
    application = get_wsgi_application()
    
    0 讨论(0)
  • 2020-12-08 00:22

    It could be any reason. In my case, I updated my python version outside of my virtual environment, but my virtualenv was still the old version, that makes the error. I deleted the env and build it again using the newer version, and it worked.

    0 讨论(0)
  • 2020-12-08 00:23

    Just reinstall Django using the command line, not in Pycharm helped to me.

    0 讨论(0)
  • 2020-12-08 00:25

    In my case SEcret_key was commented by mistake in settings.py

    0 讨论(0)
  • 2020-12-08 00:25

    In my case, I forgot to add one of my sub-applications inside INSTALLED_APPS.

    INSTALLED_APPS = [
        'django.contrib.admin',
        'django.contrib.auth',
        'django.contrib.contenttypes',
        'django.contrib.sessions',
        'django.contrib.messages',
        'django.contrib.staticfiles',
        'basketball',
        'basketball.area',
        'basketball.game',
        'basketball.player',
    ]
    
    0 讨论(0)
提交回复
热议问题