PetterKraabol / Twitch-Chat-Downloader

Download chat messages from past broadcasts on Twitch
https://pypi.org/project/tcd
MIT License
643 stars 61 forks source link

UnicodeEncodeError #26

Closed d-alleyne closed 6 years ago

d-alleyne commented 6 years ago

I see the following error for all formats except JSON.

return codecs.charmap_encode(input,self.errors,encoding_table)[0] UnicodeEncodeError: 'charmap' codec can't encode character '\U0001f440' in position 43: character maps to

d-alleyne commented 6 years ago

I "fixed" it on Windows by backing up cp1252.py, and filling its contents with utf_8.py.

PetterKraabol commented 6 years ago

Hi, this looks like an emoji issue. I ran the script on a Windows 10 VM and it worked just fine. Emojis are expectedly appearing as blocks and there are no errors.

Try using this branch https://github.com/PetterKraabol/Twitch-Chat-Downloader/tree/issue-26 I guess the error comes from printing the lines in your terminal/cmd, rather than writing them to disk.

PetterKraabol commented 6 years ago

Closing this for now. Unable to reproduce the error in windows.