Merge "Convert gerrit output to utf8 unicode"

This commit is contained in:
Zuul 2020-01-28 02:28:47 +00:00 committed by Gerrit Code Review
commit d244a41362

View File

@ -428,13 +428,13 @@ class Gerrit(object):
self.log.debug("SSH command:\n%s" % command)
stdin, stdout, stderr = self.client.exec_command(command)
out = stdout.read()
out = stdout.read().decode('utf8')
self.log.debug("SSH received stdout:\n%s" % out)
ret = stdout.channel.recv_exit_status()
self.log.debug("SSH exit status: %s" % ret)
err = stderr.read()
err = stderr.read().decode('utf8')
self.log.debug("SSH received stderr:\n%s" % err)
if ret:
raise Exception("Gerrit error executing %s" % command)