一、安装pipmysql
二、pip install PyMySQLsql
三、在__init__.py添加以下内容:ide
import pymysqlip
pymysql.install_as_MySQLdb()it