I use "import sqlite3" in my program, but when I run it show this error: $ python gcbot.py Traceback (most recent call last): File "gcbot.py", line 39, in <module> import sqlite3 File "/usr/lib/python2.5/sqlite3/__init__.py", line 24, in <module> from dbapi2 import * File "/usr/lib/python2.5/sqlite3/dbapi2.py", line 27, in <module> from _sqlite3 import * ImportError: No module named _sqlite3 Reproducible: Always Steps to Reproduce: 1. I write a python program that have "import sqlite3" 2. When I run it by python it show error and crash. Actual Results: Show error and crash. Expected Results: The program should run and import sqlibe3 to and use sqlibe3 database. I have installed python-2.4.4-r9 and python-2.5.1-r5. For this program I use python-2.5.1-r5.
It would work a lot better like this ;) from sqlite3 import *
(In reply to comment #1) > It would work a lot better like this ;) > > from sqlite3 import * > But still it gives same error: Traceback (most recent call last): File "gcbot.py", line 39, in <module> from sqlite3 import * File "/usr/lib/python2.5/sqlite3/__init__.py", line 24, in <module> from dbapi2 import * File "/usr/lib/python2.5/sqlite3/dbapi2.py", line 27, in <module> from _sqlite3 import * ImportError: No module named _sqlite3
-from _sqlite3 import * +from sqlite3 import * Spot the difference.
On that note - did you compile python-2.5 w/ USE=sqlite? - if yes, does /usr/lib/python2.5/lib-dynload/_sqlite3.so exist?
sorry from all, problem was my use flags, it fixed. thank you
Thanks for reporting back. :)