for some reason my bot is not responding to PING which makes my bot disconnect.
if len(line) >= 1:
if data.find('PING') != -1:
con.send(bytes(data.replace('PING', 'PONG'), "UTF-8"))
print("PONG :tmi.twitch.tv")
else:
sender = get_sender(line[1]).lower()
message = get_message(line[1:])
parse_message(message)
This is on python 3.5