diff --git a/irc.py b/irc.py index 8296094..7d7602d 100644 --- a/irc.py +++ b/irc.py @@ -362,7 +362,7 @@ class PesterHandler(DefaultCommandHandler): if chan != "#pesterchum": # We don't need anywhere near that much spam. logging.info("---> recv \"PRIVMSG %s :%s\"" % (handle, msg)) - else: + elif chan == "#pesterchum": # follow instructions if msg[0:6] == "MOOD >": try: @@ -405,6 +405,11 @@ class PesterHandler(DefaultCommandHandler): if not self.mainwindow.config.lowBandwidth(): helpers.join(self.client, "#pesterchum") helpers.msg(self.client, "#pesterchum", "MOOD >%d" % (mymood)) + # We override the +T that's set by default, for now, to reenable + # CTCP communication. + # Because of the potential for spam, Low Bandwidth mode still + # disables this...this will likely change in the future. + helpers.mode(self.client, mychumhandle, "-T") def nicknameinuse(self, server, cmd, nick, msg): newnick = "pesterClient%d" % (random.randint(100,999)) diff --git a/parsetools.py b/parsetools.py index 70c7a05..25bf3f9 100644 --- a/parsetools.py +++ b/parsetools.py @@ -358,6 +358,9 @@ def kxsplitMsg(lexed, fmt="pchum", maxlen=None, debug=False): # TODO: There's presently an issue where certain combinations of color # codes end up being added as a separate, empty line. This is a bug, of # course, and should be looked into. + # TODO: This may not work properly with unicode! Because IRC doesn't + # formally use it, it should probably use the lengths of the decomposed + # characters...ugh. lexed = list(lexed) working = [] output = []