Hello Todd Lipcon,
I'd like you to do a code review. Please visit
http://gerrit.cloudera.org:8080/2312
to review the following change.
Change subject: test_result_server: ignore binary data during diagnose
......................................................................
test_result_server: ignore binary data during diagnose
Kudu's log output sometimes includes binary data, which leads to diagnosing
errors like these:
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/cherrypy/_cprequest.py", line
670, in respond
response.body = self.handler()
File "/usr/local/lib/python2.7/dist-packages/cherrypy/lib/encoding.py",
line 217, in __call__
self.body = self.oldhandler(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/cherrypy/_cpdispatch.py", line
61, in __call__
return self.callable(*self.args, **self.kwargs)
File "/home/testserver/build-support/test_result_server.py", line 182, in
diagnose
log_text =
gzip.GzipFile(fileobj=StringIO(log_text_gz)).read().decode('utf-8')
File "/usr/lib/python2.7/encodings/utf_8.py", line 16, in decode
return codecs.utf_8_decode(input, errors, True)
UnicodeDecodeError: 'utf8' codec can't decode byte 0xe2 in position 82571:
invalid continuation byte
Switching from the default ('strict') error handling behavior in favor of
'ignore' resolves the issue.
Change-Id: I44cae10bf1c02419e2c2152d0f1f97f1c22c3dd6
---
M build-support/test_result_server.py
1 file changed, 5 insertions(+), 1 deletion(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/12/2312/1
--
To view, visit http://gerrit.cloudera.org:8080/2312
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I44cae10bf1c02419e2c2152d0f1f97f1c22c3dd6
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Adar Dembo <[email protected]>
Gerrit-Reviewer: Todd Lipcon <[email protected]>