<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 async def basic_consume(self, queue_name='', consumer_tag='', no_local=False, no_ack=False, exclusive=False, no_wait=False, arguments=None, wait_message=True, timeout=0):
 """Starts the consumption of message into a queue. the callback will be called each time we're receiving a message. Args: queue_name: str, the queue to receive message from consumer_tag: str, optional consumer tag no_local: bool, if set the server will not send messages to the connection that published them. no_ack: bool, if set the server does not expect acknowledgements for messages exclusive: bool, request exclusive consumer access, meaning only this consumer can access the queue no_wait: bool, if set, the server will not respond to the method arguments: dict, AMQP arguments to be passed to the server wait_message: Indicates if the consumer should wait for new messages in the queue or simply return None if the queue is empty. timeout: A timeout for waiting messages. ``wait_message`` has precendence over timeout. """

        # If a consumer tag was not passed, create one
        consumer_tag = consumer_tag or 'ctag%i.%s' % (
            self.channel_id, uuid.uuid4().hex)

        if arguments is None:
            arguments = {}

        frame = amqp_frame.AmqpRequest(
            self.protocol._stream_writer, amqp_constants.TYPE_METHOD,
            self.channel_id)
        frame.declare_method(
            amqp_constants.CLASS_BASIC, amqp_constants.BASIC_CONSUME)
        request = amqp_frame.AmqpEncoder()
        request.write_short(0)
        request.write_shortstr(queue_name)
        request.write_shortstr(consumer_tag)
        request.write_bits(no_local, no_ack, exclusive, no_wait)
        request.write_table(arguments)

        self.consumer_queues[consumer_tag] = asyncio.Queue(self.max_queue_size)
        self.last_consumer_tag = consumer_tag

        consumer = self.CONSUMER_CLASS(
            self, self.consumer_queues[consumer_tag],
            consumer_tag, nowait=not wait_message,
            timeout=timeout)

        await self._write_frame_awaiting_response(
            'basic_consume', frame, request, no_wait)

        if not no_wait:
            self._ctag_events[consumer_tag].set()

        return consumer