我尝试在我的副总裁上运行姜戈应用程序,运行Debian5。当我运行演示应用程序时,返回以下错误:
File "/usr/local/lib/python2.5/site-packages/django/utils/importlib.py", line 35, in import_module
__import__(name)
File "/usr/local/lib/python2.5/site-packages/django/db/backends/sqlite3/base.py", line 30, in <module>
raise ImproperlyConfigured, "Error loading %s: %s" % (module, exc)
ImproperlyConfigured: Error loading either pysqlite2 or sqlite3 modules (tried in that order): No module named _sqlite3
查看Python安装,它给出了相同的错误:
Python 2.5.2 (r252:60911, May 12 2009, 07:46:31)
[GCC 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import sqlite3
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.5/sqlite3/__init__.py", line 24, in <module>
from dbapi2 import *
File "/usr/local/lib/python2.5/sqlite3/dbapi2.py", line 27, in <module>
from _sqlite3 import *
ImportError: No module named _sqlite3
>>>
通过在Web上阅读,我了解到Python2.5应该附带所有必要的SQLite包装器。我是否需要重新安装Python,或者是否有其他方法可以启动并运行此模块?