UnicodeDecodeError: 'charmap' codec can't decode byte 0x90 in position

Error

UnicodeDecodeError: 'charmap' codec can't decode byte 0x90 in position

Most likely it occurs when working with files that contain characters of another alphabet. For example, Cyrillic ones

Perhaps the encoding problem can be solved by declaring the required encoding when opening the file

Replace

with open('your_file','r') as f:

With

with open('your_file','r', encoding="utf8") as f:

Article author: Andrei Olegovich