1. 程式人生 > 其它 >python decode() 方法以指定的編碼格式解碼 bytes 物件

python decode() 方法以指定的編碼格式解碼 bytes 物件

技術標籤:pythonpython

bytes.decode(encoding="utf-8", errors="strict")

在這裡插入圖片描述

這裡strict意思是隻要有解碼錯誤都會報錯
所以問題很大,後面選擇了’ignore’
在這裡插入圖片描述
原始參考頁面1