<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def popleft(self):
 """Removes and returns the oldest read pulse."""

        self._mq.send("^", True, type=1)
        message = self._wait_receive_msg()
        reply = int(message[0].decode('utf-8'))
        #print(reply)
        if reply == -1:
            raise IndexError("pop from empty list")
        return reply