8
UnicodeDecodeError:'charmap'编解码器无法解码位置Y的字节X:字符映射到<undefined>
我正在尝试让Python 3程序对充满信息的文本文件进行一些操作。但是,当尝试读取文件时,出现以下错误: Traceback (most recent call last): File "SCRIPT LOCATION", line NUMBER, in <module> `text = file.read()` File "C:\Python31\lib\encodings\cp1252.py", line 23, in decode `return codecs.charmap_decode(input,self.errors,decoding_table)[0]` UnicodeDecodeError: 'charmap' codec can't decode byte 0x90 in position 2907500: character maps to `<undefined>`