You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Apparently, there's a bug in the Windows + Python combo on certain locales which results in a wonky encoding choices by the interpreter.
In my case, when I ran python -m mistune ... on a file that contained the character ★ (U+2605 "Black Star"), it produced an error along the lines of:
[lines omitted for clarity]
File "encodings\cp1251.py", line [xxx], in encode
UnicodeEncodeError: 'charmap' codec can't encode characters in position [yyy-zzz]: character maps to <undefined>
My system language is Russian, so its choice of encoding is understandable to a degree. This appears to be a similar problem, and applying that along with this advice fixed it for me.
Maybe there's something to be adjusted in mistune to force it (?) to use UTF-8?
Windows 10
Python 3.12.2
mistune 3.0.2
The text was updated successfully, but these errors were encountered:
Apparently, there's a bug in the Windows + Python combo on certain locales which results in a wonky encoding choices by the interpreter.
In my case, when I ran
python -m mistune ...
on a file that contained the character ★ (U+2605 "Black Star"), it produced an error along the lines of:My system language is Russian, so its choice of encoding is understandable to a degree. This appears to be a similar problem, and applying that along with this advice fixed it for me.
Maybe there's something to be adjusted in mistune to force it (?) to use UTF-8?
The text was updated successfully, but these errors were encountered: