Update haproxy-statsd to python3

Change-Id: I1b5c15f0c47a4bf1261abaf6d4e336aad5339c5b
This commit is contained in:
James E. Blair 2019-05-25 06:47:57 -07:00
parent 5faf89f566
commit 8ebe74e512
1 changed files with 2 additions and 2 deletions

View File

@ -120,11 +120,11 @@ class HAProxy(object):
def command(self, command):
with self.socket as socket:
socket.send(command + '\n')
socket.send((command + '\n').encode('utf8'))
data = ''
while True:
r = socket.recv(4096)
data += r
data += r.decode('utf8')
if not r:
break
return data