code: def cancel(self):
          
          LOG.debug('cancelling %s', self)
          self._cancelled = True
          self.clear_callbacks()  # not strictly necessary, but may release references
          while True:
              try:
                  self._waitables.get_nowait().put_nowait(self.sentinel)
              except queue.Empty:
                  break
docs: Cancels the observer
  
          No more notifications will be passed on