Comment 4 for bug 785578

Revision history for this message
Ignas Vyšnu (yfyf) wrote :

Hi,

I also seem to have this problem with Lithunian characters.
The behaviour is a bit funny though, I seem to be able to enter any unicode characters in the first entry, but the subsequent ones break gTimeLog, with the character 'ą' for example.

> cat .gtimelog/timelog.txt:
2011-09-25 14:33: ą

^^^report works fine.

> cat .gtimelog/timelog.txt
2011-09-25 14:33: ą
2011-09-25 14:40: ą

^^^results in:

Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/gtimelog/main.py", line 1633, in on_daily_report_activate
    self.mail(reports.daily_report)
  File "/usr/lib/python2.7/site-packages/gtimelog/main.py", line 1786, in mail
    write_draft(draft, self.settings.email, self.settings.name)
  File "/usr/lib/python2.7/site-packages/gtimelog/main.py", line 744, in daily_report
    format_duration_long(duration))
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc4 in position 0: ordinal not in range(128)

oh and:
> file .gtimelog/timelog.txt
.gtimelog/timelog.txt: UTF-8 Unicode text