2020.12.27
pycharm使用plot无法正确画图:
_tkinter.TclError: couldn’t connect to display “:4”
解决方法 参考
import matplotlib
matplotlib.use(‘AGG’)#或者PDF, SVG或PS
import matplotlib.pyplot as plt
2021.5.9
File “D:\software\Anaconda3\envs\cs\lib\site-packages\pyreadline\lineeditor\history.py”, line 82, in read_history_file
for line in open(filename, ‘r’):
UnicodeDecodeError: ‘gbk’ codec can’t decode byte 0x99 in position 214: illegal multibyte sequence
解放方法 参考
将报错语句修改为
open(filename, ‘r’, encoding=‘utf-8’):