mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-25 00:52:02 +00:00
Update report.py
This commit is contained in:
parent
a6c34fdbc9
commit
e8b29cab6e
@ -233,6 +233,10 @@ def tsvRows(n):
|
||||
for row in csv.reader(fd, delimiter="\t", quoting=csv.QUOTE_NONE):
|
||||
new_row = []
|
||||
for e in row:
|
||||
# The first one .encode('utf-8').decode('unicode-escape') decodes the escape characters from the strings.
|
||||
# The second one (encode('latin1').decode('utf-8')) fixes the changes with unicode vs utf-8 chars, so
|
||||
# 'Чем зÐ<C2B7>нимаеÑ<C2B5>ЬÑ<C2AC>Ñ<EFBFBD>' is transformed back into 'Чем зАнимаешЬся'.
|
||||
|
||||
new_row.append(e.encode('utf-8').decode('unicode-escape').encode('latin1').decode('utf-8'))
|
||||
result.append(new_row)
|
||||
return result
|
||||
|
Loading…
Reference in New Issue
Block a user