code: def get_events(self):
          '''
          iterate over the available events and return a list of events
          '''
          ret = []
          while True:
              event = self.event.get_event(wait=1, full=True)
              if event is None:
                  return ret
              ret.append(eventf get_events(self):
          '''
          iterate over the available events and return a list of events
          '''
          ret = []
          while True:
              event = self.event.get_event(wait=1, full=True)
              if event is None:
                  return ret
              ret.append(event)
docs: iterate over the available events and return a list of events