pip install flask-mysqldb
C:\Users\prince>pip install flask-mysqldb 收集flask-mysqldb
使用缓存 的https://files.pythonhosted.org/packages/62/e3/955c845efe1aacf30c8e2607470544ede36aa1044f6382c809f13e014104/Flask-MySQLdb-0.2.0.tar.gz 要求已经满足: Flask>=0.10 in c:\users\prince\appdata\local\programs\python\python37-32\lib\site-packages (来自flask-mysqldb) (1.1.1) 收集mysqlclient (来自flask-mysqldb) 使用缓存 https://files.pythonhosted.org/packages/4d/38/c5f8bac9c50f3042c8f05615f84206f77f03db79781db841898fde1bb284/mysqlclient-1.4.4.tar.gz \users\prince\appdata\local\programs\python\python37-32\lib\site-packages (来自 Jinja2>=2.10.1->Flask>=0.10->flask-mysqldb) (1.1.1) 安装收集的包:mysqlclient,flask-mysqldb Running setup.py install for mysqlclient ...错误错误:命令错误退出状态1:命令:'c:\用户\王子\应用数据\本地\程序\python\python37-32\python .exe' -u -c '导入系统,setuptools,tokenize;sys.argv[0] = '"'"'C:\Users\prince\AppData\Local\Temp\pip-install-sb1cs5ex\mysqlclient\setup.py'"'"'; 命令:'c:\users\prince\appdata\local\programs\python\python37-32\python.exe' -u -c 'import sys,setuptools,tokenize;sys.argv[0] = '"'"'C:\Users\prince\AppData\Local\Temp\pip-install-sb1cs5ex\mysqlclient\setup.py'"'"'; 命令:'c:\users\prince\appdata\local\programs\python\python37-32\python.exe' -u -c 'import sys,setuptools,tokenize;sys.argv[0] = '"'"'C:\Users\prince\AppData\Local\Temp\pip-install-sb1cs5ex\mysqlclient\setup.py'"'"'; file ='"'"'C:\Users\prince\AppData\Local\Temp\pip-install-sb1cs5ex\mysqlclient\setup.py'"'"';f=getattr(tokenize, '"'"'open' "'"', open)( file );code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"'); f.close();exec(编译(代码、文件退出状态为 2 失败 ---------------------------------------- 错误:命令出错退出状态为 1: 'c:\users\prince\appdata\local\programs\python\python37-32\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\prince\AppData\Local\Temp\pip-install-sb1cs5ex\mysqlclient\setup.py'"'"'; file ='"'"'C:\Users\prince\AppData\Local\Temp\pip-install-sb1cs5ex\mysqlclient\setup.py'"'"';f=getattr(tokenize, '"'"'open' "'"', open)( file );code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"'); f.close();exec(compile(code, file , '"'"'exec'"'"'))' install --record 'C:\Users\prince\AppData\Local\Temp\pip-record- 8l4u4qqk\install-record.txt' --single-version-externally-managed --compile 检查日志以获取完整的命令输出。