onejgordon / flow-dashboard

[UNMAINTAINED] A goal, task & habit tracker + personal dashboard to focus on what matters
http://flowdash.co
MIT License
1.67k stars 186 forks source link

Support for unicode characters in exports #144

Open onejgordon opened 2 years ago

onejgordon commented 2 years ago

Exports of user data currently fail when they include unicode characters, e.g.:

/reports.py", line 130, in writeData
2022-07-14 12:17:00.243 PDT
 csv.writer(self.gcs_file).writerow(ed)
2022-07-14 12:17:00.243 PDT
UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-3: ordinal not in range(128)

This may be a limitation of the cloudstorage library in python 2.7 (see https://cloud.google.com/appengine/docs/standard/python/googlecloudstorageclient/read-write-to-cloud-storage), but this is not confirmed.

We currently strip non-ascii characters to avoid problems with writing report data.