爬取电影天堂出现 'gbk' codec can't decode byte 0xd0 in position 25804: illegal multibyte sequence
原因是内部含有非法字符
用gbk编码无法正确解析
解决办法
text = response.content.decode('gbk', 'ignore')
忽略错误检查,可以执行
爬取电影天堂出现 'gbk' codec can't decode byte 0xd0 in position 25804: illegal multibyte sequence
原因是内部含有非法字符
用gbk编码无法正确解析
解决办法
text = response.content.decode('gbk', 'ignore')
忽略错误检查,可以执行