Пытаясь runserver
с db['ENGINE'] = 'django.db.backends.psycopg2'
Я получил:
[...]
File "/usr/local/lib/python2.6/dist-packages/django/db/backends/psycopg2/__init__.py", line 67, in <module>
from psycopg2._psycopg import BINARY, NUMBER, STRING, DATETIME, ROWID
File "/usr/local/lib/python2.6/dist-packages/psycopg2-2.4.4-py2.6-linux-x86_64.egg/psycopg2/__init__.py", line 67, in <module>
from psycopg2._psycopg import BINARY, NUMBER, STRING, DATETIME, ROWID
ImportError: /usr/local/lib/python2.6/dist-packages/psycopg2-2.4.4-py2.6-linux-x86_64.egg/psycopg2/_psycopg.so: undefined symbol: Py_InitModule4_64
с 'ENGINE': 'django.db.backends.postgresql_psycopg2'
Я получил:
[...]
File "/usr/local/lib/python2.6/dist-packages/django/utils/importlib.py", line 35, in import_module
__import__(name)
File "/usr/local/lib/python2.6/dist-packages/django/db/backends/postgresql_psycopg2/base.py", line 24, in <module>
raise ImproperlyConfigured("Error loading psycopg2 module: %s" % e)
django.core.exceptions.ImproperlyConfigured: Error loading psycopg2 module: /usr/local/lib/python2.6/dist-packages/psycopg2-2.4.4-py2.6-linux-x86_64.egg/psycopg2/_psycopg.so: undefined symbol: Py_InitModule4_64
И я не должен использовать psycopg с Python>2.6, верно?
Любая помощь о том, как сделать эту работу?