当前位置:网站首页>One trick to cure pycharm DEBUG error UnicodeDecodeError: 'utf-8' codec can't decode
One trick to cure pycharm DEBUG error UnicodeDecodeError: 'utf-8' codec can't decode
2022-08-04 22:19:00 【I am a lion fighting a rabbit】
Project Scenario:
pycharm Professional Edition runs deep learning projects
Problem description
This problem is utterly disgusting. It's disgusting that RUN does not report an error, but when trying to DEBUG, it reports an error, and it does not show where the error is. This leads to long codes that can only be modified by experience, and people will be stupid.
Baidu has a bunch of answers as follows:
The first solution: nothing more thanChanged the code to UTF-8, and changed many places, it is useless at all
The second solution: check whether the path contains Chinese, I will not make such a low-level mistake
The third solution: try to restart the computer,Restart pycharm, or reload pycharm directly, for this kind of suggestion, I can only say: GUN
Solution:
Finally, go directly to the source code of the bottom layer of DEBUG:
r = r.decode('utf-8')# Change to the followingr = r.decode('utf-8', 'ignore')
That is to ignore this error directly. After all, it can be RUN, and the code is no problem, why not let DEBUG.
边栏推荐
- Several ways for rk3399 to drive screen parameters
- Domestic PMP certificate of gold content how
- SQL Server 调用 WebService
- OC-拷贝
- rk3399-0.0 svc command
- 历史上的今天:PHP公开发布;iPhone 4 问世;万维网之父诞生
- Develop your own text recognition application with Tesseract
- 【线性代数02】AX=b的2种解释和矩阵乘法的5种视角
- PowerBI scripture series
- 一招包治pycharm DEBUG报错 UnicodeDecodeError: ‘utf-8‘ codec can‘t decode
猜你喜欢
随机推荐
Use ngrok to optimize web pages on raspberry pi (1)
UDP通信
Analysis and treatment of Ramnit infectious virus
ES 数据聚合、数据同步、集群
测试薪资这么高?刚毕业20K,仅需3.5个月
rk3399 驱动屏参的几种方式
torch单机多卡和多机多卡训练
国际项目管理师PMP证书,值得考嘛?
CountDownLatch使用及原理
祝福一路顺风
老叶的三束玫瑰
VSCode—常用快捷键(持续记录
LeetCode 199: 二叉树的右视图
[Linear Algebra 02] 2 interpretations of AX=b and 5 perspectives of matrix multiplication
【组成原理 六 存储器类型】
视频gif如何制作?试试这个视频制作gif神器
ANT1.7 download and configuration method
【C - 基本概念】
Altium Designer 19.1.18 - Protecting Locked Objects
# #ifndef/#define/#endif使用详解