Sunday, April 10, 2022

[SOLVED] how to solved charmap' codec can't encode character '\u300b?

Issue

I'm trying to start a script, but I have run in to a problem. [ERROR] 'charmap' codec can't encode character '\u300b' in position 11: character maps to

id='dv3'>

Solution

Your code is printing something that is unreadable for the machine. Try changing the output encoding to "utf-8" or just use code below at the very first lines of your code:

import sys
sys.stdin.reconfigure(encoding='utf-8')
sys.stdout.reconfigure(encoding='utf-8')


Answered By - Amirhossein Kiani
Answer Checked By - Clifford M. (WPSolving Volunteer)