小编Hay*_*ley的帖子

如何在 Ubuntu 20.04 (Focal Fossa) 中为 Python 2.7 安装 python-mysqldb?

我试过“apt-get install python-mysqldb”,结果是:

root@ps1svr:~# apt-get install python-mysqldb
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package python-mysqldb is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'python-mysqldb' has no installation candidate
Run Code Online (Sandbox Code Playgroud)

注意:“apt-get install python3-mysqldb”有效,但是我有很多为 Python 2.x 编写的代码不再运行,这引起了足够多的问题,我可能不得不重新安装 Ubuntu 18.04

ubuntu mysql-python python-2.7

6
推荐指数
2
解决办法
5917
查看次数

标签 统计

mysql-python ×1

python-2.7 ×1

ubuntu ×1