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