- UnicodeDecodeError: 'gbk' codec can't decode byte 0xa8 in position 157: illegal multibyte sequence永久解決方法
- 打開PyQuery文件導入 import chardet 模塊將217行代碼改為
-
1 if 'filename' in kwargs: 2 txt = open('./test_01.html', 'rb').read()#./test_01.html運行文件 3 encoding = chardet.detect(txt)['encoding'] 4 html = open(kwargs['filename'],encoding=encoding)