UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb4 in position 0: invalid start byte
See original GitHub issueHello. I trying to run examples/tutorial/2-Movement.py
with no changes and get a error when I pressed numpad buttons.
24 bits font.
key color : 0 0 0
Traceback (most recent call last):
File "C:\Users\ilya_gorohov\Documents\tdltest\main.py", line 60, in <module> for event in tdl.event.get(): # Iterate over recent events.
File "C:\Users\ilya_gorohov\AppData\Local\Programs\Python\Python36-32\lib\site-packages\tdl\event.py", line 384, in get _processEvents()
File "C:\Users\ilya_gorohov\AppData\Local\Programs\Python\Python36-32\lib\site-packages\tdl\event.py", line 365, in _processEvents libkey.ralt, libkey.rctrl, libkey.shift))
File "C:\Users\ilya_gorohov\AppData\Local\Programs\Python\Python36-32\lib\site-packages\tdl\event.py", line 115, in __init__ char = char if isinstance(char, str) else char.decode()
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xc4 in position 0: unexpected end of data
Windows 10, Python 3.6, tdl 2.0.1
Issue Analytics
- State:
- Created 7 years ago
- Comments:5
Top GitHub Comments
I’m able to repeat the _Bool issue on Python 3.6.1 (32-bit). That issue doesn’t show up in a 64-bit build.
libtcod doesn’t seem to define the modifier keys on SDL text events.
Released v3.0.1, which manually zeroes out those values as a temporary fix.
New release v3.0.0 shouldn’t crash, but the event attributes will be mostly blank.