我不能让我的网站在南方运行.我已成功安装在南方,我可以“成功进口南方”.
./manage.py shell >>> import south >>>
但是,一旦我将’south’添加到INSTALLED_APPS,并运行./manage.py syncdb(以完成安装),我会收到以下错误:
There is no South database module ‘south.db.django.db.backends.postgresql_psycopg2’ for your database. Please either choose a supported database,check for SOUTH_DATABASE_ADAPTER[S] settings,or remove South from INSTALLED_APPS.
我正在使用PostgreSQL数据库和postgresql_psycopg2库.我很困惑,因为Postgres肯定是一个受支持的数据库.我是否需要在settings.py中手动配置SOUTH_DATABASE_ADAPTER?
编辑:这是我的数据库设置.我知道他们的工作 – 我试图让这个运行的(测试)服务器一直在与数据库正常交谈数周.
DATABASE_ENGINE = 'postgresql_psycopg2' DATABASE_NAME = 'iknowthisiscorrect' DATABASE_HOST = '' #localhost DATABASE_PORT = '5432' # I've configured Postgres to use this port
解决方法
我在South
source code发现了这个评论.看看第63行.
63 # This error should only be triggered on 1.1 and below. 64 sys.stderr.write( 65 ( 66 "There is no South database module '%s' for your database. " + \ 67 "Please either choose a supported database,check for " + \ 68 "SOUTH_DATABASE_ADAPTER[S] settings," + \ 69 "or remove South from INSTALLED_APPS.\n" 70 ) % (module_name,)
您使用的是哪个版本的Django?是< = 1.1?