def unhandle(self, handler):
        """ unregister handler (removing callback function) """
        with self._hlock:
            try:
                self._handler_list.remove(handler)
            except ValueError:
                raise ValueError("Handler is not handling this event, so cannot unhandle it.")
        return self
def unhandle ( self , handler ) : with self . _hlock : try : self . _handler_list . remove ( handler ) except ValueError : raise ValueError ( "Handler is not handling this event, so cannot unhandle it." ) return self
unregister handler (removing callback function)