python转exe时报错
UnicodeDecodeError: 'gbk' codec can't decode byte 0xaa in pos
原因:
pyinstaller读文件错误
解决方法
找到PyInstaller里的winmanifest.py文件
找到1076行:old_xml = f.read()。
将其中的1075行改为:
with open(filename,encoding="UTF-8") as f:
寻找方法:1、进入pyinstaller的安装路径,参考下面文章
https://blog.youkuaiyun.com/qq_33289175/article/details/87311631
2、找到utils--win32,即可看到
3、用notepad++或记事本打开