From bda57556a54b8abd1cf109a2b1d9154b377962dd Mon Sep 17 00:00:00 2001 From: Jonas Braathen Date: Wed, 31 Aug 2016 20:50:37 +0200 Subject: [PATCH] Must write bytes to a TLS transport, not unicode. --- snurr.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/snurr.py b/snurr.py index ec1f26b..856c57f 100755 --- a/snurr.py +++ b/snurr.py @@ -41,7 +41,7 @@ class SnurrBot(irc.IRCClient): else: self.actions.newfull(msg, user, channel) logger.info("PRIVMSG: %s: %s" % (user,msg)) - + def msgReply(self, user, to, msg): if len(msg) > 0: if to == self.nickname: @@ -55,7 +55,7 @@ class SnurrBot(irc.IRCClient): logger.info("Message sent to %s" % self.factory.channel) if len(msg) > 0: - self.say(self.factory.channel, msg, length=512) + self.say(self.factory.channel, msg.encode('utf-8'), length=512) def rawDataReceived(self, data): pass