Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

django 1.9 issue #1

Open
andresdouglas opened this issue May 10, 2016 · 4 comments
Open

django 1.9 issue #1

andresdouglas opened this issue May 10, 2016 · 4 comments

Comments

@andresdouglas
Copy link

When installing in a django 1.9 site, run into the following error:

lib/python2.7/site-packages/django/apps/registry.py", line 124, in check_apps_ready
    raise AppRegistryNotReady("Apps aren't loaded yet.")
django.core.exceptions.AppRegistryNotReady: Apps aren't loaded yet.

I believe it has to do with this issue: etianen/django-reversion#481, especifically that you shouldn't import models from your app's init.py file

@andresdouglas
Copy link
Author

I know you're not actively maintaining this repo, but just thought I'd keep track of it here.

@andresdouglas
Copy link
Author

Adding the following lines in your site's settings.py below the SECRET_KEY declaration seems to fix things:

import django
django.setup()

@andresdouglas
Copy link
Author

Nevermind, that doesn't seem to work. Seems like that call to setup is premature and installed apps won't actually get processed.

@zzantares
Copy link

For me I was trying to use the User model in an apps.py, I had to move my import from the top of the file to be inside the ready() function in my AppConfig class, now it works fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants