Trying to get an oauth
module to work I made the pro-move of : manage.py reset sites
This had the effect killing the admin and login functionality of my site.
So, my question is how to I get back to square one and fix what I broke.
Here is my current error when trying to display the admin tool:
DoesNotExist at /admin/ Site matching query does not exist. Request Method: GET Request URL: http://mdev.5buckchuck.com/admin/ Django Version: 1.3 Exception Type: DoesNotExist Exception Value: Site matching query does not exist.`
I looked at the documentation but I am lost and tired in it: http://docs.djangoproject.com/en/1.3/ref/contrib/sites/
It seemed to indicate: manage.py syncdb
So, I wonder what to do next...
You don't really need the sites
framework if you only run one site from the project, so the easiest fix would be to remove the following item from your INSTALLED_APPS
and the error should go away:
'django.contrib.sites'
You can also re-create the missing Site
object from shell. Run python manage.py shell
and then:
from django.contrib.sites.models import Site Site.objects.create(pk=1, domain='mdev.5buckchuck.com', name='5buckchuck.com')
Provide SITE_ID=1 in settings.py. This will work.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With