class_docstr: Selector object for watching and event notification.
      
class_docstr_tok: ["Selector","object","for","watching","and","event","notification","."]
docstr: dispatch events to the registered hanlders
docstr_tok: ["dispatch","events","to","the","registered","hanlders"]
code: def watch(self, timeout=None):
      """dispatch events to the registered hanlders"""
  
      if timeout:
          self._timeout = timeout
  
      self._watch()
      return
  
      # FIXME:
      # leave like this until I understand better the set of exceptions I
      # would like to handle. It really is bad to catch all exceptions,
      # especially since it hides errors during development
      try:
          self._watch()
  
      except:
          # catch all exceptions
          self._cleanup()
  
          # get exception information
          import sys
  
          type, value = sys.exc_info()[:2]
  
          # rethrow the exception so the clients can handle it
          raise type(value)
  
      return
  
file_path: pathos/pathos/selector.py
label_desc: Use image node_id 1 for calling the Selector obj's underlying member method code with example usage: obj.watch(timeout) without return types