def __init__(self, wa_phone, wa_password, contacts, irc_server, irc_port, owner_nick, log_file): threading.Thread.__init__(self) self.must_run = True self.irc_server = irc_server self.irc_port = irc_port self.owner_nick = owner_nick self.wa_phone = wa_phone self.log_file = log_file irc_nick = contacts[wa_phone] self.irc_nick = irc_nick self.wa_password = wa_password self.contacts = contacts self.irc_i = IRCInterface(self.irc_server, self.irc_port, self.irc_nick, channels_from_contacts(self.contacts), self.irc_msg_received, self.stop) self.wa_i = WAInterface(self.wa_phone, self.wa_password, self.wa_msg_received, self.stop)