django-nonrel 和管理页面 [英] django-nonrel and the admin page

查看:28
本文介绍了django-nonrel 和管理页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在 AppEngine 上为我的网站设置 Django 管理套件,但它无法正常工作.我正在使用 django-nonrel 设置.我网站的其余部分似乎工作正常,但我需要让管理员工作,以便我可以开始使用数据存储.

I am trying to set-up the Django admin suite for my site on AppEngine and it is not working. I am using the django-nonrel setup with . The rest of my site seems to work fine but I need to get the admin working so I can start working with the datastore.

这是我得到的错误:

DoesNotExist at /admin/
Site matching query does not exist.

我的 url 模式包括这个模式:

My url patterns includes this pattern:

url(r'^admin/', include(admin.site.urls)),

我的设置包括:

'autoload',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.admin',
'djangotoolbox',
'djangoappengine',
'myapp',

我的困惑是它已安装并且在那里,所以我不确定为什么它在该页面上失败.为了证明我没有失去理智,我从一个工作站点复制了 URL 模式代码并查看了管理模块的代码,但仍然没有运气.

My confusion is that this is installed and it is there so I am not sure why it's failing on that page. To prove I was not loosing my mind I copied the URL pattern code from a working site and looked at the code for the admin module but still no luck.

感谢任何人的见解.

RB

推荐答案

我遇到了同样的问题,只需在已安装的应用程序中注释掉 'django.contrib.sites'...现在应该可以了!

I had the same problem, simply comment out 'django.contrib.sites', in installed apps... This should work now !

这篇关于django-nonrel 和管理页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆