python 去除不可见字符

line.strip().strip(b'x00'.decode())
_line.strip().strip(b'x00'.decode()).strip(b'xefxbbxbf'.decode()).split('')
line.decode('gb2312', 'ignore').encode('utf8')
原文地址:https://www.cnblogs.com/oneby/p/9267384.html