data = data.decode("utf-8") 出现错误时候可以加上第二个参数 如下; data = data.decode("utf-8","ignore") 忽略错误提示 转载于:https://www.cnblogs.com/lilinpging/p/8358141.html