Nic0/tyrs — Issue #112: Whats wrong with '¿' ?
Author: diegoxter
Created: 2011-12-23 15:59:33+00:00
State: open

This appeared while trying to write '¿' (without quotes)

File "/usr/bin/tyrs", line 16, in
main()
File "/usr/lib/python2.7/site-packages/tyrs/tyrs.py", line 66, in main
init_tyrs()
File "/usr/lib/python2.7/site-packages/tyrs/tyrs.py", line 71, in init_tyrs
init_interface()
File "/usr/lib/python2.7/site-packages/tyrs/tyrs.py", line 88, in init_interface
user_interface = Interface()
File "/usr/lib/python2.7/site-packages/tyrs/interface.py", line 49, in __init__
self.main_loop()
File "/usr/lib/python2.7/site-packages/tyrs/interface.py", line 62, in main_loop
self.loop.run()
File "/usr/lib/python2.7/site-packages/urwid/main_loop.py", line 274, in run
self.screen.run_wrapper(self._run)
File "/usr/lib/python2.7/site-packages/urwid/raw_display.py", line 237, in run_wrapper
return fn()
File "/usr/lib/python2.7/site-packages/urwid/main_loop.py", line 307, in _run
self.event_loop.run()
File "/usr/lib/python2.7/site-packages/urwid/main_loop.py", line 682, in run
self._loop()
File "/usr/lib/python2.7/site-packages/urwid/main_loop.py", line 720, in _loop
self._watch_files[fd]()
File "/usr/lib/python2.7/site-packages/urwid/main_loop.py", line 358, in _update
self.process_input(keys)
File "/usr/lib/python2.7/site-packages/urwid/main_loop.py", line 447, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/usr/lib/python2.7/site-packages/urwid/container.py", line 629, in keypress
return self.footer.keypress((maxcol,),key)
File "/usr/lib/python2.7/site-packages/urwid/container.py", line 1390, in keypress
key = w.keypress( (mc,)+size[1:], key )
File "/usr/lib/python2.7/site-packages/tyrs/editor.py", line 73, in keypress
urwid.Edit.keypress(self, size, key)
File "/usr/lib/python2.7/site-packages/urwid/widget.py", line 1036, in keypress
self.insert_text( key )
File "/usr/lib/python2.7/site-packages/urwid/widget.py", line 972, in insert_text
text = self._normalize_to_caption(text)
File "/usr/lib/python2.7/site-packages/urwid/widget.py", line 988, in _normalize_to_caption
return text.encode('ascii') # follow python2's implicit conversion
UnicodeEncodeError: 'ascii' codec can't encode character u'\xbf' in position 0: ordinal not in range(128)