发布时间:2019-09-27 07:09:51编辑:auto阅读(1740)
[root@localhost python]# python3 router.py
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/sqlalchemy/dialects/sqlite/pysqlite.py", line 337, in dbapi
from sqlite3 import dbapi2 as sqlite # try 2.5+ stdlib name.
File "/usr/local/lib/python3.6/sqlite3/__init__.py", line 23, in <module>
from sqlite3.dbapi2 import *
File "/usr/local/lib/python3.6/sqlite3/dbapi2.py", line 27, in <module>
from _sqlite3 import *
ModuleNotFoundError: No module named '_sqlite3'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "router.py", line 2, in <module>
from db import *
File "/home/ming/python/db.py", line 11, in <module>
db_engine = create_engine('sqlite:///:memory:', echo = False)
File "/usr/local/lib/python3.6/site-packages/sqlalchemy/engine/__init__.py", line 391, in create_engine
return strategy.create(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/sqlalchemy/engine/strategies.py", line 80, in create
dbapi = dialect_cls.dbapi(**dbapi_args)
File "/usr/local/lib/python3.6/site-packages/sqlalchemy/dialects/sqlite/pysqlite.py", line 339, in dbapi
raise e
File "/usr/local/lib/python3.6/site-packages/sqlalchemy/dialects/sqlite/pysqlite.py", line 334, in dbapi
from pysqlite2 import dbapi2 as sqlite
ModuleNotFoundError: No module named 'pysqlite2'
[root@localhost python]#
上一篇: python3的构造方法
下一篇: 浅谈#!/usr/bin/python3
47750
46246
37132
34638
29231
25893
24762
19866
19426
17916
5720°
6323°
5841°
5891°
6991°
5830°
5850°
6364°
6318°
7682°