tableau / tableau-log-viewer

Tableau Log Viewer is a cross-platform tool for quickly glancing over Tableau log files
MIT License
172 stars 51 forks source link

Parse log files as UTF8 #81

Closed vogelsgesang closed 6 years ago

vogelsgesang commented 6 years ago

In accordance with https://tools.ietf.org/html/rfc7159 and https://tools.ietf.org/html/rfc8259, json must be encoded as UTF8. So far, the log viewer did not read the JSON files as UTF8. Instead we relied on QTextStream which internally used a system-dependent encoding.

The logs written by Hyper are UTF8-encoded and the log viewer did not render non-ASCII characters correctly. Logs written by Tableau on the other hand only use plain ASCII characters and escape non-ASCII characters using JSON escape characters. Hence, this change fixes behavior for Hyper log files while at the same time not impacting Tableau log files negatively.