def twitch_receive_messages(self):
        """
        Call this function to process everything received by the socket
        This needs to be called frequently enough (~10s) Twitch logs off
        users not replying to ping commands.

        :return: list of chat messages received. Each message is a dict
            with the keys ['channel', 'username', 'message']
        """
        self._push_from_buffer()
        result = []
        while True:
            # process the complete buffer, until no data is left no more
            try:
                msg = self.s.recv(4096).decode()     # NON-BLOCKING RECEIVE!
            except socket.error as e:
                err = e.args[0]
                if err == errno.EAGAIN or err == errno.EWOULDBLOCK:
                    # There is no more data available to read
                    return result
                else:
                    # a "real" error occurred
                    # import traceback
                    # import sys
                    # print(traceback.format_exc())
                    # print("Trying to recover...")
                    self.connect()
                    return result
            else:
                if self.verbose:
                    print(msg)
                rec = [self._parse_message(line)
                       for line in filter(None, msg.split('\r\n'))]
                rec = [r for r in rec if r]     # remove Nones
                result.extend(rec)
Call this function to process everything received by the socket
        This needs to be called frequently enough (~10s) Twitch logs off
        users not replying to ping commands.

        :return: list of chat messages received. Each message is a dict
            with the keys ['channel', 'username', 'message']