当前位置:网站首页>解决 UnicodeDecodeError: ‘gbk‘ codec can‘t decode byte 0xa2 in position 107
解决 UnicodeDecodeError: ‘gbk‘ codec can‘t decode byte 0xa2 in position 107
2022-07-05 12:40:00 【南湖渔歌】
报错:
UnicodeDecodeError: ‘gbk’ codec can’t decode byte 0xa2 in position 107: illegal multibyte sequence
with open('./test.html') as fin:
html_doc = fin.read()
解决:
with open('./test.html',encoding='utf-8') as fin:
html_doc = fin.read()
边栏推荐
- Storage Basics
- How to connect the API interface of Taobao open platform (super detailed)
- 10 minute fitness method reading notes (1/5)
- Compile kernel modules separately
- 《信息系统项目管理师》备考笔记---信息化知识
- 深度长文探讨Join运算的简化和提速
- 在家庭智能照明中应用的测距传感芯片4530A
- 关于 SAP UI5 getSAPLogonLanguage is not a function 的错误消息以及 API 版本的讨论
- Taobao short video, why the worse the effect
- What is the difference between Bi software in the domestic market
猜你喜欢
10 minute fitness method reading notes (3/5)
国内市场上的BI软件,到底有啥区别
Taobao order amount check error, avoid capital loss API
SAP UI5 DynamicPage 控件介紹
Making and using the cutting tool of TTF font library
Didi open source Delta: AI developers can easily train natural language models
Volatile instruction rearrangement and why instruction rearrangement is prohibited
DNS的原理介绍
RHCAS6
实战模拟│JWT 登录认证
随机推荐
Introduction to the principle of DNS
关于 SAP UI5 floating footer 显示与否的单步调试以及使用 SAP UI5 的收益
Simply take stock reading notes (2/8)
[cloud native] use of Nacos taskmanager task management
Using MySQL in docker
Setting up sqli lab environment
RHCSA1
Language model
SAP self-development records user login logs and other information
GPON other manufacturers' configuration process analysis
A deep long article on the simplification and acceleration of join operation
Taobao, pinduoduo, jd.com, Doudian order & Flag insertion remarks API solution
Oppo Xiaobu launched Obert, a large pre training model, and promoted to the top of kgclue
Distributed solution - Comprehensive decryption of distributed task scheduling platform - xxljob scheduling center cluster
Install rhel8.2 virtual machine
VoneDAO破解组织发展效能难题
Time conversion error
关于 SAP UI5 getSAPLogonLanguage is not a function 的错误消息以及 API 版本的讨论
JDBC exercise - query data encapsulated into object return & simple login demo
Transactions from January 14 to 19, 2022